From c8c6c03dda789a6af20b23182b11bef088498735 Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Sun, 28 Dec 2003 09:44:37 +0000 Subject: Pass around IntrinsicLowering instances as appropriate. Reimplement the Interpreters implementation of va_* to be more direct. llvm-svn: 10627 --- llvm/lib/ExecutionEngine/Interpreter/Interpreter.h | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'llvm/lib/ExecutionEngine/Interpreter/Interpreter.h') diff --git a/llvm/lib/ExecutionEngine/Interpreter/Interpreter.h b/llvm/lib/ExecutionEngine/Interpreter/Interpreter.h index 1f50777351f..5757327c208 100644 --- a/llvm/lib/ExecutionEngine/Interpreter/Interpreter.h +++ b/llvm/lib/ExecutionEngine/Interpreter/Interpreter.h @@ -79,6 +79,7 @@ struct ExecutionContext { class Interpreter : public ExecutionEngine, public InstVisitor { int ExitCode; // The exit code to be returned by the lli util TargetData TD; + IntrinsicLowering *IL; // The runtime stack of executing code. The top of the stack is the current // function record. @@ -89,17 +90,20 @@ class Interpreter : public ExecutionEngine, public InstVisitor { std::vector AtExitHandlers; public: - Interpreter(Module *M, bool isLittleEndian, bool isLongPointer); - inline ~Interpreter() { } + Interpreter(Module *M, bool isLittleEndian, bool isLongPointer, + IntrinsicLowering *IL); + ~Interpreter(); /// runAtExitHandlers - Run any functions registered by the program's calls to /// atexit(3), which we intercept and store in AtExitHandlers. /// void runAtExitHandlers(); - /// create - Create an interpreter ExecutionEngine. This can never fail. + /// create - Create an interpreter ExecutionEngine. This can never fail. The + /// specified IntrinsicLowering implementation will be deleted when the + /// Interpreter execution engine is destroyed. /// - static ExecutionEngine *create(Module *M); + static ExecutionEngine *create(Module *M, IntrinsicLowering *IL); /// run - Start execution with the specified function and arguments. /// -- cgit v1.2.3