This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Your ifcvt patch breaks bootstrap


On Sat, Jul 14, 2001 at 05:24:47PM -0400, Daniel Berlin wrote:
> trap_bb is the exit block, so GET_CODE (insn) on the head insn (which
> is NULL), crashes.

This fixes the one failure; a full powerpc cross-build is
still underway.


r~

Index: ifcvt.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/ifcvt.c,v
retrieving revision 1.54
diff -c -p -d -r1.54 ifcvt.c
*** ifcvt.c	2001/07/14 18:39:15	1.54
--- ifcvt.c	2001/07/14 23:58:56
*************** find_cond_trap (test_bb, then_edge, else
*** 2018,2023 ****
--- 2018,2028 ----
    else
      return FALSE;
  
+   /* Don't confuse a conditional return with something we want to
+      optimize here.  */
+   if (trap_bb == EXIT_BLOCK_PTR)
+     return FALSE;
+ 
    /* The only instruction in the THEN block must be the trap.  */
    trap = first_active_insn (trap_bb);
    if (! (trap == trap_bb->end


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]