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:
467c430
)
Fix for PR4121. If TwoAddressInstructionPass removes a dead def, and the regB
author
Lang Hames
<lhames@gmail.com>
Wed, 13 May 2009 04:18:47 +0000
(
04:18
+0000)
committer
Lang Hames
<lhames@gmail.com>
Wed, 13 May 2009 04:18:47 +0000
(
04:18
+0000)
operand was killed, the kill needs to be removed from regB's VarInfo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@71635
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/CodeGen/TwoAddressInstructionPass.cpp
patch
|
blob
|
history
diff --git
a/lib/CodeGen/TwoAddressInstructionPass.cpp
b/lib/CodeGen/TwoAddressInstructionPass.cpp
index e37639e068a680ad123904fb65e0ab413cb4454e..2ec0c712222e4ef022266a05572f04a19154a5b5 100644
(file)
--- a/
lib/CodeGen/TwoAddressInstructionPass.cpp
+++ b/
lib/CodeGen/TwoAddressInstructionPass.cpp
@@
-858,6
+858,12
@@
bool TwoAddressInstructionPass::runOnMachineFunction(MachineFunction &MF) {
}
}
}
+
+ // We're really going to nuke the old inst. If regB was marked
+ // as a kill we need to update its Kills list.
+ if (mi->getOperand(si).isKill())
+ LV->removeVirtualRegisterKilled(regB, mi);
+
mbbi->erase(mi); // Nuke the old inst.
mi = nmi;
++NumDeletes;