mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-01 00:33:09 +00:00
reintroduce original (asserting) semantics of CallSite(Instruction *II)
add instead a CallSite(Value* V) constructor that is consistent with ImmutableCallSize and use that one in client code git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109553 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
bdcb5afb77
commit
b344a346f1
@ -55,6 +55,7 @@ public:
|
||||
CallSiteBase(InstrTy *II) {
|
||||
assert(II && "Null instruction given?");
|
||||
*this = get(II);
|
||||
assert(I.getPointer() && "Not a call?");
|
||||
}
|
||||
|
||||
/// CallSiteBase::get - This static method is sort of like a constructor. It
|
||||
@ -293,6 +294,7 @@ class CallSite : public CallSiteBase<Function, Value, User, Instruction,
|
||||
public:
|
||||
CallSite() {}
|
||||
CallSite(Base B) : Base(B) {}
|
||||
CallSite(Value* V) : Base(V) {}
|
||||
CallSite(CallInst *CI) : Base(CI) {}
|
||||
CallSite(InvokeInst *II) : Base(II) {}
|
||||
CallSite(Instruction *II) : Base(II) {}
|
||||
|
@ -120,7 +120,7 @@ getCallSiteDependencyFrom(CallSite CS, bool isReadOnlyCall,
|
||||
Pointer = CI->getArgOperand(0);
|
||||
// calls to free() erase the entire structure
|
||||
PointerSize = ~0ULL;
|
||||
} else if (CallSite InstCS = Inst) {
|
||||
} else if (CallSite InstCS = cast<Value>(Inst)) {
|
||||
// Debug intrinsics don't cause dependences.
|
||||
if (isa<DbgInfoIntrinsic>(Inst)) continue;
|
||||
// If these two calls do not interfere, look past it.
|
||||
|
Loading…
Reference in New Issue
Block a user