aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen/LiveIntervalAnalysis.cpp
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2007-12-05 09:51:10 +0000
committerEvan Cheng <evan.cheng@apple.com>2007-12-05 09:51:10 +0000
commitadf85906906ebf85c57c333e8209f37ef11a6c99 (patch)
tree55b3befe185f93909e364cb2129927f51f997987 /lib/CodeGen/LiveIntervalAnalysis.cpp
parentf38d14f03e495ea98ae16bda6febbde276513294 (diff)
If a split live interval is spilled again, remove the kill marker on its last use.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44611 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/LiveIntervalAnalysis.cpp')
-rw-r--r--lib/CodeGen/LiveIntervalAnalysis.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/CodeGen/LiveIntervalAnalysis.cpp b/lib/CodeGen/LiveIntervalAnalysis.cpp
index b237247f7f..b321b3fdf6 100644
--- a/lib/CodeGen/LiveIntervalAnalysis.cpp
+++ b/lib/CodeGen/LiveIntervalAnalysis.cpp
@@ -1165,6 +1165,7 @@ addIntervalsForSpills(const LiveInterval &li,
// it's also guaranteed to be a single val# / range interval.
if (vrm.getPreSplitReg(li.reg)) {
vrm.setIsSplitFromReg(li.reg, 0);
+ vrm.removeKillPoint(li.reg);
bool DefIsReMat = vrm.isReMaterialized(li.reg);
Slot = vrm.getStackSlot(li.reg);
assert(Slot != VirtRegMap::MAX_STACK_SLOT);
@@ -1398,8 +1399,10 @@ addIntervalsForSpills(const LiveInterval &li,
int UseIdx = LastUse->findRegisterUseOperandIdx(LI->reg);
assert(UseIdx != -1);
if (LastUse->getInstrDescriptor()->
- getOperandConstraint(UseIdx, TOI::TIED_TO) == -1)
+ getOperandConstraint(UseIdx, TOI::TIED_TO) == -1) {
LastUse->getOperand(UseIdx).setIsKill();
+ vrm.addKillPoint(LI->reg, &LastUse->getOperand(UseIdx));
+ }
}
RetNewLIs.push_back(LI);
}