diff options
Diffstat (limited to 'lib/Target/X86/X86TargetMachine.cpp')
-rw-r--r-- | lib/Target/X86/X86TargetMachine.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/Target/X86/X86TargetMachine.cpp b/lib/Target/X86/X86TargetMachine.cpp index e316abc522..7d5e5ce4e9 100644 --- a/lib/Target/X86/X86TargetMachine.cpp +++ b/lib/Target/X86/X86TargetMachine.cpp @@ -5,6 +5,7 @@ //===----------------------------------------------------------------------===// #include "X86TargetMachine.h" +#include "llvm/Transforms/Scalar.h" #include "llvm/Target/TargetMachineImpls.h" #include "llvm/CodeGen/MachineFunction.h" #include "llvm/PassManager.h" @@ -28,6 +29,11 @@ X86TargetMachine::X86TargetMachine() : TargetMachine("X86", 1, 4, 4, 4) { /// not supported for this target. /// bool X86TargetMachine::addPassesToJITCompile(PassManager &PM) { + // For the moment we have decided that malloc and free will be + // taken care of by converting them to calls, using the existing + // LLVM scalar transforms pass to do this. + PM.add(createLowerAllocationsPass()); + PM.add(createSimpleX86InstructionSelector(*this)); // TODO: optional optimizations go here |