summaryrefslogtreecommitdiff
path: root/lib/Target/ARM/ARMBaseInstrInfo.cpp
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2010-09-10 23:46:12 +0000
committerBill Wendling <isanbard@gmail.com>2010-09-10 23:46:12 +0000
commit3665661a5708c8adc2727be38b56d1d87ddeb661 (patch)
tree950e2818cdb04156591a728b71d31ea9f79b8425 /lib/Target/ARM/ARMBaseInstrInfo.cpp
parent92ad57f066e9f256e4e3d72febf152e68caa80c7 (diff)
downloadllvm-3665661a5708c8adc2727be38b56d1d87ddeb661.tar.gz
llvm-3665661a5708c8adc2727be38b56d1d87ddeb661.tar.bz2
llvm-3665661a5708c8adc2727be38b56d1d87ddeb661.tar.xz
No need to recompute the SrcReg and CmpValue.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@113666 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/ARM/ARMBaseInstrInfo.cpp')
-rw-r--r--lib/Target/ARM/ARMBaseInstrInfo.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/lib/Target/ARM/ARMBaseInstrInfo.cpp b/lib/Target/ARM/ARMBaseInstrInfo.cpp
index a73e7ad44d..d79905a80b 100644
--- a/lib/Target/ARM/ARMBaseInstrInfo.cpp
+++ b/lib/Target/ARM/ARMBaseInstrInfo.cpp
@@ -1381,11 +1381,9 @@ AnalyzeCompare(const MachineInstr *MI, unsigned &SrcReg, int &CmpValue) const {
/// comparison into one that sets the zero bit in the flags register. Update the
/// iterator *only* if a transformation took place.
bool ARMBaseInstrInfo::
-ConvertToSetZeroFlag(MachineInstr *CmpInstr,
+ConvertToSetZeroFlag(MachineInstr *CmpInstr, unsigned SrcReg, int CmpValue,
MachineBasicBlock::iterator &MII) const {
- unsigned SrcReg;
- int CmpValue;
- if (!AnalyzeCompare(CmpInstr, SrcReg, CmpValue) || CmpValue != 0)
+ if (CmpValue != 0)
return false;
MachineRegisterInfo &MRI = CmpInstr->getParent()->getParent()->getRegInfo();