[llvm] [LV]Split store-load forward distance analysis from other checks, NFC (PR #121156)
Florian Hahn via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 17 04:49:13 PDT 2025
================
@@ -3874,12 +3874,17 @@ FixedScalableVFPair LoopVectorizationCostModel::computeFeasibleMaxVF(
// the memory accesses that is most restrictive (involved in the smallest
// dependence distance).
unsigned MaxSafeElements =
- llvm::bit_floor(Legal->getMaxSafeVectorWidthInBits() / WidestType);
+ bit_floor(Legal->getMaxSafeVectorWidthInBits() / WidestType);
+ unsigned MaxSafeElementsPowerOf2 = MaxSafeElements;
----------------
fhahn wrote:
Do we need the extra `MaxSafeElementsPowerOf2` variable?
```suggestion
unsigned MaxSafeElementsPowerOf2 = bit_floor(Legal->getMaxSafeVectorWidthInBits() / WidestType);
```
https://github.com/llvm/llvm-project/pull/121156
More information about the llvm-commits
mailing list