diff options
author | rakdver <rakdver@138bc75d-0d04-0410-961f-82ee72b054a4> | 2006-02-05 20:14:59 +0000 |
---|---|---|
committer | rakdver <rakdver@138bc75d-0d04-0410-961f-82ee72b054a4> | 2006-02-05 20:14:59 +0000 |
commit | c8d055f657b3a033072fca9dc9501bffd927b04d (patch) | |
tree | f9c43362e6fd6ea70ca28c6eb34ce8db0d770637 /gcc/loop-init.c | |
parent | dd7622e6d3b955a40e1b8e7973dfedfa57dad5e6 (diff) | |
download | gcc-c8d055f657b3a033072fca9dc9501bffd927b04d.tar.gz |
* tree-vrp.c (cfg_loops): Removed.
(adjust_range_with_scev, vrp_visit_assignment, execute_vrp):
Use current_loops instead of cfg_loops. Pass flags to
loop_optimizer_init.
* cfgloopmanip.c (fix_loop_structure): Update only available
information.
* tree-ssa-loop-ch.c (copy_loop_headers): Pass flags to
loop_optimizer_init.
* modulo-sched.c (build_loops_structure): Removed.
(sms_schedule): Use loop_optimizer_init.
* loop-init.c (loop_optimizer_init): Use flags to determine
which properties of loops to prepare.
(rtl_loop_init): Pass flags to loop_optimizer_init.
* tree-ssa-sink.c (execute_sink_code): Ditto.
* tree-ssa-loop.c (tree_loop_optimizer_init): Ditto.
* tree-ssa-pre.c (init_pre): Ditto.
* cfgloop.h (LOOPS_NORMAL): New.
(loop_optimizer_init): Declaration changed.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@110620 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/loop-init.c')
-rw-r--r-- | gcc/loop-init.c | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/gcc/loop-init.c b/gcc/loop-init.c index d44575b983d..d6c370314cc 100644 --- a/gcc/loop-init.c +++ b/gcc/loop-init.c @@ -34,10 +34,11 @@ Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA /* Initialize loop optimizer. This is used by the tree and RTL loop - optimizers. */ + optimizers. FLAGS specify what properties to compute and/or ensure for + loops. */ struct loops * -loop_optimizer_init (FILE *dumpfile) +loop_optimizer_init (FILE *dumpfile, unsigned flags) { struct loops *loops = XCNEW (struct loops); edge e; @@ -77,13 +78,19 @@ loop_optimizer_init (FILE *dumpfile) loops->cfg.dfs_order = NULL; /* Create pre-headers. */ - create_preheaders (loops, CP_SIMPLE_PREHEADERS); + if (flags & LOOPS_HAVE_PREHEADERS) + create_preheaders (loops, CP_SIMPLE_PREHEADERS); /* Force all latches to have only single successor. */ - force_single_succ_latches (loops); + if (flags & LOOPS_HAVE_SIMPLE_LATCHES) + force_single_succ_latches (loops); /* Mark irreducible loops. */ - mark_irreducible_loops (loops); + if (flags & LOOPS_HAVE_MARKED_IRREDUCIBLE_REGIONS) + mark_irreducible_loops (loops); + + if (flags & LOOPS_HAVE_MARKED_SINGLE_EXITS) + mark_single_exit_loops (loops); /* Dump loops. */ flow_loops_dump (loops, dumpfile, NULL, 1); @@ -166,7 +173,7 @@ rtl_loop_init (void) /* Initialize structures for layout changes. */ cfg_layout_initialize (0); - current_loops = loop_optimizer_init (dump_file); + current_loops = loop_optimizer_init (dump_file, LOOPS_NORMAL); } struct tree_opt_pass pass_rtl_loop_init = |