From: Evan Cheng Date: Fri, 2 Mar 2007 10:41:15 +0000 (+0000) Subject: Dead live-in detection bug. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=7b466d048110ec149446bfb9856f79b7b17cf5d3;p=oota-llvm.git Dead live-in detection bug. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34843 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/CodeGen/LiveIntervalAnalysis.cpp b/lib/CodeGen/LiveIntervalAnalysis.cpp index a5907d6067e..26d741f6898 100644 --- a/lib/CodeGen/LiveIntervalAnalysis.cpp +++ b/lib/CodeGen/LiveIntervalAnalysis.cpp @@ -938,11 +938,11 @@ bool LiveIntervals::JoinCopy(MachineInstr *CopyMI, if (JoinIntervals(DestInt, SrcInt)) { if (isDead) { // Result of the copy is dead. Propagate this property. - if (SrcStart == 0 && MRegisterInfo::isPhysicalRegister(SrcReg)) { + if (SrcStart == 0 && MRegisterInfo::isPhysicalRegister(repSrcReg)) { // Live-in to the function but dead. Remove it from MBB live-in set. // JoinIntervals may end up swapping the two intervals. MachineBasicBlock *MBB = CopyMI->getParent(); - MBB->removeLiveIn(SrcReg); + MBB->removeLiveIn(repSrcReg); } else { MachineInstr *SrcMI = getInstructionFromIndex(SrcStart); if (SrcMI) {