[llvm] [LoopVectorizer] Only check register pressure for VFs that have been enabled via maxBandwidth (PR #149056)
Florian Hahn via llvm-commits
llvm-commits at lists.llvm.org
Fri Jul 18 01:29:58 PDT 2025
================
@@ -4375,9 +4389,10 @@ VectorizationFactor LoopVectorizationPlanner::selectVectorizationFactor() {
if (VF.isScalar())
continue;
- /// Don't consider the VF if it exceeds the number of registers for the
- /// target.
- if (CM.useMaxBandwidth(VF) && RUs[I].exceedsMaxNumRegs(TTI))
+ /// If the VF was proposed due to MaxBandwidth, don't consider the VF if
+ /// it exceeds the number of registers for the target.
----------------
fhahn wrote:
This comment now mentions MaxBandwith, but calls the more generally named `shouldCalculateRegPressureForVF`, which doesn't mentioned `MaxBandwidth` in its doc-comment. Would be good to either clarify `shouldCalculateRegPressureForVF`' doc-comment or the function name
https://github.com/llvm/llvm-project/pull/149056
More information about the llvm-commits
mailing list