mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-12-15 07:39:31 +00:00
Reorder if-else branches as suggested by Bill.
llvm-svn: 76808
This commit is contained in:
parent
6fa63db9be
commit
d1f9f45b05
@ -800,15 +800,15 @@ void LiveInterval::ComputeJoinedWeight(const LiveInterval &Other) {
|
||||
// weight of the non-spilled interval. This can only happen with
|
||||
// iterative coalescers.
|
||||
|
||||
if (weight == HUGE_VALF &&
|
||||
if (Other.weight != HUGE_VALF) {
|
||||
weight += Other.weight;
|
||||
}
|
||||
else if (weight == HUGE_VALF &&
|
||||
!TargetRegisterInfo::isPhysicalRegister(reg)) {
|
||||
// Remove this assert if you have an iterative coalescer
|
||||
assert(0 && "Joining to spilled interval");
|
||||
weight = Other.weight;
|
||||
}
|
||||
else if (Other.weight != HUGE_VALF) {
|
||||
weight += Other.weight;
|
||||
}
|
||||
else {
|
||||
// Otherwise the weight stays the same
|
||||
// Remove this assert if you have an iterative coalescer
|
||||
|
Loading…
Reference in New Issue
Block a user