summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJakob Stoklund Olesen <stoklund@2pi.dk>2011-04-12 18:11:28 +0000
committerJakob Stoklund Olesen <stoklund@2pi.dk>2011-04-12 18:11:28 +0000
commit68e84581c5155b238b455bea62314d92650e3787 (patch)
tree9a8f68349970d4e6a209eb59d29753d2311be95d
parent4547a9e658d5df7ab54b7508dc77063e41346250 (diff)
downloadbcm5719-llvm-68e84581c5155b238b455bea62314d92650e3787.tar.gz
bcm5719-llvm-68e84581c5155b238b455bea62314d92650e3787.zip
Fix a bug in RegAllocBase::addMBBLiveIns() where a basic block could accidentally be skipped.
llvm-svn: 129373
-rw-r--r--llvm/lib/CodeGen/RegAllocBasic.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/RegAllocBasic.cpp b/llvm/lib/CodeGen/RegAllocBasic.cpp
index af7da53b89b..dd5049898d9 100644
--- a/llvm/lib/CodeGen/RegAllocBasic.cpp
+++ b/llvm/lib/CodeGen/RegAllocBasic.cpp
@@ -429,7 +429,7 @@ void RegAllocBase::addMBBLiveIns(MachineFunction *MF) {
if (!MBB->isLiveIn(PhysReg))
MBB->addLiveIn(PhysReg);
} else if (SI.start() > Stop)
- MBB = Indexes->getMBBFromIndex(SI.start());
+ MBB = Indexes->getMBBFromIndex(SI.start().getPrevIndex());
if (++MBB == MFE)
break;
tie(Start, Stop) = Indexes->getMBBRange(MBB);
OpenPOWER on IntegriCloud