diff options
author | Alkis Evlogimenos <alkis@evlogimenos.com> | 2003-12-13 05:50:19 +0000 |
---|---|---|
committer | Alkis Evlogimenos <alkis@evlogimenos.com> | 2003-12-13 05:50:19 +0000 |
commit | 7d65a12fe660b10c5a10a3f0a655aa4e4a7fe365 (patch) | |
tree | 8e5025014272a0d7accecda56aaf43e538d41e5a | |
parent | f6e610c27dcc681a427862a8bcd63908eb31fa3c (diff) |
Expire any active intervals left when register allocation is done.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10448 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/CodeGen/RegAllocLinearScan.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/lib/CodeGen/RegAllocLinearScan.cpp b/lib/CodeGen/RegAllocLinearScan.cpp index a50574c454..8645a2b044 100644 --- a/lib/CodeGen/RegAllocLinearScan.cpp +++ b/lib/CodeGen/RegAllocLinearScan.cpp @@ -269,6 +269,18 @@ bool RA::runOnMachineFunction(MachineFunction &fn) { } } } + // expire any remaining active intervals + for (IntervalPtrs::iterator i = active_.begin(); i != active_.end(); ++i) { + unsigned reg = (*i)->reg; + DEBUG(std::cerr << "\t\tinterval " << **i << " expired\n"); + if (reg < MRegisterInfo::FirstVirtualRegister) { + clearReservedPhysReg(reg); + } + else { + p2vMap_[v2pMap_[reg]] = 0; + } + // remove interval from active + } DEBUG(std::cerr << "finished register allocation\n"); DEBUG(printVirt2PhysMap()); |