forked from OSchip/llvm-project
Fix a pasto. Also simplify for Bill's benefit.
llvm-svn: 82505
This commit is contained in:
parent
33f6acbbf1
commit
0dfed43a5b
|
@ -2571,17 +2571,19 @@ void SimpleRegisterCoalescing::CalculateSpillWeights() {
|
|||
continue;
|
||||
|
||||
bool HasDef = mopi.isDef();
|
||||
bool HasUse = mopi.isUse();
|
||||
bool HasUse = !HasDef;
|
||||
for (unsigned j = i+1; j != e; ++j) {
|
||||
const MachineOperand &mopj = MI->getOperand(j);
|
||||
if (!mopj.isReg() || mopj.getReg() != Reg)
|
||||
continue;
|
||||
HasDef |= mopj.isDef();
|
||||
HasUse |= mopj.isUse();
|
||||
if (HasDef && HasUse)
|
||||
break;
|
||||
}
|
||||
|
||||
LiveInterval &RegInt = li_->getInterval(Reg);
|
||||
float Weight = li_->getSpillWeight(HasDef, HasUse, loopDepth+1);
|
||||
float Weight = li_->getSpillWeight(HasDef, HasUse, loopDepth);
|
||||
if (HasDef && isExit) {
|
||||
// Looks like this is a loop count variable update.
|
||||
MachineInstrIndex DefIdx =
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
; RUN: llc < %s -mtriple=arm-apple-darwin9 -stats |& grep asm-printer | grep 161
|
||||
; RUN: llc < %s -mtriple=arm-apple-darwin9 -stats |& grep asm-printer | grep 162
|
||||
|
||||
%"struct.Adv5::Ekin<3>" = type <{ i8 }>
|
||||
%"struct.Adv5::X::Energyflux<3>" = type { double }
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
; RUN: llc < %s -march=x86 -stats |& grep {Number of re-materialization} | grep 2
|
||||
; RUN: llc < %s -march=x86 -stats |& grep {Number of re-materialization} | grep 3
|
||||
; rdar://5761454
|
||||
|
||||
%struct.quad_struct = type { i32, i32, %struct.quad_struct*, %struct.quad_struct*, %struct.quad_struct*, %struct.quad_struct*, %struct.quad_struct* }
|
||||
|
|
Loading…
Reference in New Issue