summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/SystemZ
diff options
context:
space:
mode:
authorJonas Paulsson <jonas.paulsson@ericsson.com>2015-10-08 07:39:55 +0000
committerJonas Paulsson <jonas.paulsson@ericsson.com>2015-10-08 07:39:55 +0000
commit9e1f3bd1bd74c65056c4f30428b1bd3152a581bf (patch)
tree9917574314b28536e55e47acc968f25bb3b4b55b /llvm/lib/Target/SystemZ
parent90c5099e8a6e78aa29575bfdc83dfbf1543af7fc (diff)
downloadbcm5719-llvm-9e1f3bd1bd74c65056c4f30428b1bd3152a581bf.tar.gz
bcm5719-llvm-9e1f3bd1bd74c65056c4f30428b1bd3152a581bf.zip
[SystemZ] Minor fixes in SystemZElimCompare.cpp
Reviewed by Ulrich Weigand. llvm-svn: 249662
Diffstat (limited to 'llvm/lib/Target/SystemZ')
-rw-r--r--llvm/lib/Target/SystemZ/SystemZElimCompare.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/llvm/lib/Target/SystemZ/SystemZElimCompare.cpp b/llvm/lib/Target/SystemZ/SystemZElimCompare.cpp
index 16f9adc79f1..d26e40b4791 100644
--- a/llvm/lib/Target/SystemZ/SystemZElimCompare.cpp
+++ b/llvm/lib/Target/SystemZ/SystemZElimCompare.cpp
@@ -205,7 +205,7 @@ SystemZElimCompare::convertToBRCT(MachineInstr *MI, MachineInstr *Compare,
.addOperand(MI->getOperand(1))
.addOperand(Target)
.addReg(SystemZ::CC, RegState::ImplicitDefine);
- MI->removeFromParent();
+ MI->eraseFromParent();
return true;
}
@@ -439,17 +439,16 @@ bool SystemZElimCompare::processBlock(MachineBasicBlock &MBB) {
(optimizeCompareZero(MI, CCUsers) ||
fuseCompareAndBranch(MI, CCUsers))) {
++MBBI;
- MI->removeFromParent();
+ MI->eraseFromParent();
Changed = true;
CCUsers.clear();
- CompleteCCUsers = true;
continue;
}
Reference CCRefs(getRegReferences(MI, SystemZ::CC));
if (CCRefs.Def) {
CCUsers.clear();
- CompleteCCUsers = !CCRefs.IndirectDef;
+ CompleteCCUsers = true;
}
if (CompleteCCUsers && CCRefs.Use)
CCUsers.push_back(MI);
OpenPOWER on IntegriCloud