diff options
author | Evan Cheng <evan.cheng@apple.com> | 2008-03-29 18:34:22 +0000 |
---|---|---|
committer | Evan Cheng <evan.cheng@apple.com> | 2008-03-29 18:34:22 +0000 |
commit | 16d72072df3bfe24c8715f75784fe3ad7c91fe65 (patch) | |
tree | b876d98376b77fde21f1c896e9f4957414e81aea | |
parent | 08bae57469fa14b55f806fcde8fddfe6a1b9eb3e (diff) | |
download | bcm5719-llvm-16d72072df3bfe24c8715f75784fe3ad7c91fe65.tar.gz bcm5719-llvm-16d72072df3bfe24c8715f75784fe3ad7c91fe65.zip |
Cosmetic changes.
llvm-svn: 48947
-rw-r--r-- | llvm/lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp | 27 |
1 files changed, 3 insertions, 24 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp b/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp index 024190df6bd..558f5f1bfba 100644 --- a/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp +++ b/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGRRList.cpp @@ -1708,28 +1708,9 @@ void BURegReductionPriorityQueue<SF>::CalculateSethiUllmanNumbers() { CalcNodeSethiUllmanNumber(&(*SUnits)[i]); } -#if 0 -static unsigned SumOfUnscheduledPredsOfSuccs(const SUnit *SU) { - unsigned Sum = 0; - for (SUnit::const_succ_iterator I = SU->Succs.begin(), E = SU->Succs.end(); - I != E; ++I) { - SUnit *SuccSU = I->Dep; - for (SUnit::const_pred_iterator II = SuccSU->Preds.begin(), - EE = SuccSU->Preds.end(); II != EE; ++II) { - SUnit *PredSU = II->Dep; - if (!PredSU->isScheduled) - ++Sum; - } - } - - return Sum; -} -#endif - /// LimitedSumOfUnscheduledPredsOfSuccs - Compute the sum of the unscheduled /// predecessors of the successors of the SUnit SU. Stop when the provided /// limit is exceeded. - static unsigned LimitedSumOfUnscheduledPredsOfSuccs(const SUnit *SU, unsigned Limit) { unsigned Sum = 0; @@ -1739,11 +1720,9 @@ static unsigned LimitedSumOfUnscheduledPredsOfSuccs(const SUnit *SU, for (SUnit::const_pred_iterator II = SuccSU->Preds.begin(), EE = SuccSU->Preds.end(); II != EE; ++II) { SUnit *PredSU = II->Dep; - if (!PredSU->isScheduled) { - ++Sum; - if(Sum > Limit) - return Sum; - } + if (!PredSU->isScheduled) + if (++Sum > Limit) + return Sum; } } return Sum; |