aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2010-03-04 21:28:09 +0000
committerEvan Cheng <evan.cheng@apple.com>2010-03-04 21:28:09 +0000
commit5e4415d10159d96f00103cf510855f833508f3d2 (patch)
tree3b1bfa19dc6d9e3d66dbe35bfec10b6dda859d4c
parent5daca473d881155a2d66ba067d55d21f84a7bf11 (diff)
downloadexternal_llvm-5e4415d10159d96f00103cf510855f833508f3d2.zip
external_llvm-5e4415d10159d96f00103cf510855f833508f3d2.tar.gz
external_llvm-5e4415d10159d96f00103cf510855f833508f3d2.tar.bz2
Run machine licm before machine cse to avoid messing up licm opportunities.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@97752 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--lib/CodeGen/LLVMTargetMachine.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/CodeGen/LLVMTargetMachine.cpp b/lib/CodeGen/LLVMTargetMachine.cpp
index 33d37f7..abf183c 100644
--- a/lib/CodeGen/LLVMTargetMachine.cpp
+++ b/lib/CodeGen/LLVMTargetMachine.cpp
@@ -320,10 +320,10 @@ bool LLVMTargetMachine::addCommonCodeGenPasses(PassManagerBase &PM,
if (OptLevel != CodeGenOpt::None) {
PM.add(createOptimizeExtsPass());
- if (EnableMachineCSE)
- PM.add(createMachineCSEPass());
if (!DisableMachineLICM)
PM.add(createMachineLICMPass());
+ if (EnableMachineCSE)
+ PM.add(createMachineCSEPass());
if (!DisableMachineSink)
PM.add(createMachineSinkingPass());
printAndVerify(PM, "After MachineLICM and MachineSinking",