]> git.ipfire.org Git - thirdparty/gcc.git/commit
Fixup vector epilog analysis skipping when not using partial vectors
authorRichard Biener <rguenther@suse.de>
Thu, 26 Jun 2025 09:38:47 +0000 (11:38 +0200)
committerRichard Biener <rguenther@suse.de>
Fri, 27 Jun 2025 09:06:57 +0000 (11:06 +0200)
commitf359b9150c282c69704d8d2a6c8e071c90506538
tree1f783276541effb8511edaaeff1d83b55ec833ea
parenta0af6fd825d53333d0a1e3a5cdb3a2fe4c751c2e
Fixup vector epilog analysis skipping when not using partial vectors

The following avoids re-analyzing the loop as epilogue when not
using partial vectors and the mode is the same as the autodetected
vector mode and that has a too high VF for a non-predicated loop.
This situation occurs almost always on x86 and saves us one
re-analysis unless --param vect-partial-vector-usage is non-default.

* tree-vectorizer.h (vect_chooses_same_modes_p): New
overload.
* tree-vect-stmts.cc (vect_chooses_same_modes_p): Likewise.
* tree-vect-loop.cc (vect_analyze_loop): Prune epilogue
analysis further when not using partial vectors.
gcc/tree-vect-loop.cc
gcc/tree-vect-stmts.cc
gcc/tree-vectorizer.h