From: Richard Stallman Date: Sat, 6 Nov 1993 21:50:29 +0000 (+0000) Subject: (unroll_loop): Don't unroll loop if jump has combined X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=b9b817f010ec5bdaaeff1d31e00adfb3f74b5c98;p=gcc.git (unroll_loop): Don't unroll loop if jump has combined the original loop start label with another label. From-SVN: r6028 --- diff --git a/gcc/unroll.c b/gcc/unroll.c index 038c99854ec..631abcc93c0 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