mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-15 20:29:48 +00:00
Fix the new scheduler assertion checks to work when
the scheduler has inserted no-ops. This fixes the 2006-07-03-schedulers.ll regression on ppc32. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49747 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
ff140fa1f1
commit
5a2d335c4c
@ -1076,6 +1076,7 @@ void ScheduleDAGRRList::ListScheduleBottomUp() {
|
||||
// Verify that all SUnits were scheduled.
|
||||
bool AnyNotSched = false;
|
||||
unsigned DeadNodes = 0;
|
||||
unsigned Noops = 0;
|
||||
for (unsigned i = 0, e = SUnits.size(); i != e; ++i) {
|
||||
if (!SUnits[i].isScheduled) {
|
||||
if (SUnits[i].NumPreds == 0 && SUnits[i].NumSuccs == 0) {
|
||||
@ -1096,8 +1097,11 @@ void ScheduleDAGRRList::ListScheduleBottomUp() {
|
||||
AnyNotSched = true;
|
||||
}
|
||||
}
|
||||
for (unsigned i = 0, e = Sequence.size(); i != e; ++i)
|
||||
if (!Sequence[i])
|
||||
++Noops;
|
||||
assert(!AnyNotSched);
|
||||
assert(Sequence.size() + DeadNodes == SUnits.size() &&
|
||||
assert(Sequence.size() + DeadNodes - Noops == SUnits.size() &&
|
||||
"The number of nodes scheduled doesn't match the expected number!");
|
||||
#endif
|
||||
}
|
||||
@ -1193,6 +1197,7 @@ void ScheduleDAGRRList::ListScheduleTopDown() {
|
||||
// Verify that all SUnits were scheduled.
|
||||
bool AnyNotSched = false;
|
||||
unsigned DeadNodes = 0;
|
||||
unsigned Noops = 0;
|
||||
for (unsigned i = 0, e = SUnits.size(); i != e; ++i) {
|
||||
if (!SUnits[i].isScheduled) {
|
||||
if (SUnits[i].NumPreds == 0 && SUnits[i].NumSuccs == 0) {
|
||||
@ -1213,8 +1218,11 @@ void ScheduleDAGRRList::ListScheduleTopDown() {
|
||||
AnyNotSched = true;
|
||||
}
|
||||
}
|
||||
for (unsigned i = 0, e = Sequence.size(); i != e; ++i)
|
||||
if (!Sequence[i])
|
||||
++Noops;
|
||||
assert(!AnyNotSched);
|
||||
assert(Sequence.size() + DeadNodes == SUnits.size() &&
|
||||
assert(Sequence.size() + DeadNodes - Noops == SUnits.size() &&
|
||||
"The number of nodes scheduled doesn't match the expected number!");
|
||||
#endif
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user