summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Analysis/LoopAccessAnalysis.cpp
diff options
context:
space:
mode:
authorAdam Nemet <anemet@apple.com>2015-11-03 20:13:43 +0000
committerAdam Nemet <anemet@apple.com>2015-11-03 20:13:43 +0000
commitd7037c56d3faa38eb9870abfb181a339e5532a13 (patch)
tree47cdc1aa82ca57d80079494a20a56ae4e85dbffc /llvm/lib/Analysis/LoopAccessAnalysis.cpp
parentb45516e875f5398418cf7e89f20bd41707b52358 (diff)
downloadbcm5719-llvm-d7037c56d3faa38eb9870abfb181a339e5532a13.tar.gz
bcm5719-llvm-d7037c56d3faa38eb9870abfb181a339e5532a13.zip
[LAA] LLE 2/6: Fix a NoDep case that should be a Forward dependence
Summary: When the dependence distance in zero then we have a loop-independent dependence from the earlier to the later access. No current client of LAA uses forward dependences so other than potentially hitting the MaxDependences threshold earlier, this change shouldn't affect anything right now. This and the previous patch were tested together for compile-time regression. None found in LNT/SPEC. Reviewers: hfinkel Subscribers: rengolin, llvm-commits Differential Revision: http://reviews.llvm.org/D13255 llvm-svn: 251973
Diffstat (limited to 'llvm/lib/Analysis/LoopAccessAnalysis.cpp')
-rw-r--r--llvm/lib/Analysis/LoopAccessAnalysis.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Analysis/LoopAccessAnalysis.cpp b/llvm/lib/Analysis/LoopAccessAnalysis.cpp
index b4b646f8144..80d6575a9c2 100644
--- a/llvm/lib/Analysis/LoopAccessAnalysis.cpp
+++ b/llvm/lib/Analysis/LoopAccessAnalysis.cpp
@@ -1090,7 +1090,7 @@ MemoryDepChecker::isDependent(const MemAccessInfo &A, unsigned AIdx,
// Could be improved to assert type sizes are the same (i32 == float, etc).
if (Val == 0) {
if (ATy == BTy)
- return Dependence::NoDep;
+ return Dependence::Forward;
DEBUG(dbgs() << "LAA: Zero dependence difference but different types\n");
return Dependence::Unknown;
}
OpenPOWER on IntegriCloud