llvm-project/llvm/test/Analysis/DependenceAnalysis
Congzhe Cao 76be554931 [DependenceAnalysis][PR56275] Normalize negative dependence analysis results
This patch is the first of the two-patch series (D130188, D130179) that
resolve PR56275 (https://github.com/llvm/llvm-project/issues/56275)
which is a missed opportunity, where a perfrectly valid case for loop
interchange failed interchange legality.

If the distance/direction vector produced by dependence analysis (DA) is
negative, it needs to be normalized (reversed). This patch provides helper
functions `isDirectionNegative()` and `normalize()` in DA that does the
normalization, and clients can query DA to do normalization if needed.

A pass option `<normalized-results>` is added to DependenceAnalysisPrinterPass,
and we leverage it to update DA test cases to make sure of test coverage. The
test cases added in `Banerjee.ll` shows that negative vectors are normalized
with `print<da><normalized-results>`.

Reviewed By: bmahjour, Meinersbur, #loopoptwg

Differential Revision: https://reviews.llvm.org/D130188
2022-08-03 19:59:00 -04:00
..
AA.ll
Banerjee.ll [DependenceAnalysis][PR56275] Normalize negative dependence analysis results 2022-08-03 19:59:00 -04:00
BasePtrBug.ll
Constraints.ll
Coupled.ll
DADelin.ll
Dump.ll
ExactRDIV.ll
ExactSIV.ll
GCD.ll
Invariant.ll
MIVCheckConst.ll
MIVMaxLevelThreshold.ll
MismatchingNestLevels.ll
NonAffineExpr.ll
NonCanonicalizedSubscript.ll
PR21585.ll
Preliminary.ll
PreliminaryNoValidityCheckFixedSize.ll
Propagating.ll
Separability.ll
SimpleSIVNoValidityCheck.ll
SimpleSIVNoValidityCheckFixedSize.ll
StrongSIV.ll
SymbolicRDIV.ll
SymbolicSIV.ll
UsefulGEP.ll
WeakCrossingSIV.ll
WeakZeroDstSIV.ll
WeakZeroSrcSIV.ll
ZIV.ll
lcssa.ll Recommit "[SCEV] Look through single value PHIs." (take 3) 2022-06-09 15:20:10 +01:00
new-pm-invalidation.ll