From: Conor McCarthy cmccarthy@codeweavers.com
Microsoft recommends waking after unlocking for performance reasons. The same reasons may not apply here but it results in a consistent 0.7% framerate lift in Horizon Zero Dawn on RADV. --- dlls/dxgi/swapchain.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/dxgi/swapchain.c b/dlls/dxgi/swapchain.c index d68788b8fc5..36c4716835c 100644 --- a/dlls/dxgi/swapchain.c +++ b/dlls/dxgi/swapchain.c @@ -2345,8 +2345,8 @@ static HRESULT d3d12_swapchain_present(struct d3d12_swapchain *swapchain,
EnterCriticalSection(&swapchain->worker_cs); list_add_tail(&swapchain->worker_ops, &op->entry); - WakeAllConditionVariable(&swapchain->worker_cv); LeaveCriticalSection(&swapchain->worker_cs); + WakeAllConditionVariable(&swapchain->worker_cv);
++swapchain->frame_number; if ((frame_latency_event = swapchain->frame_latency_event))