[llvm] 85e2a36 - [DA] Remove dead code from the Weak Crossing SIV test (#190355)
via llvm-commits
llvm-commits at lists.llvm.org
Fri Apr 3 09:30:48 PDT 2026
Author: Ryotaro Kasuga
Date: 2026-04-03T16:30:42Z
New Revision: 85e2a3650185cf68be1ff2df74b447ca4899a96d
URL: https://github.com/llvm/llvm-project/commit/85e2a3650185cf68be1ff2df74b447ca4899a96d
DIFF: https://github.com/llvm/llvm-project/commit/85e2a3650185cf68be1ff2df74b447ca4899a96d.diff
LOG: [DA] Remove dead code from the Weak Crossing SIV test (#190355)
The ConstantRange intersection check can now handle cases where the
condition of this branch is satisfied. The check is performed before
entering this function, so this part is no longer necessary.
Added:
Modified:
llvm/lib/Analysis/DependenceAnalysis.cpp
Removed:
################################################################################
diff --git a/llvm/lib/Analysis/DependenceAnalysis.cpp b/llvm/lib/Analysis/DependenceAnalysis.cpp
index da591472d8dc0..ab09b2095dcc3 100644
--- a/llvm/lib/Analysis/DependenceAnalysis.cpp
+++ b/llvm/lib/Analysis/DependenceAnalysis.cpp
@@ -1402,17 +1402,6 @@ bool DependenceInfo::weakCrossingSIVtest(const SCEVAddRecExpr *Src,
if (!ConstDelta)
return false;
- // We're certain that ConstCoeff > 0; therefore,
- // if Delta < 0, then no dependence.
- LLVM_DEBUG(dbgs() << "\t Delta = " << *Delta << "\n");
- LLVM_DEBUG(dbgs() << "\t ConstCoeff = " << *ConstCoeff << "\n");
- if (SE->isKnownNegative(Delta)) {
- // No dependence, Delta < 0
- ++WeakCrossingSIVindependence;
- ++WeakCrossingSIVsuccesses;
- return true;
- }
-
ConstantRange SrcRange = SE->getSignedRange(Src);
ConstantRange DstRange = SE->getSignedRange(Dst);
LLVM_DEBUG(dbgs() << "\t SrcRange = " << SrcRange << "\n");
More information about the llvm-commits
mailing list