A draw does not wait for the fast link of a mesh pipeline that is known to be compiling.

A draw whose pipeline is missing waits up to 3 ms for its fast link before it is skipped, 6 ms a frame in all. A mesh pipeline has no stage libraries and gets no fast link, so for the 0.2 to 1.1 s of its compile every frame that drew with it lost those milliseconds and skipped the draw all the same. Once such a pipeline has been building for longer than the 8 ms a cached one needs, its draws are skipped at once, as the one-shot mesh draws already are.

Not run in the game yet.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is contained in:
chrg6
2026-11-10 14:52:25 -05:00
parent e8f5f8e01e
commit 682d9c5c50

View File

@@ -3974,6 +3974,9 @@ static int prepare_draw_ex(VkExec *ex, int prim, int32_t count, int restart, int
if (linking) t0 = kern_now_ns();
else w0 = t0 ? t0 : wait_ms ? kern_now_ns() : 0;
vk_exec_ahead(ex);
// A mesh pipeline that is known to be compiling gets no fast link, so the few milliseconds a draw waits
// for one are lost in every frame that meets it until the compile ends, 0.2 to 1.1 s later (MESH_WAIT_MS).
if (wait_ms && linking && mesh && vk_pipeline_building_ms(&s) > MESH_WAIT_MS) wait_ms = 0;
if (wait_ms) p = vk_pipeline_graphics_async(&s, &info, &pending, wait_ms);
}
if (t0 && budget) {