http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60577
--- Comment #5 from Richard Biener <rguenth at gcc dot gnu.org> --- Created attachment 32393 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=32393&action=edit hack Like this (hack alert). Applies store motion one level for a restricted set of loops. Requires us to add preheaders and record exits (and disambiguate multiple latches) and compute dominators.