summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Greene <greened@obbligato.org>2009-11-19 19:09:39 +0000
committerDavid Greene <greened@obbligato.org>2009-11-19 19:09:39 +0000
commit50909c0595c9f029798f4b3818fa8b2a7e412ef0 (patch)
tree05a2bc84cd31781a8478e0bad5c8ed320197e365
parent4b35a2ed0841798c90ea283f5d5fe7ba3a58f146 (diff)
downloadbcm5719-llvm-50909c0595c9f029798f4b3818fa8b2a7e412ef0.tar.gz
bcm5719-llvm-50909c0595c9f029798f4b3818fa8b2a7e412ef0.zip
Fix a small bug.
Fix one case we missed to make sure we reserve registers from allocation. llvm-svn: 89376
-rw-r--r--llvm/lib/CodeGen/RegAllocLinearScan.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/CodeGen/RegAllocLinearScan.cpp b/llvm/lib/CodeGen/RegAllocLinearScan.cpp
index be1fa08cfa0..4d6b6891f0d 100644
--- a/llvm/lib/CodeGen/RegAllocLinearScan.cpp
+++ b/llvm/lib/CodeGen/RegAllocLinearScan.cpp
@@ -1435,7 +1435,7 @@ unsigned RALinScan::getFreePhysReg(LiveInterval* cur,
if (SkipDGRegs && DowngradedRegs.count(Reg))
continue;
if (isRegAvail(Reg) && Reg < inactiveCounts.size() &&
- FreeRegInactiveCount < inactiveCounts[Reg]) {
+ FreeRegInactiveCount < inactiveCounts[Reg] && !isRecentlyUsed(Reg)) {
FreeReg = Reg;
FreeRegInactiveCount = inactiveCounts[Reg];
if (FreeRegInactiveCount == MaxInactiveCount)
OpenPOWER on IntegriCloud