[llvm] r175597 - Avoid recomputing an inserted instruction's SlotIndex.
Cameron Zwarich
zwarich at apple.com
Tue Feb 19 22:46:32 PST 2013
Author: zwarich
Date: Wed Feb 20 00:46:32 2013
New Revision: 175597
URL: http://llvm.org/viewvc/llvm-project?rev=175597&view=rev
Log:
Avoid recomputing an inserted instruction's SlotIndex.
Modified:
llvm/trunk/lib/CodeGen/PHIElimination.cpp
Modified: llvm/trunk/lib/CodeGen/PHIElimination.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/PHIElimination.cpp?rev=175597&r1=175596&r2=175597&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/PHIElimination.cpp (original)
+++ llvm/trunk/lib/CodeGen/PHIElimination.cpp Wed Feb 20 00:46:32 2013
@@ -306,10 +306,9 @@ void PHIElimination::LowerPHINode(Machin
// Update LiveIntervals for the new copy or implicit def.
if (LIS) {
MachineInstr *NewInstr = prior(AfterPHIsIt);
- LIS->InsertMachineInstrInMaps(NewInstr);
+ SlotIndex DestCopyIndex = LIS->InsertMachineInstrInMaps(NewInstr);
SlotIndex MBBStartIndex = LIS->getMBBStartIdx(&MBB);
- SlotIndex DestCopyIndex = LIS->getInstructionIndex(NewInstr);
if (IncomingReg) {
// Add the region from the beginning of MBB to the copy instruction to
// IncomingReg's live interval.
More information about the llvm-commits
mailing list