[llvm] [LAA] Relax HasSameSize check on couldPrevertStoreLoadForward (PR #159537)
Ramkumar Ramachandra via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 3 01:41:22 PDT 2026
================
@@ -2274,10 +2277,9 @@ MemoryDepChecker::isDependent(const MemAccessInfo &A, unsigned AIdx,
// Attempt to prove strided accesses independent.
if (APDist) {
- // If the distance between accesses and their strides are known constants,
- // check whether the accesses interlace each other.
- if (ConstDist > 0 && CommonStride && CommonStride > 1 && HasSameSize &&
- areStridedAccessesIndependent(ConstDist, *CommonStride, TypeByteSize)) {
+ if (ConstDist && CommonStride && CommonStride > 1 && HasSameSize &&
+ areStridedAccessesIndependent(ConstDist, *CommonStride,
+ TypeByteSize.first)) {
----------------
artagnon wrote:
Ah, but we're guarding on HasSameSize anyway, so both elements of the pair are equal: see https://github.com/llvm/llvm-project/pull/161238 for underlying change.
https://github.com/llvm/llvm-project/pull/159537
More information about the llvm-commits
mailing list