upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/runtime/shims/xbox_present.cpp
diff options
context:
space:
mode:
authorRyx <118130241+Ryx69@users.noreply.github.com>2026-11-22 04:53:09 +0100
committerRyx <118130241+Ryx69@users.noreply.github.com>2026-11-22 04:55:03 +0100
commit147f9300cf1bfc10f9cc610cb8cb6f075394a26e (patch)
treef7f3e6013e0e869d3881b4b53e79b94c2bfa4132 /runtime/shims/xbox_present.cpp
parent5464be577d6ea07397b56297ee7c571c3d0ce570 (diff)
Runtime: presenter survives failed submits and recreations, and counts only shown frames (review)
From VictorJulianiR's review of the presenter, with Vonsek's measurements: - A failed blit submission left the frame's fence reset with nothing to signal it, so the next present waited forever (Vonsek: the retry reached vkWaitForFences with UINT64_MAX). An empty batch now takes the acquire semaphore and signals the fence, and the swapchain is recreated next time to give back the image that was never presented. If that batch fails too, or a fence wait or reset fails, the presenter stops (ok() is false). A back buffer the device does not know is refused before an image is acquired for it. - A swapchain recreation published the new swapchain before its per-image semaphores existed, so a failed semaphore left a presenter that could submit with a null one. The images and semaphores are now built in local storage and published only when all exist; on a failure the partial objects are released and the next present tries again. - An out-of-date present was counted as presented (Vonsek: 69 VK_SUCCESS and one VK_ERROR_OUT_OF_DATE_KHR reached 70). presented() now counts VK_SUCCESS and VK_SUBOPTIMAL_KHR only; the caller still gets VK_SUCCESS. d3d12_present_test gives the device and presenter their functions through a driver double that forwards to the real driver. It counts real out-of-date presents (the frame counts allow for them) and live binary semaphores. It reports one present as out of date and one as suboptimal, fails the second semaphore of a recreation, and fails one blit submission. Against the old presenter the test fails at the frame count after the resize, where this RTX 5060 Ti reported a real out-of-date present. Docs: the presenter is named as leonida::VulkanPresenter, made by rt::d3d12::create_window_presenter, and the test is described as 60 frames then 10 after a resize (AlxcBTW).
Diffstat (limited to 'runtime/shims/xbox_present.cpp')
0 files changed, 0 insertions, 0 deletions