Threads: Use a dummy idle thread when no other are ready.
This thread will not actually execute instructions, it will only advance the timing/events and try to yield immediately to the next ready thread, if there aren't any ready threads then it will be rescheduled and start its job again.
This commit is contained in:
parent
b659cac2dc
commit
60a373a786
4 changed files with 47 additions and 2 deletions
|
@ -124,6 +124,8 @@ bool LoadExec(u32 entry_point) {
|
|||
|
||||
// 0x30 is the typical main thread priority I've seen used so far
|
||||
g_main_thread = Kernel::SetupMainThread(0x30);
|
||||
// Setup the idle thread
|
||||
Kernel::SetupIdleThread();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue