MachineScheduler: Slightly simplify release node

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@282201 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Matthias Braun 2016-09-22 21:39:56 +00:00
parent c3e16a5807
commit a86d297ba3
2 changed files with 11 additions and 21 deletions

View File

@ -718,10 +718,6 @@ public:
void releaseNode(SUnit *SU, unsigned ReadyCycle);
void releaseTopNode(SUnit *SU);
void releaseBottomNode(SUnit *SU);
void bumpCycle(unsigned NextCycle);
void incExecutedResources(unsigned PIdx, unsigned Count);
@ -892,12 +888,18 @@ public:
void schedNode(SUnit *SU, bool IsTopNode) override;
void releaseTopNode(SUnit *SU) override {
Top.releaseTopNode(SU);
if (SU->isScheduled)
return;
Top.releaseNode(SU, SU->TopReadyCycle);
TopCand.SU = nullptr;
}
void releaseBottomNode(SUnit *SU) override {
Bot.releaseBottomNode(SU);
if (SU->isScheduled)
return;
Bot.releaseNode(SU, SU->BotReadyCycle);
BotCand.SU = nullptr;
}
@ -975,7 +977,9 @@ public:
void schedNode(SUnit *SU, bool IsTopNode) override;
void releaseTopNode(SUnit *SU) override {
Top.releaseTopNode(SU);
if (SU->isScheduled)
return;
Top.releaseNode(SU, SU->TopReadyCycle);
}
// Only called for roots.

View File

@ -1995,20 +1995,6 @@ void SchedBoundary::releaseNode(SUnit *SU, unsigned ReadyCycle) {
Available.push(SU);
}
void SchedBoundary::releaseTopNode(SUnit *SU) {
if (SU->isScheduled)
return;
releaseNode(SU, SU->TopReadyCycle);
}
void SchedBoundary::releaseBottomNode(SUnit *SU) {
if (SU->isScheduled)
return;
releaseNode(SU, SU->BotReadyCycle);
}
/// Move the boundary of scheduled code by one cycle.
void SchedBoundary::bumpCycle(unsigned NextCycle) {
if (SchedModel->getMicroOpBufferSize() == 0) {