summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2002-12-28 20:33:32 +0000
committerChris Lattner <sabre@nondot.org>2002-12-28 20:33:32 +0000
commit9a81e694392a58c78817e13f5539fdb0978481be (patch)
tree407c1056614f332066c7236720b1f103237128ff /llvm/lib
parente6fb194716db4caf29077794a5f750239c1ec781 (diff)
downloadbcm5719-llvm-9a81e694392a58c78817e13f5539fdb0978481be.tar.gz
bcm5719-llvm-9a81e694392a58c78817e13f5539fdb0978481be.zip
* Initialize new FrameInfo member
* most pass ctors no longer take TM arguments * New prolog/epilog insertion pass llvm-svn: 5188
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Target/X86/X86TargetMachine.cpp15
1 files changed, 11 insertions, 4 deletions
diff --git a/llvm/lib/Target/X86/X86TargetMachine.cpp b/llvm/lib/Target/X86/X86TargetMachine.cpp
index 0fc56611f45..7075a3324a0 100644
--- a/llvm/lib/Target/X86/X86TargetMachine.cpp
+++ b/llvm/lib/Target/X86/X86TargetMachine.cpp
@@ -36,7 +36,8 @@ X86TargetMachine::X86TargetMachine(unsigned Config)
(Config & TM::EndianMask) == TM::LittleEndian,
1, 4,
(Config & TM::PtrSizeMask) == TM::PtrSize64 ? 8 : 4,
- (Config & TM::PtrSizeMask) == TM::PtrSize64 ? 8 : 4) {
+ (Config & TM::PtrSizeMask) == TM::PtrSize64 ? 8 : 4),
+ FrameInfo(TargetFrameInfo::StackGrowsDown, 1/*16*/, 0) {
}
@@ -60,12 +61,18 @@ bool X86TargetMachine::addPassesToJITCompile(PassManager &PM) {
// Perform register allocation to convert to a concrete x86 representation
if (NoLocalRA)
- PM.add(createSimpleRegisterAllocator(*this));
+ PM.add(createSimpleRegisterAllocator());
else
- PM.add(createLocalRegisterAllocator(*this));
+ PM.add(createLocalRegisterAllocator());
+
+ if (PrintCode)
+ PM.add(createMachineFunctionPrinterPass());
+
+ // Insert prolog/epilog code. Eliminate abstract frame index references...
+ PM.add(createPrologEpilogCodeInserter());
if (PrintCode) // Print the register-allocated code
- PM.add(createX86CodePrinterPass(*this, std::cerr));
+ PM.add(createX86CodePrinterPass(std::cerr));
PM.add(createMachineCodeDestructionPass());
OpenPOWER on IntegriCloud