void __KernelReturnFromInterrupt() { VERBOSE_LOG(SCEINTC, "Left interrupt handler at %08x", currentMIPS->pc); hleSkipDeadbeef(); // This is what we just ran. PendingInterrupt pend = pendingInterrupts.front(); pendingInterrupts.pop_front(); intrHandlers[pend.intr]->handleResult(pend); inInterrupt = false; // Restore context after running the interrupt. intState.restore(); // All should now be back to normal, including PC. // Alright, let's see if there's any more interrupts queued... if (!__RunOnePendingInterrupt()) { // Otherwise, we reschedule when dispatch was enabled, or switch back otherwise. if (__KernelIsDispatchEnabled()) __KernelReSchedule("left interrupt"); else __KernelSwitchToThread(threadBeforeInterrupt, "left interrupt"); } }
void UnitTestTerminator() { // Bails out of jit so we can time things. coreState = CORE_POWERDOWN; hleSkipDeadbeef(); }