diff options
-rw-r--r-- | lib/ExecutionEngine/JIT/JIT.cpp | 2 | ||||
-rw-r--r-- | tools/llc/llc.cpp | 3 |
2 files changed, 2 insertions, 3 deletions
diff --git a/lib/ExecutionEngine/JIT/JIT.cpp b/lib/ExecutionEngine/JIT/JIT.cpp index 91c8caf..7262739 100644 --- a/lib/ExecutionEngine/JIT/JIT.cpp +++ b/lib/ExecutionEngine/JIT/JIT.cpp @@ -47,7 +47,7 @@ JIT::JIT(ModuleProvider *MP, TargetMachine &tm, TargetJITInfo &tji) // Add target data MutexGuard locked(lock); FunctionPassManager& PM = state.getPM(locked); - PM.add(new TargetData(TM.getTargetData())); + PM.add(new TargetData(*TM.getTargetData())); // Compile LLVM Code down to machine code in the intermediate representation TJI.addPassesToJITCompile(PM); diff --git a/tools/llc/llc.cpp b/tools/llc/llc.cpp index 4d36e83..1df22ac 100644 --- a/tools/llc/llc.cpp +++ b/tools/llc/llc.cpp @@ -143,11 +143,10 @@ int main(int argc, char **argv) { std::auto_ptr<TargetMachine> target(MArch->CtorFn(mod, FeaturesStr)); assert(target.get() && "Could not allocate target machine!"); TargetMachine &Target = *target.get(); - const TargetData *TD = Target.getTargetData(); // Build up all of the passes that we want to do to the module... PassManager Passes; - Passes.add(new TargetData(TD)); + Passes.add(new TargetData(*Target.getTargetData())); #ifndef NDEBUG if(!NoVerify) |