http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59006
--- Comment #6 from rguenther at suse dot de <rguenther at suse dot de> --- On Wed, 20 Nov 2013, congh at google dot com wrote: > http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59006 > > Cong Hou <congh at google dot com> changed: > > What |Removed |Added > ---------------------------------------------------------------------------- > CC| |congh at google dot com > > --- Comment #5 from Cong Hou <congh at google dot com> --- > Hoisting all vectorized statements may not be the best solution (some loads > may > not be necessary outside of the loop), but I think it works and can solve the > current issues. Richard, are you working on this? If you'd like I could also > make a patch with this idea. No, I was trying to fix it in another way but that didn't work out. Feel free to take the bug (and yes, applying the invariant motion after the vectorization transform, on the vectorized stmts). Thanks, Richard.