https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82689
Richard Biener <rguenth at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |missed-optimization Status|UNCONFIRMED |NEW Last reconfirmed| |2017-10-24 CC| |rguenth at gcc dot gnu.org Blocks| |33315 Ever confirmed|0 |1 --- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> --- We don't currently optimize this (RTL crossjumping does to the extent you are seeing). On GIMPLE there's no semantically equivalent code doing an unconditional store (you'd lose at least some TBAA). There's a related bug, PR33315, about sinking and commoning stores. Referenced Bugs: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=33315 [Bug 33315] stores not commoned by sinking