diff options
author | Brian Gaeke <gaeke@uiuc.edu> | 2003-11-07 20:04:22 +0000 |
---|---|---|
committer | Brian Gaeke <gaeke@uiuc.edu> | 2003-11-07 20:04:22 +0000 |
commit | fea483d7c027c595101dce825bdf3f512bf9aaca (patch) | |
tree | 8ac90ca099a1f6df83e5a222ba25ed2297ef83e7 /lib/ExecutionEngine | |
parent | ae2495a9210257a9d4c430df20952c34034828c8 (diff) | |
download | external_llvm-fea483d7c027c595101dce825bdf3f512bf9aaca.zip external_llvm-fea483d7c027c595101dce825bdf3f512bf9aaca.tar.gz external_llvm-fea483d7c027c595101dce825bdf3f512bf9aaca.tar.bz2 |
visitCallInst --> visitCallSite.
Use visitCallSite to implement both CallInsts and InvokeInsts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9788 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/ExecutionEngine')
-rw-r--r-- | lib/ExecutionEngine/Interpreter/Execution.cpp | 4 | ||||
-rw-r--r-- | lib/ExecutionEngine/Interpreter/Interpreter.h | 7 |
2 files changed, 7 insertions, 4 deletions
diff --git a/lib/ExecutionEngine/Interpreter/Execution.cpp b/lib/ExecutionEngine/Interpreter/Execution.cpp index 6eb0324..e04f564 100644 --- a/lib/ExecutionEngine/Interpreter/Execution.cpp +++ b/lib/ExecutionEngine/Interpreter/Execution.cpp @@ -637,9 +637,9 @@ void Interpreter::visitStoreInst(StoreInst &I) { // Miscellaneous Instruction Implementations //===----------------------------------------------------------------------===// -void Interpreter::visitCallInst(CallInst &I) { +void Interpreter::visitCallSite(CallSite CS) { ExecutionContext &SF = ECStack.back(); - SF.Caller = CallSite(&I); + SF.Caller = CS; std::vector<GenericValue> ArgVals; const unsigned NumArgs = SF.Caller.arg_size(); ArgVals.reserve(NumArgs); diff --git a/lib/ExecutionEngine/Interpreter/Interpreter.h b/lib/ExecutionEngine/Interpreter/Interpreter.h index 06e8257..974aea8 100644 --- a/lib/ExecutionEngine/Interpreter/Interpreter.h +++ b/lib/ExecutionEngine/Interpreter/Interpreter.h @@ -119,10 +119,13 @@ public: void visitLoadInst(LoadInst &I); void visitStoreInst(StoreInst &I); void visitGetElementPtrInst(GetElementPtrInst &I); - void visitPHINode(PHINode &PN) { assert(0 && "PHI nodes already handled!"); } void visitCastInst(CastInst &I); - void visitCallInst(CallInst &I); + + void visitCallSite(CallSite CS); + void visitCallInst(CallInst &I) { visitCallSite (CallSite (&I)); } + void visitInvokeInst(InvokeInst &I) { visitCallSite (CallSite (&I)); } + void visitShl(ShiftInst &I); void visitShr(ShiftInst &I); void visitVANextInst(VANextInst &I); |