https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106343
--- Comment #7 from Richard Biener <rguenth at gcc dot gnu.org> --- SLP discovery doesn't support this (and there's for sure some duplicate bug about this). Note that SLP discovery currently does a greedy search from the stores and it commits to the first "working" graph (where "working" differs from loop vs. non-loop operation), opening up more "fixup" possibilities will also open up the chance for it to de-rail more easily.