nsysnet: Avoid CPU starvation when games call select in a loop

Fixes Just Dance 2018 getting stuck on a black screen during early boot
This commit is contained in:
Exzap
2026-09-20 05:04:21 +02:00
parent 3277f9f9c2
commit 14e74ea33f

View File

@@ -1240,7 +1240,7 @@ void nsysnetExport_select(PPCInterpreter_t* hCPU)
break;
}
// yield thread
PPCCore_switchToScheduler();
coreinit::OSSleepTicks(coreinit::EspressoTime::ConvertNsToTimerTicks(300000)); // sleep 0.3ms so we don't end up with a case where a single select loop starves all other CPU threads (seen in Just Dance 2018)
}
else
{