[llvm] [NFC][LoopVectorize] Introduce new getEstimatedRuntimeVF function (PR #116247)
Hari Limaye via llvm-commits
llvm-commits at lists.llvm.org
Fri Nov 15 02:24:13 PST 2024
================
@@ -4976,11 +4973,7 @@ LoopVectorizationCostModel::selectInterleaveCount(ElementCount VF,
MaxInterleaveCount = ForceTargetMaxVectorInterleaveFactor;
}
- unsigned EstimatedVF = VF.getKnownMinValue();
- if (VF.isScalable()) {
- if (std::optional<unsigned> VScale = getVScaleForTuning(TheLoop, TTI))
- EstimatedVF *= *VScale;
- }
+ unsigned EstimatedVF = getEstimatedRuntimeVF(TheLoop, TTI, VF);
assert(EstimatedVF >= 1 && "Estimated VF shouldn't be less than 1");
----------------
hazzlim wrote:
Does it make any sense to move this assert into `getEstimatedRuntimeVF` ?
https://github.com/llvm/llvm-project/pull/116247
More information about the llvm-commits
mailing list