aboutsummaryrefslogtreecommitdiff
path: root/lib/CodeGen
diff options
context:
space:
mode:
authorLang Hames <lhames@gmail.com>2012-02-15 01:31:10 +0000
committerLang Hames <lhames@gmail.com>2012-02-15 01:31:10 +0000
commitf58e37f957191a3e41f605628c6169fbb1d4f922 (patch)
treef08c434884e3e1f746487b6cb91514572b5f2241 /lib/CodeGen
parentda7984fbbac967ddbe5de4e789f8f37c673a7d75 (diff)
Don't emit live ranges for physregs live-ins that are dead.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@150553 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen')
-rw-r--r--lib/CodeGen/LiveIntervalAnalysis.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/CodeGen/LiveIntervalAnalysis.cpp b/lib/CodeGen/LiveIntervalAnalysis.cpp
index d27b8e5fd9..f99f8cfbc9 100644
--- a/lib/CodeGen/LiveIntervalAnalysis.cpp
+++ b/lib/CodeGen/LiveIntervalAnalysis.cpp
@@ -529,9 +529,10 @@ void LiveIntervals::handleLiveInRegister(MachineBasicBlock *MBB,
if (!SeenDefUse) {
if (isAllocatable(interval.reg) || isReserved(interval.reg)) {
// This must be an entry block or landing pad - we asserted so on entry
- // to the function. For these blocks the interval is dead on entry.
+ // to the function. For these blocks the interval is dead on entry, so
+ // we won't emit a live-range for it.
DEBUG(dbgs() << " dead");
- end = start.getDeadSlot();
+ return;
} else {
assert(isRegLiveOutOf(MBB, interval.reg) &&
"Live in reg untouched in block should be be live through.");