From 889ab7d15888f64826009cded172f0dced5b590c Mon Sep 17 00:00:00 2001 From: Jakob Stoklund Olesen Date: Thu, 24 Jun 2010 23:57:35 +0000 Subject: [PATCH] Make sure all eliminated kills are removed from VNInfo lists. This fixes PR7479 and PR7485. The test cases from those PRs are big, so not included. However, PR7485 comes from self hosting on FreeBSD, so we will surely hear about any regression. llvm-svn: 106811 --- llvm/lib/CodeGen/LiveInterval.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/llvm/lib/CodeGen/LiveInterval.cpp b/llvm/lib/CodeGen/LiveInterval.cpp index 7eb430db4803..bf0bdd183c8f 100644 --- a/llvm/lib/CodeGen/LiveInterval.cpp +++ b/llvm/lib/CodeGen/LiveInterval.cpp @@ -484,6 +484,8 @@ void LiveInterval::join(LiveInterval &Other, I->valno = NewVNInfo[OtherAssignments[RangeNo]]; assert(I->valno && "Adding a dead range?"); InsertPos = addRangeFrom(*I, InsertPos); + InsertPos->valno->removeKills(InsertPos->start, + InsertPos->end.getPrevSlot()); } ComputeJoinedWeight(Other);