diff options
| author | Hal Finkel <hfinkel@anl.gov> | 2013-04-18 22:54:25 +0000 |
|---|---|---|
| committer | Hal Finkel <hfinkel@anl.gov> | 2013-04-18 22:54:25 +0000 |
| commit | b12da6be7501ae98870907015660ff23d0288f3e (patch) | |
| tree | 2f6c3f90988764f39e7e4b816ae72353d34b9b41 /llvm/lib/Target/PowerPC | |
| parent | 1e4a886c287e4bd4a46dc202ed27539c658807d2 (diff) | |
| download | bcm5719-llvm-b12da6be7501ae98870907015660ff23d0288f3e.tar.gz bcm5719-llvm-b12da6be7501ae98870907015660ff23d0288f3e.zip | |
Disable PPC comparison optimization by default
This seems to cause a stage-2 LLVM compile failure (by crashing TableGen); do
I'm disabling this for now.
llvm-svn: 179807
Diffstat (limited to 'llvm/lib/Target/PowerPC')
| -rw-r--r-- | llvm/lib/Target/PowerPC/PPCInstrInfo.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp b/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp index b78f071ef65..cd50bb5306e 100644 --- a/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp +++ b/llvm/lib/Target/PowerPC/PPCInstrInfo.cpp @@ -42,6 +42,9 @@ static cl:: opt<bool> DisableCTRLoopAnal("disable-ppc-ctrloop-analysis", cl::Hidden, cl::desc("Disable analysis for CTR loops")); +static cl::opt<bool> DisableCmpOpt("disable-ppc-cmp-opt", cl::init(true), +cl::desc("Disable compare instruction optimization"), cl::Hidden); + PPCInstrInfo::PPCInstrInfo(PPCTargetMachine &tm) : PPCGenInstrInfo(PPC::ADJCALLSTACKDOWN, PPC::ADJCALLSTACKUP), TM(tm), RI(*TM.getSubtargetImpl(), *this) {} @@ -1088,6 +1091,9 @@ bool PPCInstrInfo::optimizeCompareInstr(MachineInstr *CmpInstr, unsigned SrcReg, unsigned SrcReg2, int Mask, int Value, const MachineRegisterInfo *MRI) const { + if (DisableCmpOpt) + return false; + int OpC = CmpInstr->getOpcode(); unsigned CRReg = CmpInstr->getOperand(0).getReg(); bool isFP = OpC == PPC::FCMPUS || OpC == PPC::FCMPUD; |

