https://gcc.gnu.org/bugzilla/show_bug.cgi?id=113371
--- Comment #6 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Richard Biener <rgue...@gcc.gnu.org>: https://gcc.gnu.org/g:3359942417b02de88ae84d50aac232ac01ff9e15 commit r14-8175-g3359942417b02de88ae84d50aac232ac01ff9e15 Author: Richard Biener <rguent...@suse.de> Date: Tue Jan 16 13:09:27 2024 +0100 tree-optimization/113371 - avoid prologue peeling for peeled early exits The following avoids prologue peeling when doing early exit vectorization with the IV exit before the early exit. That's because we it invalidates the invariant that the effective latch of the loop is empty causing wrong continuation to the main loop. In particular this is prone to break virtual SSA form. PR tree-optimization/113371 * tree-vect-data-refs.cc (vect_enhance_data_refs_alignment): Do not peel when LOOP_VINFO_EARLY_BREAKS_VECT_PEELED. * tree-vect-loop-manip.cc (vect_do_peeling): Assert we do not perform prologue peeling when LOOP_VINFO_EARLY_BREAKS_VECT_PEELED. * gcc.dg/vect/pr113371.c: New testcase.