summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGList.cpp
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2008-11-17 21:31:02 +0000
committerDan Gohman <gohman@apple.com>2008-11-17 21:31:02 +0000
commit92a36d7a7804e6c45b46debd8e0f0d16ae8e41d5 (patch)
tree139c3dd150e654a439950135d79935a24a40921e /llvm/lib/CodeGen/SelectionDAG/ScheduleDAGList.cpp
parentf046b50ecdd64ed95743df69a2178dfcb0addf82 (diff)
downloadbcm5719-llvm-92a36d7a7804e6c45b46debd8e0f0d16ae8e41d5.tar.gz
bcm5719-llvm-92a36d7a7804e6c45b46debd8e0f0d16ae8e41d5.zip
Eliminate some trivial differences between the ScheduleNodeTopDown
functions in these two schedulers. llvm-svn: 59465
Diffstat (limited to 'llvm/lib/CodeGen/SelectionDAG/ScheduleDAGList.cpp')
-rw-r--r--llvm/lib/CodeGen/SelectionDAG/ScheduleDAGList.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGList.cpp b/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGList.cpp
index 901a2a8c921..4611ec1c597 100644
--- a/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGList.cpp
+++ b/llvm/lib/CodeGen/SelectionDAG/ScheduleDAGList.cpp
@@ -148,11 +148,14 @@ void ScheduleDAGList::ScheduleNodeTopDown(SUnit *SU, unsigned CurCycle) {
Sequence.push_back(SU);
SU->Cycle = CurCycle;
-
+
// Top down: release successors.
for (SUnit::succ_iterator I = SU->Succs.begin(), E = SU->Succs.end();
I != E; ++I)
ReleaseSucc(I->Dep, I->isCtrl);
+
+ SU->isScheduled = true;
+ AvailableQueue->ScheduledNode(SU);
}
/// ListScheduleTopDown - The main loop of list scheduling for top-down
@@ -235,8 +238,6 @@ void ScheduleDAGList::ListScheduleTopDown() {
if (FoundSUnit) {
ScheduleNodeTopDown(FoundSUnit, CurCycle);
HazardRec->EmitInstruction(FoundNode);
- FoundSUnit->isScheduled = true;
- AvailableQueue->ScheduledNode(FoundSUnit);
// If this is a pseudo-op node, we don't want to increment the current
// cycle.
OpenPOWER on IntegriCloud