mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-11-30 09:43:45 +01:00
Improve perf of sceKernelCheckCallback().
Some games seem to call this a lot.
This commit is contained in:
1 parent
b77d965e56
commit
f9fc1af5c8
1 file changed
+8
@@ -2696,6 +2696,14 @@ bool __KernelCheckCallbacks() {
|
||||
|
||||
bool __KernelForceCallbacks()
|
||||
{
|
||||
// Let's not check every thread all the time, callbacks are fairly uncommon.
|
||||
if (readyCallbacksCount == 0) {
|
||||
return false;
|
||||
}
|
||||
if (readyCallbacksCount < 0) {
|
||||
ERROR_LOG(HLE, "readyCallbacksCount became negative: %i", readyCallbacksCount);
|
||||
}
|
||||
|
||||
Thread *curThread = __GetCurrentThread();
|
||||
|
||||
bool callbacksProcessed = __KernelCheckThreadCallbacks(curThread, true);
|
||||
|
||||
Reference in new issue
Block a user