mirror of
https://github.com/yuzu-emu/yuzu.git
synced 2024-07-04 23:31:19 +01:00
Scheduler: Fix HLE Threads on guard
This commit is contained in:
parent
3de33348e4
commit
6ed28e15fa
1 changed files with 6 additions and 4 deletions
|
@ -689,10 +689,12 @@ void Scheduler::SwitchToCurrent() {
|
||||||
current_thread = selected_thread;
|
current_thread = selected_thread;
|
||||||
guard.unlock();
|
guard.unlock();
|
||||||
while (!is_context_switch_pending) {
|
while (!is_context_switch_pending) {
|
||||||
current_thread->context_guard.lock();
|
if (current_thread != nullptr) {
|
||||||
if (current_thread->GetSchedulingStatus() != ThreadSchedStatus::Runnable) {
|
current_thread->context_guard.lock();
|
||||||
current_thread->context_guard.unlock();
|
if (current_thread->GetSchedulingStatus() != ThreadSchedStatus::Runnable) {
|
||||||
break;
|
current_thread->context_guard.unlock();
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
std::shared_ptr<Common::Fiber> next_context;
|
std::shared_ptr<Common::Fiber> next_context;
|
||||||
if (current_thread != nullptr) {
|
if (current_thread != nullptr) {
|
||||||
|
|
Loading…
Reference in a new issue