http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59019
--- Comment #5 from Jeffrey A. Law <law at redhat dot com> --- Always considering trap-if as ending a BB appears to be a bit of a rathole. Every time I squash one issue, another raises its head. I did find that combine.c already has some bits to recognize when it does something that may muck up the CFG and tries to compensate, it just doesn't hadle the situation around trap-if. I'm going to see if I can proof of concept a fix in that code. Of course this is a pass specific fix, but as I look deeper, more memories keep coming back -- we've had special code in cse.c to deal with similar situations, so maybe adding another case for combine isn't that bad after all.