https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101501
Richard Biener <rguenth at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Ever confirmed|0 |1 Last reconfirmed| |2021-07-22 Assignee|unassigned at gcc dot gnu.org |rguenth at gcc dot gnu.org Status|UNCONFIRMED |ASSIGNED --- Comment #4 from Richard Biener <rguenth at gcc dot gnu.org> --- niter analysis computes Analyzing # of iterations of loop 2 exit condition [a_lsm.5_10 * 52, + , 204] != 0 bounds on difference of bases: -255 ... 0 result: # of iterations (a_lsm.5_10 * 52) / 52, bounded by 63 but then Loop 2 iterates at most 14 times. Loop 2 likely iterates at most 14 times. because we have nb_iterations_upper_bound set on the loop. That upper bound is set by the vectorizer which vectorizes the loop but then it's immediately removed again because the runtime profitability check optimizes to 1 != 0?! With -fno-vect-cost-model things don't fare any better but -fno-tree-vectorize fixes the issue.