diff options
author | Owen Anderson <resistor@mac.com> | 2008-10-07 20:22:28 +0000 |
---|---|---|
committer | Owen Anderson <resistor@mac.com> | 2008-10-07 20:22:28 +0000 |
commit | bac9ae29c7009e75c4efb9283b9f0a21d1d34356 (patch) | |
tree | bd2cf50595adb1345d767124b9f529511c09147c /lib/CodeGen/SimpleRegisterCoalescing.cpp | |
parent | 320c148375723e6e2f850f5e9909da26391a0119 (diff) | |
download | external_llvm-bac9ae29c7009e75c4efb9283b9f0a21d1d34356.zip external_llvm-bac9ae29c7009e75c4efb9283b9f0a21d1d34356.tar.gz external_llvm-bac9ae29c7009e75c4efb9283b9f0a21d1d34356.tar.bz2 |
Add an option to enable StrongPHIElimination, for ease of testing.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@57259 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/SimpleRegisterCoalescing.cpp')
-rw-r--r-- | lib/CodeGen/SimpleRegisterCoalescing.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/CodeGen/SimpleRegisterCoalescing.cpp b/lib/CodeGen/SimpleRegisterCoalescing.cpp index b6aae65..0a77826 100644 --- a/lib/CodeGen/SimpleRegisterCoalescing.cpp +++ b/lib/CodeGen/SimpleRegisterCoalescing.cpp @@ -25,6 +25,7 @@ #include "llvm/CodeGen/RegisterCoalescer.h" #include "llvm/Target/TargetInstrInfo.h" #include "llvm/Target/TargetMachine.h" +#include "llvm/Target/TargetOptions.h" #include "llvm/Support/CommandLine.h" #include "llvm/Support/Debug.h" #include "llvm/ADT/SmallSet.h" @@ -72,7 +73,10 @@ void SimpleRegisterCoalescing::getAnalysisUsage(AnalysisUsage &AU) const { AU.addRequired<MachineLoopInfo>(); AU.addPreserved<MachineLoopInfo>(); AU.addPreservedID(MachineDominatorsID); - AU.addPreservedID(PHIEliminationID); + if (StrongPHIElim) + AU.addPreservedID(StrongPHIEliminationID); + else + AU.addPreservedID(PHIEliminationID); AU.addPreservedID(TwoAddressInstructionPassID); MachineFunctionPass::getAnalysisUsage(AU); } |