[llvm] Use MaxStride instead of CommonStride to calculate MaxVF (PR #98142)

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 9 03:56:35 PDT 2024


================
@@ -2176,7 +2172,7 @@ MemoryDepChecker::Dependence::DepType MemoryDepChecker::isDependent(
   // minimum for computations below, as this ensures we compute the closest
   // possible dependence distance.
   uint64_t MinDistanceNeeded =
-      TypeByteSize * *CommonStride * (MinNumIter - 1) + TypeByteSize;
+      TypeByteSize * MaxStride * (MinNumIter - 1) + TypeByteSize;
----------------
fhahn wrote:

Should be fine I think, as this maximizes the Minimum, would be good to update the comment above though 

https://github.com/llvm/llvm-project/pull/98142


More information about the llvm-commits mailing list