This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
unroll.c (unroll_loops): Don't delete named CODE_LABELs.
- To: egcs-patches at egcs dot cygnus dot com
- Subject: unroll.c (unroll_loops): Don't delete named CODE_LABELs.
- From: Jim Wilson <wilson at cygnus dot com>
- Date: Fri, 09 Jul 1999 19:13:28 -0700
I have checked in this patch. This fixes an irix6 -g -O3 -funroll-all-loops
bootstrap failure reported by Kaveh Ghazi.
Fri Jul 9 19:08:55 1999 Jim Wilson <wilson@cygnus.com>
* unroll.c (unroll_loops): Don't delete named CODE_LABELs.
Index: unroll.c
===================================================================
RCS file: /egcs/carton/cvsfiles/egcs/gcc/unroll.c,v
retrieving revision 1.58
diff -p -r1.58 unroll.c
*** unroll.c 1999/07/07 00:41:18 1.58
--- unroll.c 1999/07/10 02:10:34
*************** unroll_loop (loop_end, insn_count, loop_
*** 1262,1272 ****
insn = NEXT_INSN (copy_start);
while (insn != safety_label)
{
! /* ??? We can't delete a NOTE_INSN_DELETED_LABEL unless we fix the
! DECL_RTL field of the associated LABEL_DECL to point to (one of)
! the new copies of the label. Otherwise, we hit an abort in
! dwarfout.c/dwarf2out.c. */
if (insn != start_label
&& ! (GET_CODE (insn) == NOTE
&& NOTE_LINE_NUMBER (insn) == NOTE_INSN_DELETED_LABEL))
insn = delete_insn (insn);
--- 1262,1277 ----
insn = NEXT_INSN (copy_start);
while (insn != safety_label)
{
! /* ??? Don't delete named code labels. They will be deleted when the
! jump that references them is deleted. Otherwise, we end up deleting
! them twice, which causes them to completely disappear instead of turn
! into NOTE_INSN_DELETED_LABEL notes. This in turn causes aborts in
! dwarfout.c/dwarf2out.c. We could perhaps fix the dwarf*out.c files
! to handle deleted labels instead. Or perhaps fix DECL_RTL of the
! associated LABEL_DECL to point to one of the new label instances. */
! /* ??? Likewise, we can't delete a NOTE_INSN_DELETED_LABEL note. */
if (insn != start_label
+ && ! (GET_CODE (insn) == CODE_LABEL && LABEL_NAME (insn))
&& ! (GET_CODE (insn) == NOTE
&& NOTE_LINE_NUMBER (insn) == NOTE_INSN_DELETED_LABEL))
insn = delete_insn (insn);