[llvm] [LV] Prefer fixed VFs for epilogue vectorization (PR #211814)
David Sherwood via llvm-commits
llvm-commits at lists.llvm.org
Fri Jul 31 04:18:21 PDT 2026
================
@@ -706,6 +706,21 @@ bool LoopVectorizationPlanner::isMoreProfitable(const VectorizationFactor &A,
!B.Width.isScalar())
return true;
+ // Prefer fixed VFs for epilogue loops (unless the fixed cost is much more
+ // expensive -- >= 2x). There are some extra costs for using scalable vectors
----------------
david-arm wrote:
I'm not sure about adding a hidden, magic tuning factor here. At the very least, such a tuning factor needs modelling properly with a tunable cost (i.e. one that can be controlled via the command line).
https://github.com/llvm/llvm-project/pull/211814
More information about the llvm-commits
mailing list