diff options
author | Evan Cheng <evan.cheng@apple.com> | 2008-04-09 01:30:15 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2008-04-09 01:30:15 +0000 |
commit | 48383898b9643f2a40239e8262f2cfa71795d46f (patch) | |
tree | cb47cfa200600ba84c5c8a1e564bce3a713eafb5 /lib | |
parent | f1823dfacfc0d8dc6664d4f54c42e3c361bb2fd6 (diff) | |
download | external_llvm-48383898b9643f2a40239e8262f2cfa71795d46f.zip external_llvm-48383898b9643f2a40239e8262f2cfa71795d46f.tar.gz external_llvm-48383898b9643f2a40239e8262f2cfa71795d46f.tar.bz2 |
Missed a hasInterval check.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49415 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/CodeGen/SimpleRegisterCoalescing.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/CodeGen/SimpleRegisterCoalescing.cpp b/lib/CodeGen/SimpleRegisterCoalescing.cpp index 3f124c0..acbc911d 100644 --- a/lib/CodeGen/SimpleRegisterCoalescing.cpp +++ b/lib/CodeGen/SimpleRegisterCoalescing.cpp @@ -1655,6 +1655,8 @@ SimpleRegisterCoalescing::TurnCopyIntoImpDef(MachineBasicBlock::iterator &I, LiveInterval &SrcInt = li_->getInterval(SrcReg); if (!SrcInt.empty()) return false; + if (!li_->hasInterval(DstReg)) + return false; LiveInterval &DstInt = li_->getInterval(DstReg); LiveInterval::iterator DstLR = DstInt.FindLiveRangeContaining(CopyIdx); DstInt.removeValNo(DstLR->valno); |