mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-03-09 06:46:45 +08:00
cfgloop.c (flow_loops_find): Fix handling of abnormal edges.
2003-01-16 Zdenek Dvorak <rakdver@atrey.karlin.mff.cuni.cz> * cfgloop.c (flow_loops_find): Fix handling of abnormal edges. From-SVN: r61393
This commit is contained in:
parent
c1b50e4978
commit
16f2b86aa8
@ -1,3 +1,7 @@
|
||||
2003-01-16 Zdenek Dvorak <rakdver@atrey.karlin.mff.cuni.cz>
|
||||
|
||||
* cfgloop.c (flow_loops_find): Fix handling of abnormal edges.
|
||||
|
||||
2003-01-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
|
||||
|
||||
* dbxout.c (lastfile, cwd): Fix `unused' warning.
|
||||
|
@ -804,19 +804,20 @@ flow_loops_find (loops, flags)
|
||||
|
||||
header->loop_depth = 0;
|
||||
|
||||
/* If we have an abnormal predecessor, do not consider the
|
||||
loop (not worth the problems). */
|
||||
for (e = header->pred; e; e = e->pred_next)
|
||||
if (e->flags & EDGE_ABNORMAL)
|
||||
break;
|
||||
if (e)
|
||||
continue;
|
||||
|
||||
for (e = header->pred; e; e = e->pred_next)
|
||||
{
|
||||
basic_block latch = e->src;
|
||||
|
||||
if (e->flags & EDGE_ABNORMAL)
|
||||
{
|
||||
if (more_latches)
|
||||
{
|
||||
RESET_BIT (headers, header->index);
|
||||
num_loops--;
|
||||
}
|
||||
break;
|
||||
}
|
||||
abort ();
|
||||
|
||||
/* Look for back edges where a predecessor is dominated
|
||||
by this block. A natural loop has a single entry
|
||||
|
Loading…
Reference in New Issue
Block a user