diff options
author | spop <spop@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-01-05 21:21:16 +0000 |
---|---|---|
committer | spop <spop@138bc75d-0d04-0410-961f-82ee72b054a4> | 2009-01-05 21:21:16 +0000 |
commit | d51c4d4c9d643b05450ee86d0949e4dadd6530f3 (patch) | |
tree | 7103675e82bd26353d156d348a7f09c39210cc96 /gcc/graphite.h | |
parent | 6c6bce6534f7c9abaedd691b758c9af12dd269be (diff) | |
download | gcc-d51c4d4c9d643b05450ee86d0949e4dadd6530f3.tar.gz |
2009-01-05 Sebastian Pop <sebastian.pop@amd.com>
PR tree-optimization/38492
* graphite.c (rename_map_elt, debug_rename_elt,
debug_rename_map_1, debug_rename_map, new_rename_map_elt,
rename_map_elt_info, eq_rename_map_elts,
get_new_name_from_old_name, bb_in_sese_p): Moved around.
(sese_find_uses_to_rename_use): Renamed sese_build_livein_liveouts_use.
(sese_find_uses_to_rename_bb): Renamed sese_build_livein_liveouts_bb.
(sese_build_livein_liveouts): New.
(new_sese, free_sese): New.
(new_scop): Call new_sese.
(free_scop): Call free_sese.
(rename_variables_from_edge, rename_phis_end_scop): Removed.
(register_old_new_names): Renamed register_old_and_new_names.
(register_scop_liveout_renames, add_loop_exit_phis,
insert_loop_close_phis, struct igp,
default_liveout_before_guard, add_guard_exit_phis,
insert_guard_phis, copy_renames): New.
(translate_clast): Call insert_loop_close_phis and insert_guard_phis.
(sese_add_exit_phis_edge): Renamed scop_add_exit_phis_edge.
(rewrite_into_sese_closed_ssa): Renamed scop_insert_phis_for_liveouts.
(scop_adjust_phis_for_liveouts): New.
(gloog): Call scop_adjust_phis_for_liveouts.
* graphite.h (struct sese): Documented. Added fields liveout,
num_ver and livein.
(SESE_LIVEOUT, SESE_LIVEIN, SESE_LIVEIN_VER, SESE_NUM_VER): New.
(new_sese, free_sese, sese_build_livein_liveouts): Declared.
(struct scop): Added field liveout_renames.
(SCOP_LIVEOUT_RENAMES): New.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@143097 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/graphite.h')
-rw-r--r-- | gcc/graphite.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/gcc/graphite.h b/gcc/graphite.h index 92a68167f22..76f26c8728a 100644 --- a/gcc/graphite.h +++ b/gcc/graphite.h @@ -275,13 +275,36 @@ DEF_VEC_ALLOC_P (name_tree, heap); by two edges. */ typedef struct sese { + /* Single ENTRY and single EXIT from the SESE region. */ edge entry, exit; + + /* REGION_BASIC_BLOCKS contains the set of all the basic blocks + belonging to the SESE region. */ struct pointer_set_t *region_basic_blocks; + + /* An SSA_NAME version is flagged in the LIVEOUT bitmap if the + SSA_NAME is defined inside and used outside the SESE region. */ + bitmap liveout; + + /* The overall number of SSA_NAME versions used to index LIVEIN. */ + int num_ver; + + /* For each SSA_NAME version VER in LIVEOUT, LIVEIN[VER] contains + the set of basic blocks indices that contain a use of VER. */ + bitmap *livein; } *sese; #define SESE_ENTRY(S) (S->entry) #define SESE_EXIT(S) (S->exit) #define SESE_REGION_BBS(S) (S->region_basic_blocks) +#define SESE_LIVEOUT(S) (S->liveout) +#define SESE_LIVEIN(S) (S->livein) +#define SESE_LIVEIN_VER(S, I) (S->livein[I]) +#define SESE_NUM_VER(S) (S->num_ver) + +extern sese new_sese (edge, edge); +extern void free_sese (sese); +extern void sese_build_livein_liveouts (sese); /* A SCOP is a Static Control Part of the program, simple enough to be represented in polyhedral form. */ @@ -319,6 +342,10 @@ struct scop can only add new params before generating the bb domains, otherwise they become invalid. */ bool add_params; + + /* LIVEOUT_RENAMES registers the rename mapping that has to be + applied after code generation. */ + htab_t liveout_renames; }; #define SCOP_BBS(S) S->bbs @@ -341,6 +368,7 @@ struct scop #define SCOP_PROG(S) S->program #define SCOP_LOOP2CLOOG_LOOP(S) S->loop2cloog_loop #define SCOP_LOOPS_MAPPING(S) S->loops_mapping +#define SCOP_LIVEOUT_RENAMES(S) S->liveout_renames extern void debug_scop (scop_p, int); extern void debug_scops (int); |