mirror of
https://github.com/Ryujinx/Ryujinx.git
synced 2024-12-23 10:35:34 +00:00
Move prio/core locals inside the lock on yield (#478)
This commit is contained in:
parent
9ace6b9285
commit
2fd23577ce
|
@ -226,11 +226,11 @@ namespace Ryujinx.HLE.HOS.Kernel
|
||||||
|
|
||||||
public void YieldWithLoadBalancing()
|
public void YieldWithLoadBalancing()
|
||||||
{
|
{
|
||||||
|
System.CriticalSectionLock.Lock();
|
||||||
|
|
||||||
int Prio = DynamicPriority;
|
int Prio = DynamicPriority;
|
||||||
int Core = CurrentCore;
|
int Core = CurrentCore;
|
||||||
|
|
||||||
System.CriticalSectionLock.Lock();
|
|
||||||
|
|
||||||
if (SchedFlags != ThreadSchedState.Running)
|
if (SchedFlags != ThreadSchedState.Running)
|
||||||
{
|
{
|
||||||
System.CriticalSectionLock.Unlock();
|
System.CriticalSectionLock.Unlock();
|
||||||
|
|
Loading…
Reference in a new issue