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:
0c58897
)
MachineBasicBlock::remove should not modify the iterator passed in
author
Chris Lattner
<sabre@nondot.org>
Wed, 31 Mar 2004 21:59:29 +0000
(21:59 +0000)
committer
Chris Lattner
<sabre@nondot.org>
Wed, 31 Mar 2004 21:59:29 +0000
(21:59 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12571
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 181fe469a13a9ad8e0f3d158f606226a1eb87bad..324f4c4e853c44b6b4852fad2e60b41a3952481d 100644
(file)
--- a/
lib/CodeGen/PHIElimination.cpp
+++ b/
lib/CodeGen/PHIElimination.cpp
@@
-71,8
+71,7
@@
bool PNE::EliminatePHINodes(MachineFunction &MF, MachineBasicBlock &MBB) {
while (MBB.front().getOpcode() == TargetInstrInfo::PHI) {
// Unlink the PHI node from the basic block... but don't delete the PHI yet
- MachineBasicBlock::iterator begin = MBB.begin();
- MachineInstr *MI = MBB.remove(begin);
+ MachineInstr *MI = MBB.remove(MBB.begin());
assert(MRegisterInfo::isVirtualRegister(MI->getOperand(0).getReg()) &&
"PHI node doesn't write virt reg?");