From 50872d5385463cf1d2e23a758516e7f818e1af24 Mon Sep 17 00:00:00 2001 From: Brian Gaeke Date: Wed, 14 Apr 2004 17:45:52 +0000 Subject: [PATCH] Add a TargetData to the PassManager regardless of the TargetMachine. This should unbreak the Sparc JIT again. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12949 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/ExecutionEngine/JIT/JIT.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/ExecutionEngine/JIT/JIT.cpp b/lib/ExecutionEngine/JIT/JIT.cpp index 4426c67ef8f..3d4bc4c6882 100644 --- a/lib/ExecutionEngine/JIT/JIT.cpp +++ b/lib/ExecutionEngine/JIT/JIT.cpp @@ -32,6 +32,9 @@ JIT::JIT(ModuleProvider *MP, TargetMachine &tm, TargetJITInfo &tji) // Initialize MCE MCE = createEmitter(*this); + // Add target data + PM.add (new TargetData (TM.getTargetData ())); + // Compile LLVM Code down to machine code in the intermediate representation TJI.addPassesToJITCompile(PM);