mirror of
https://github.com/InstanceBrick/nightcap.git
synced 2026-10-18 09:00:46 +02:00
Uploads decode on a background dispatcher and the submit carries a timeline semaphore wait, so the GPU waits for the texture rather than the render thread. The gather of the application's compressed bytes moves there too when they are already mapped; unmapping or freeing that memory drains the decodes still reading it. Staged copies gain an explicit host-write barrier. A queue submission only makes host writes from before it visible to the device, and these writes land after the submit. Devices without timelineSemaphore, and submits whose pNext already sizes arrays by their semaphore counts, decode inline as before. Blade Ball, median of three: worst vkQueueSubmit 140ms -> 1ms, p99 4.9ms -> 0.05ms, total 2534ms -> 309ms. Frame interval unchanged; its tail is the engine's own main-thread step.