diff --git a/Source/Core/Core/Core.cpp b/Source/Core/Core/Core.cpp index a433f656657..06100980167 100644 --- a/Source/Core/Core/Core.cpp +++ b/Source/Core/Core/Core.cpp @@ -784,7 +784,7 @@ static bool PauseAndLock(Core::System& system) // video has to come after CPU, because CPU thread can wait for video thread // (s_efbAccessRequested). - system.GetFifo().PauseAndLock(true, false); + system.GetFifo().PauseAndLock(); ResetRumble(); diff --git a/Source/Core/DolphinQt/Host.cpp b/Source/Core/DolphinQt/Host.cpp index 78ff0fae8a8..57586300cfd 100644 --- a/Source/Core/DolphinQt/Host.cpp +++ b/Source/Core/DolphinQt/Host.cpp @@ -106,7 +106,7 @@ static void RunWithGPUThreadInactive(std::function f) auto& system = Core::System::GetInstance(); const bool was_running = Core::GetState(system) == Core::State::Running; auto& fifo = system.GetFifo(); - fifo.PauseAndLock(true, was_running); + fifo.PauseAndLock(); f(); fifo.RestoreState(was_running); } diff --git a/Source/Core/VideoCommon/Fifo.cpp b/Source/Core/VideoCommon/Fifo.cpp index 7e07e0bbf37..ad8761c76ba 100644 --- a/Source/Core/VideoCommon/Fifo.cpp +++ b/Source/Core/VideoCommon/Fifo.cpp @@ -67,23 +67,15 @@ void FifoManager::DoState(PointerWrap& p) p.Do(m_syncing_suspended); } -void FifoManager::PauseAndLock(bool do_lock, bool unpause_on_unlock) +void FifoManager::PauseAndLock() { - if (do_lock) - { - SyncGPU(SyncGPUReason::Other); - EmulatorState(false); + SyncGPU(SyncGPUReason::Other); + EmulatorState(false); - if (!m_system.IsDualCoreMode() || m_use_deterministic_gpu_thread) - return; + if (!m_system.IsDualCoreMode() || m_use_deterministic_gpu_thread) + return; - m_gpu_mainloop.WaitYield(std::chrono::milliseconds(100), Host_YieldToUI); - } - else - { - if (unpause_on_unlock) - EmulatorState(true); - } + m_gpu_mainloop.WaitYield(std::chrono::milliseconds(100), Host_YieldToUI); } void FifoManager::RestoreState(const bool was_running) diff --git a/Source/Core/VideoCommon/Fifo.h b/Source/Core/VideoCommon/Fifo.h index c6fc6376615..2afa110532e 100644 --- a/Source/Core/VideoCommon/Fifo.h +++ b/Source/Core/VideoCommon/Fifo.h @@ -52,7 +52,7 @@ public: void Shutdown(); void Prepare(); // Must be called from the CPU thread. void DoState(PointerWrap& f); - void PauseAndLock(bool do_lock, bool unpause_on_unlock); + void PauseAndLock(); void RestoreState(bool was_running); void UpdateWantDeterminism(bool want); bool UseDeterministicGPUThread() const { return m_use_deterministic_gpu_thread; } diff --git a/Source/Core/VideoCommon/VideoConfig.cpp b/Source/Core/VideoCommon/VideoConfig.cpp index 4c11fb084e8..60668f9f2d7 100644 --- a/Source/Core/VideoCommon/VideoConfig.cpp +++ b/Source/Core/VideoCommon/VideoConfig.cpp @@ -64,7 +64,7 @@ void VideoConfig::Refresh() const bool lock_gpu_thread = Core::IsRunning(system); if (lock_gpu_thread) - system.GetFifo().PauseAndLock(true, false); + system.GetFifo().PauseAndLock(); g_Config.Refresh(); g_Config.VerifyValidity();