diff options
author | David Greene <greened@obbligato.org> | 2009-07-22 20:08:25 +0000 |
---|---|---|
committer | David Greene <greened@obbligato.org> | 2009-07-22 20:08:25 +0000 |
commit | 1e2a04ba99034eabb18e5fa41cddac8dbb871679 (patch) | |
tree | 3209a2d776abeb88c23474fe331673a42cf9b695 /llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp | |
parent | b3a1fdc363679f753f9bd16eff3cef160b52dcf6 (diff) | |
download | bcm5719-llvm-1e2a04ba99034eabb18e5fa41cddac8dbb871679.tar.gz bcm5719-llvm-1e2a04ba99034eabb18e5fa41cddac8dbb871679.zip |
Make some changes suggested by Bill and Evan.
llvm-svn: 76775
Diffstat (limited to 'llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp')
-rw-r--r-- | llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp b/llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp index f5d85ab4544..49f7d9a45f8 100644 --- a/llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp +++ b/llvm/lib/CodeGen/SimpleRegisterCoalescing.cpp @@ -1970,23 +1970,7 @@ bool SimpleRegisterCoalescing::SimpleJoin(LiveInterval &LHS, LiveInterval &RHS){ LHS.addKills(LHSValNo, VNI->kills); LHS.MergeRangesInAsValue(RHS, LHSValNo); - // If either of these intervals was spilled, the weight is the - // weight of the non-spilled interval. This can only happen - // with iterative coalescers. - if (LHS.weight == HUGE_VALF && !TargetRegisterInfo::isPhysicalRegister(LHS.reg)) { - // Remove this assert if you have an iterative coalescer - assert(0 && "Joining to spilled interval"); - LHS.weight = RHS.weight; - } - else if (RHS.weight != HUGE_VALF) { - LHS.weight += RHS.weight; - } - else { - // Remove this assert if you have an iterative coalescer - assert(0 && "Joining from spilled interval"); - } - - // Otherwise the LHS weight stays the same + LHS.ComputeJoinedWeight(RHS); // Update regalloc hint if both are virtual registers. if (TargetRegisterInfo::isVirtualRegister(LHS.reg) && |