diff options
author | Christopher Lamb <christopher.lamb@gmail.com> | 2007-07-27 07:36:14 +0000 |
---|---|---|
committer | Christopher Lamb <christopher.lamb@gmail.com> | 2007-07-27 07:36:14 +0000 |
commit | ed37973fd1a1c3ec69d3d99dccbc594c9039b08b (patch) | |
tree | b289127f3dbd55e3448aaf51b0b610983c7553b6 | |
parent | 75b3832ff3773dc6d12bdbd6316e6c46ddfaa5c9 (diff) | |
download | external_llvm-ed37973fd1a1c3ec69d3d99dccbc594c9039b08b.tar.gz external_llvm-ed37973fd1a1c3ec69d3d99dccbc594c9039b08b.tar.bz2 external_llvm-ed37973fd1a1c3ec69d3d99dccbc594c9039b08b.zip |
Move subreg lowering pass to be right after regalloc, per feedback.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40548 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/CodeGen/LLVMTargetMachine.cpp | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/lib/CodeGen/LLVMTargetMachine.cpp b/lib/CodeGen/LLVMTargetMachine.cpp index 4620abb721..526c5255fe 100644 --- a/lib/CodeGen/LLVMTargetMachine.cpp +++ b/lib/CodeGen/LLVMTargetMachine.cpp @@ -72,6 +72,11 @@ LLVMTargetMachine::addPassesToEmitFile(FunctionPassManager &PM, if (PrintMachineCode) PM.add(createMachineFunctionPrinterPass(cerr)); + + PM.add(createLowerSubregsPass()); + + if (PrintMachineCode) // Print the subreg lowered code + PM.add(createMachineFunctionPrinterPass(cerr)); // Run post-ra passes. if (addPostRegAlloc(PM, Fast) && PrintMachineCode) @@ -96,8 +101,6 @@ LLVMTargetMachine::addPassesToEmitFile(FunctionPassManager &PM, if (addPreEmitPass(PM, Fast) && PrintMachineCode) PM.add(createMachineFunctionPrinterPass(cerr)); - - PM.add(createLowerSubregsPass()); switch (FileType) { default: @@ -178,6 +181,11 @@ bool LLVMTargetMachine::addPassesToEmitMachineCode(FunctionPassManager &PM, if (PrintMachineCode) PM.add(createMachineFunctionPrinterPass(cerr)); + + PM.add(createLowerSubregsPass()); + + if (PrintMachineCode) // Print the subreg lowered code + PM.add(createMachineFunctionPrinterPass(cerr)); // Run post-ra passes. if (addPostRegAlloc(PM, Fast) && PrintMachineCode) @@ -199,8 +207,6 @@ bool LLVMTargetMachine::addPassesToEmitMachineCode(FunctionPassManager &PM, if (addPreEmitPass(PM, Fast) && PrintMachineCode) PM.add(createMachineFunctionPrinterPass(cerr)); - - PM.add(createLowerSubregsPass()); addCodeEmitter(PM, Fast, PrintEmittedAsm, MCE); |