This is the mail archive of the gcc-bugs@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]
Other format: [Raw text]

[Bug rtl-optimization/42461] [4.5 Regression] Missed optimisation for pure functions with __builtin_unreachable



------- Comment #3 from ebotcazou at gcc dot gnu dot org  2010-01-30 16:47 -------
So what's the story here?  Is it the case that const/pure function removal must
now be done entirely at the tree level because everything is frozen EH-wise at
the RTL level?  Why isn't there the obvious early return for -fno-exceptions?

/* Return true if INSN could throw, assuming no REG_EH_REGION note
   to the contrary.  */

bool
insn_could_throw_p (const_rtx insn)
{
  if (CALL_P (insn))
    return true;
  if (INSN_P (insn) && flag_non_call_exceptions)
    return may_trap_p (PATTERN (insn));
  return false;
}


-- 

ebotcazou at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ebotcazou at gcc dot gnu dot
                   |                            |org


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


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