Implemented SP, DP, and SI events

Inject a thread pause into infinite loops to allow the idle thread to
yield for event processing
Removed all preemption usage from the scheduler
This commit is contained in:
Mr-Wiseguy 2022-11-18 16:12:39 -05:00
parent b94fe6f5fb
commit 39b67c8468
20 changed files with 449 additions and 113 deletions

View file

@ -21,7 +21,7 @@ void Multilibultra::pause_thread_native_impl(OSThread *t) {
SuspendThread(t->context->host_thread.native_handle());
// Perform a synchronous action to ensure that the thread is suspended
// see: https://devblogs.microsoft.com/oldnewthing/20150205-00/?p=44743
CONTEXT threadContext;
CONTEXT threadContext{};
GetThreadContext(t->context->host_thread.native_handle(), &threadContext);
}