Lines Matching refs:SU
56 if (SUnit *SU = Sequence[i]) in dumpSchedule() local
57 SU->dump(this); in dumpSchedule()
173 SUnit *SU = WorkList.pop_back_val(); in setDepthDirty() local
174 SU->isDepthCurrent = false; in setDepthDirty()
175 for (SUnit::const_succ_iterator I = SU->Succs.begin(), in setDepthDirty()
176 E = SU->Succs.end(); I != E; ++I) { in setDepthDirty()
189 SUnit *SU = WorkList.pop_back_val(); in setHeightDirty() local
190 SU->isHeightCurrent = false; in setHeightDirty()
191 for (SUnit::const_pred_iterator I = SU->Preds.begin(), in setHeightDirty()
192 E = SU->Preds.end(); I != E; ++I) { in setHeightDirty()
444 SUnit *SU = &SUnits[i]; in InitDAGTopologicalSorting() local
445 int NodeNum = SU->NodeNum; in InitDAGTopologicalSorting()
446 unsigned Degree = SU->Succs.size(); in InitDAGTopologicalSorting()
452 assert(SU->Succs.empty() && "SUnit should have no successors"); in InitDAGTopologicalSorting()
454 WorkList.push_back(SU); in InitDAGTopologicalSorting()
460 SUnit *SU = WorkList.back(); in InitDAGTopologicalSorting() local
462 Allocate(SU->NodeNum, --Id); in InitDAGTopologicalSorting()
463 for (SUnit::const_pred_iterator I = SU->Preds.begin(), E = SU->Preds.end(); in InitDAGTopologicalSorting()
465 SUnit *SU = I->getSUnit(); in InitDAGTopologicalSorting() local
466 if (!--Node2Index[SU->NodeNum]) in InitDAGTopologicalSorting()
469 WorkList.push_back(SU); in InitDAGTopologicalSorting()
478 SUnit *SU = &SUnits[i]; in InitDAGTopologicalSorting() local
479 for (SUnit::const_pred_iterator I = SU->Preds.begin(), E = SU->Preds.end(); in InitDAGTopologicalSorting()
481 assert(Node2Index[SU->NodeNum] > Node2Index[I->getSUnit()->NodeNum] && in InitDAGTopologicalSorting()
516 void ScheduleDAGTopologicalSort::DFS(const SUnit *SU, int UpperBound, in DFS() argument
521 WorkList.push_back(SU); in DFS()
523 SU = WorkList.back(); in DFS()
525 Visited.set(SU->NodeNum); in DFS()
526 for (int I = SU->Succs.size()-1; I >= 0; --I) { in DFS()
527 int s = SU->Succs[I].getSUnit()->NodeNum; in DFS()
534 WorkList.push_back(SU->Succs[I].getSUnit()); in DFS()
570 bool ScheduleDAGTopologicalSort::WillCreateCycle(SUnit *SU, SUnit *TargetSU) { in WillCreateCycle() argument
571 if (IsReachable(TargetSU, SU)) in WillCreateCycle()
573 for (SUnit::pred_iterator I = SU->Preds.begin(), E = SU->Preds.end(); in WillCreateCycle()
582 bool ScheduleDAGTopologicalSort::IsReachable(const SUnit *SU, in IsReachable() argument
588 UpperBound = Node2Index[SU->NodeNum]; in IsReachable()