mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-29 10:25:12 +00:00
Make it explicit that ExecutionEngine takes ownership of the modules.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@215967 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -94,7 +94,7 @@ class Interpreter : public ExecutionEngine, public InstVisitor<Interpreter> {
|
||||
std::vector<Function*> AtExitHandlers;
|
||||
|
||||
public:
|
||||
explicit Interpreter(Module *M);
|
||||
explicit Interpreter(std::unique_ptr<Module> M);
|
||||
~Interpreter();
|
||||
|
||||
/// runAtExitHandlers - Run any functions registered by the program's calls to
|
||||
@@ -105,10 +105,11 @@ public:
|
||||
static void Register() {
|
||||
InterpCtor = create;
|
||||
}
|
||||
|
||||
/// create - Create an interpreter ExecutionEngine. This can never fail.
|
||||
|
||||
/// Create an interpreter ExecutionEngine.
|
||||
///
|
||||
static ExecutionEngine *create(Module *M, std::string *ErrorStr = nullptr);
|
||||
static ExecutionEngine *create(std::unique_ptr<Module> M,
|
||||
std::string *ErrorStr = nullptr);
|
||||
|
||||
/// run - Start execution with the specified function and arguments.
|
||||
///
|
||||
|
Reference in New Issue
Block a user