https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100858
--- Comment #2 from Nikita Kniazev <nok.raven at gmail dot com> --- (In reply to Richard Biener from comment #1) > That's really a duplicate of 100858 - this case can be handled by sinking as > well > since we "sink" the return. Make it > > void bar(); > > int foo(bool f) > { > if (f) { > bar(); > __builtin_abort (); > } > else { > bar(); > return 2; > } > } > to force hoisting. I have a hard time in finding this as equivalent to the original code. > Hoisting is done by PRE but that requires a LHS and doesn't handle calls with > side-effects. That seems like an artificial limitation. Why we cannot hoist the bar call?