Fix memdep's handling of invokes when finding the dependency of another call

instruction.  This fixes some Ada miscompiles reported in PR2324.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@51069 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Owen Anderson 2008-05-13 21:25:37 +00:00
parent 9b43ac042e
commit ff5a535378

View File

@ -129,7 +129,7 @@ Instruction* MemoryDependenceAnalysis::getCallSiteDependency(CallSite C,
// FreeInsts erase the entire structure
pointerSize = ~0UL;
} else if (isa<CallInst>(QI)) {
} else if (CallSite::get(QI).getInstruction() != 0) {
AliasAnalysis::ModRefBehavior result =
AA.getModRefBehavior(CallSite::get(QI));
if (result != AliasAnalysis::DoesNotAccessMemory) {