summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/RegAllocLinearScan.cpp
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2007-02-25 09:39:02 +0000
committerEvan Cheng <evan.cheng@apple.com>2007-02-25 09:39:02 +0000
commit220a7af107395309addd9f84411549f463ba9746 (patch)
tree4a24ded9e1dba7429643ab0fa6659e1670542259 /llvm/lib/CodeGen/RegAllocLinearScan.cpp
parentfcee9b55681da8f90b8456ddab32422edc4cd417 (diff)
downloadbcm5719-llvm-220a7af107395309addd9f84411549f463ba9746.tar.gz
bcm5719-llvm-220a7af107395309addd9f84411549f463ba9746.zip
Only add liveinterval to livein set if it isn't assigned a stack slot.
llvm-svn: 34593
Diffstat (limited to 'llvm/lib/CodeGen/RegAllocLinearScan.cpp')
-rw-r--r--llvm/lib/CodeGen/RegAllocLinearScan.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/llvm/lib/CodeGen/RegAllocLinearScan.cpp b/llvm/lib/CodeGen/RegAllocLinearScan.cpp
index 3a1bfc25fe8..76fc5809f52 100644
--- a/llvm/lib/CodeGen/RegAllocLinearScan.cpp
+++ b/llvm/lib/CodeGen/RegAllocLinearScan.cpp
@@ -303,10 +303,10 @@ void RA::linearScan()
for (unsigned i = 0, e = handled_.size(); i != e; ++i) {
LiveInterval *HI = handled_[i];
- if (HI->liveAt(StartIdx)) {
- unsigned Reg = HI->reg;
- if (MRegisterInfo::isVirtualRegister(Reg))
- Reg = vrm_->getPhys(Reg);
+ unsigned Reg = HI->reg;
+ if (!vrm_->hasStackSlot(Reg) && HI->liveAt(StartIdx)) {
+ assert(MRegisterInfo::isVirtualRegister(Reg));
+ Reg = vrm_->getPhys(Reg);
MBB->addLiveIn(Reg);
}
}
OpenPOWER on IntegriCloud