git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@156573
91177308-0d34-0410-b5e6-
96231b3b80d8
bool empty() const { return Queue.empty(); }
+ iterator begin() { return Queue.begin(); }
+
+ iterator end() { return Queue.end(); }
+
iterator find(SUnit *SU) {
return std::find(Queue.begin(), Queue.end(), SU);
}
}
virtual void releaseTopNode(SUnit *SU) {
- TopQueue.push(SU);
+ if (!SU->isScheduled)
+ TopQueue.push(SU);
}
virtual void releaseBottomNode(SUnit *SU) {
- BotQueue.push(SU);
+ if (!SU->isScheduled)
+ BotQueue.push(SU);
}
};
} // namespace