aboutsummaryrefslogtreecommitdiffstats
path: root/lib/CodeGen/SimpleRegisterCoalescing.cpp
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2007-11-05 06:46:45 +0000
committerEvan Cheng <evan.cheng@apple.com>2007-11-05 06:46:45 +0000
commit5031fd2d32a8ce5e82059928396e0c659e2a7c27 (patch)
treedfbcbc48fd7170d7689763cd68509a52b2cc1426 /lib/CodeGen/SimpleRegisterCoalescing.cpp
parent5942efb0e5f49fb772e340c251502cc0a7ff157e (diff)
downloadexternal_llvm-5031fd2d32a8ce5e82059928396e0c659e2a7c27.tar.gz
external_llvm-5031fd2d32a8ce5e82059928396e0c659e2a7c27.tar.bz2
external_llvm-5031fd2d32a8ce5e82059928396e0c659e2a7c27.zip
Skip over deleted val#'s.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43700 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/SimpleRegisterCoalescing.cpp')
-rw-r--r--lib/CodeGen/SimpleRegisterCoalescing.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/CodeGen/SimpleRegisterCoalescing.cpp b/lib/CodeGen/SimpleRegisterCoalescing.cpp
index 0d90128bee..9993b633ad 100644
--- a/lib/CodeGen/SimpleRegisterCoalescing.cpp
+++ b/lib/CodeGen/SimpleRegisterCoalescing.cpp
@@ -805,7 +805,7 @@ bool SimpleRegisterCoalescing::JoinIntervals(LiveInterval &LHS,
i != e; ++i) {
VNInfo *VNI = *i;
unsigned ValSrcReg = VNI->reg;
- if (ValSrcReg == 0) // Src not defined by a copy?
+ if (VNI->def == ~1U ||ValSrcReg == 0) // Src not defined by a copy?
continue;
// DstReg is known to be a register in the LHS interval. If the src is
@@ -823,7 +823,7 @@ bool SimpleRegisterCoalescing::JoinIntervals(LiveInterval &LHS,
i != e; ++i) {
VNInfo *VNI = *i;
unsigned ValSrcReg = VNI->reg;
- if (ValSrcReg == 0) // Src not defined by a copy?
+ if (VNI->def == ~1U || ValSrcReg == 0) // Src not defined by a copy?
continue;
// DstReg is known to be a register in the RHS interval. If the src is