mirror of
https://github.com/stenzek/duckstation.git
synced 2025-06-07 20:15:32 +00:00
GPUBackend: Only display CPU thread blocked messages if queueing
This commit is contained in:
parent
88cd086633
commit
b2c8d25638
@ -292,7 +292,9 @@ bool GPUBackend::BeginQueueFrame()
|
|||||||
if (queued_frames <= g_settings.gpu_max_queued_frames)
|
if (queued_frames <= g_settings.gpu_max_queued_frames)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
DEV_LOG("<-- {} queued frames, {} max, blocking CPU thread", queued_frames, g_settings.gpu_max_queued_frames);
|
if (g_settings.gpu_max_queued_frames > 0)
|
||||||
|
DEV_LOG("<-- {} queued frames, {} max, blocking CPU thread", queued_frames, g_settings.gpu_max_queued_frames);
|
||||||
|
|
||||||
s_cpu_thread_state.waiting_for_gpu_thread.store(true, std::memory_order_release);
|
s_cpu_thread_state.waiting_for_gpu_thread.store(true, std::memory_order_release);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@ -733,7 +735,9 @@ void GPUBackend::HandleSubmitFrameCommand(const GPUBackendFramePresentationParam
|
|||||||
if (s_cpu_thread_state.waiting_for_gpu_thread.compare_exchange_strong(expected, false, std::memory_order_acq_rel,
|
if (s_cpu_thread_state.waiting_for_gpu_thread.compare_exchange_strong(expected, false, std::memory_order_acq_rel,
|
||||||
std::memory_order_relaxed))
|
std::memory_order_relaxed))
|
||||||
{
|
{
|
||||||
DEV_LOG("--> Unblocking CPU thread");
|
if (g_settings.gpu_max_queued_frames > 0)
|
||||||
|
DEV_LOG("--> Unblocking CPU thread");
|
||||||
|
|
||||||
s_cpu_thread_state.gpu_thread_wait.Post();
|
s_cpu_thread_state.gpu_thread_wait.Post();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user