We don't want to find dependencies within the same block in this case. It leads to incorrect results because

we're detecting something at or after the call we're querying on.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52433 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Owen Anderson 2008-06-17 22:27:06 +00:00
parent b79bf1966d
commit 2960ed4b85

View File

@ -492,7 +492,7 @@ uint32_t ValueTable::lookup_or_add(Value* V) {
return nextValueNumber++;
} else if (I->second != MemoryDependenceAnalysis::NonLocal) {
if (DT->dominates(I->first, C->getParent())) {
if (DT->properlyDominates(I->first, C->getParent())) {
if (CallInst* CD = dyn_cast<CallInst>(I->second))
cdep = CD;
else {