diff options
author | rakdver <rakdver@138bc75d-0d04-0410-961f-82ee72b054a4> | 2006-11-21 01:08:40 +0000 |
---|---|---|
committer | rakdver <rakdver@138bc75d-0d04-0410-961f-82ee72b054a4> | 2006-11-21 01:08:40 +0000 |
commit | 8543a44827ae51f7ae6f3ba02b9472746cbc825c (patch) | |
tree | 62f9209bb475165a417f48acb5220a1a6c098b40 /gcc/cfgloop.c | |
parent | 749ea85f0162cbb4f17e2c28b779260bc3a6da36 (diff) | |
download | gcc-8543a44827ae51f7ae6f3ba02b9472746cbc825c.tar.gz |
* cfgloopmanip.c (add_loop, duplicate_loop): Do not set level
of the loop.
* cfgloop.c (flow_loop_level_compute, flow_loops_level_compute):
Removed.
(flow_loop_dump): Do not dump loop level.
(flow_loops_find): Do not call flow_loops_level_compute.
* cfgloop.h (struct loop): Remove level field.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@119040 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cfgloop.c')
-rw-r--r-- | gcc/cfgloop.c | 50 |
1 files changed, 2 insertions, 48 deletions
diff --git a/gcc/cfgloop.c b/gcc/cfgloop.c index 4a5631df081..e00e6a62ea4 100644 --- a/gcc/cfgloop.c +++ b/gcc/cfgloop.c @@ -41,8 +41,6 @@ Software Foundation, 51 Franklin Street, Fifth Floor, Boston, MA #define LATCH_EDGE(E) (*(int *) (E)->aux) static void flow_loops_cfg_dump (const struct loops *, FILE *); -static int flow_loop_level_compute (struct loop *); -static void flow_loops_level_compute (struct loops *); static void establish_preds (struct loop *); static void canonicalize_loop_headers (void); static bool glb_enum_p (basic_block, void *); @@ -110,9 +108,8 @@ flow_loop_dump (const struct loop *loop, FILE *file, fprintf (file, ";; header %d, latch %d\n", loop->header->index, loop->latch->index); - fprintf (file, ";; depth %d, level %d, outer %ld\n", - loop->depth, loop->level, - (long) (loop->outer ? loop->outer->num : -1)); + fprintf (file, ";; depth %d, outer %ld\n", + loop->depth, (long) (loop->outer ? loop->outer->num : -1)); fprintf (file, ";; nodes:"); bbs = get_loop_body (loop); @@ -355,45 +352,6 @@ flow_loop_tree_node_remove (struct loop *loop) loop->pred = NULL; } -/* Helper function to compute loop nesting depth and enclosed loop level - for the natural loop specified by LOOP. Returns the loop level. */ - -static int -flow_loop_level_compute (struct loop *loop) -{ - struct loop *inner; - int level = 1; - - if (! loop) - return 0; - - /* Traverse loop tree assigning depth and computing level as the - maximum level of all the inner loops of this loop. The loop - level is equivalent to the height of the loop in the loop tree - and corresponds to the number of enclosed loop levels (including - itself). */ - for (inner = loop->inner; inner; inner = inner->next) - { - int ilevel = flow_loop_level_compute (inner) + 1; - - if (ilevel > level) - level = ilevel; - } - - loop->level = level; - return level; -} - -/* Compute the loop nesting depth and enclosed loop level for the loop - hierarchy tree specified by LOOPS. Return the maximum enclosed loop - level. */ - -static void -flow_loops_level_compute (struct loops *loops) -{ - flow_loop_level_compute (loops->tree_root); -} - /* A callback to update latch and header info for basic block JUMP created by redirecting an edge. */ @@ -707,10 +665,6 @@ flow_loops_find (struct loops *loops) loop->num_nodes = flow_loop_nodes_find (loop->header, loop); } - /* Assign the loop nesting depth and enclosed loop level for each - loop. */ - flow_loops_level_compute (loops); - loops->num = num_loops; initialize_loops_parallel_p (loops); |