Commit Graph

8 Commits

Author SHA1 Message Date
bunnei d4f9119dba core: Consolidate core and system state, remove system module & cleanups. 2016-12-21 23:29:13 -05:00
bunnei 1e01fd893e Merge pull request #2260 from Subv/scheduling
Threading: Reworked the way our scheduler works.
2016-12-16 00:41:22 -05:00
Subv c6a9bce77a Fixed the codestyle to match our clang-format rules. 2016-12-14 12:35:01 -05:00
Subv 93c592f312 WaitSynch: Removed unused variables and reduced SharedPtr copies.
Define a variable with the value of the sync timeout error code.

Use a boost::flat_map instead of an unordered_map to hold the equivalence of objects and wait indices in a WaitSynchN call.
2016-12-09 12:23:09 -05:00
Subv 7e5b90a04b Threading: Added some utility functions and const correctness. 2016-12-04 09:58:36 -05:00
Subv e3486361fd Threading: Reworked the way our scheduler works.
Threads will now be awakened when the objects they're waiting on are signaled, instead of repeating the WaitSynchronization call every now and then.

The scheduler is now called once after every SVC call, and once after a thread is awakened from sleep by its timeout callback.

This new implementation is based off reverse-engineering of the real kernel.

See https://gist.github.com/Subv/02f29bd9f1e5deb7aceea1e8f019c8f4 for a more detailed description of how the real kernel handles rescheduling.
2016-12-03 22:38:14 -05:00
Subv 694df935a6 Fixed the rebase mistakes. 2016-11-30 23:28:31 -05:00
wwylele 7a4bb69d51 implement wait tree widget 2016-09-22 13:52:52 +08:00