------- Comment #9 from mkuvyrkov at gcc dot gnu dot org  2006-12-19 14:00 
-------
(In reply to comment #8)
> Subject: Re:  [4.2/4.3 regression] ICE with scheduling and __builtin_trap
> 
> Hi,
> barrier in the middle of basic block is invalid and should be noticed by
> verify_flow_info and ICE.  What part of my patch you quote is supposed
> to fix the problem?
> 

cfgrtl.c: rtl_verify_flow_info () makes the same statement as
control_flow_insn_p ():
/* We may have a barrier inside a basic block before dead code
   elimination.  There is no BLOCK_FOR_INSN field in a barrier.  */

This hunk from your patch would've helped, I guess:
*************** control_flow_insn_p (rtx insn)
*** 118,123 ****
--- 119,129 ----
              || can_throw_internal (insn));

      case INSN:
+       /* We represent EH manipulation via unspec followed by barrier.
+          Such instruction is control flow instruction even when there is
+          no other clue specifying it.  */
+       if (NEXT_INSN (insn) && GET_CODE (NEXT_INSN (insn)) == BARRIER)
+       return true;
        return (flag_non_call_exceptions && can_throw_internal (insn));

      case BARRIER:


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=29841

Reply via email to