[llvm-commits] [llvm] r51922 - /llvm/trunk/lib/CodeGen/StrongPHIElimination.cpp
Owen Anderson
resistor at mac.com
Tue Jun 3 17:38:57 PDT 2008
Author: resistor
Date: Tue Jun 3 19:38:56 2008
New Revision: 51922
URL: http://llvm.org/viewvc/llvm-project?rev=51922&view=rev
Log:
We need to subtract one from this index because live ranges are open at the end.
Modified:
llvm/trunk/lib/CodeGen/StrongPHIElimination.cpp
Modified: llvm/trunk/lib/CodeGen/StrongPHIElimination.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/StrongPHIElimination.cpp?rev=51922&r1=51921&r2=51922&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/StrongPHIElimination.cpp (original)
+++ llvm/trunk/lib/CodeGen/StrongPHIElimination.cpp Tue Jun 3 19:38:56 2008
@@ -467,7 +467,7 @@
} else {
// Otherwise, add it to the renaming set
LiveInterval& I = LI.getOrCreateInterval(SrcReg);
- unsigned idx = LI.getMBBEndIdx(P->getOperand(i).getMBB());
+ unsigned idx = LI.getMBBEndIdx(P->getOperand(i).getMBB()) - 1;
VNInfo* VN = I.getLiveRangeContaining(idx)->valno;
assert(VN && "No VNInfo for register?");
More information about the llvm-commits
mailing list