Commit graph

5 commits

Author SHA1 Message Date
Subv
00decc1180 Fixed the codestyle to match our clang-format rules. 2016-12-14 12:35:01 -05:00
Subv
d4815e828d 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
44c59feca6 Threading: Added some utility functions and const correctness. 2016-12-04 09:58:36 -05:00
Subv
5bc10a74f6 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
wwylele
8b25c12ce8 implement wait tree widget 2016-09-22 13:52:52 +08:00