projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3bb4657
)
Fix an obvious bug, noticed by inspection. No current targets trigger this.
author
Chris Lattner
<sabre@nondot.org>
Sat, 12 Aug 2006 05:41:39 +0000
(
05:41
+0000)
committer
Chris Lattner
<sabre@nondot.org>
Sat, 12 Aug 2006 05:41:39 +0000
(
05:41
+0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@29648
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/CodeGen/PHIElimination.cpp
patch
|
blob
|
history
diff --git
a/lib/CodeGen/PHIElimination.cpp
b/lib/CodeGen/PHIElimination.cpp
index ffbae2a7ff726c19147aa54a3ce5483202e90671..fef833cc19fa87acbd9dc1f7a0cc972e49df9d59 100644
(file)
--- a/
lib/CodeGen/PHIElimination.cpp
+++ b/
lib/CodeGen/PHIElimination.cpp
@@
-103,9
+103,9
@@
bool PNE::EliminatePHINodes(MachineFunction &MF, MachineBasicBlock &MBB) {
/// use of the specified register.
static bool InstructionUsesRegister(MachineInstr *MI, unsigned SrcReg) {
for (unsigned i = 0, e = MI->getNumOperands(); i != e; ++i)
- if (MI->getOperand(
0
).isRegister() &&
- MI->getOperand(
0
).getReg() == SrcReg &&
- MI->getOperand(
0
).isUse())
+ if (MI->getOperand(
i
).isRegister() &&
+ MI->getOperand(
i
).getReg() == SrcReg &&
+ MI->getOperand(
i
).isUse())
return true;
return false;
}