aboutsummaryrefslogtreecommitdiff
path: root/gcc/unroll.c
diff options
context:
space:
mode:
authorRichard Stallman <rms@gnu.org>1993-11-06 21:50:29 +0000
committerRichard Stallman <rms@gnu.org>1993-11-06 21:50:29 +0000
commitb9b817f010ec5bdaaeff1d31e00adfb3f74b5c98 (patch)
tree4c3ab00671bd320beaff1ae3bfc864feb9db456d /gcc/unroll.c
parenta39be5d99123923ddd09b846ee4a918d77c04260 (diff)
downloadgcc-b9b817f010ec5bdaaeff1d31e00adfb3f74b5c98.zip
gcc-b9b817f010ec5bdaaeff1d31e00adfb3f74b5c98.tar.gz
gcc-b9b817f010ec5bdaaeff1d31e00adfb3f74b5c98.tar.bz2
(unroll_loop): Don't unroll loop if jump has combined
the original loop start label with another label. From-SVN: r6028
Diffstat (limited to 'gcc/unroll.c')
-rw-r--r--gcc/unroll.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/gcc/unroll.c b/gcc/unroll.c
index 038c998..631abcc 100644
--- a/gcc/unroll.c
+++ b/gcc/unroll.c
@@ -600,6 +600,18 @@ unroll_loop (loop_end, insn_count, loop_start, end_insert_before,
"Unrolling failure: unknown insns between BEG note and loop label.\n");
return;
}
+ if (LABEL_NAME (start_label))
+ {
+ /* The jump optimization pass must have combined the original start label
+ with a named label for a goto. We can't unroll this case because
+ jumps which go to the named label must be handled differently than
+ jumps to the loop start, and it is impossible to differentiate them
+ in this case. */
+ if (loop_dump_stream)
+ fprintf (loop_dump_stream,
+ "Unrolling failure: loop start label is gone\n");
+ return;
+ }
if (unroll_type == UNROLL_NAIVE
&& GET_CODE (last_loop_insn) == BARRIER