From 7aa29ff12a7b36c35f568b49a887420b2a8051e2 Mon Sep 17 00:00:00 2001 From: chrg6 Date: Fri, 13 Nov 2026 12:31:04 -0500 Subject: [PATCH] Record a pipeline in pipeline-keys.bin at its fast link, not only when its optimised build ends. A session of 2026-11-13 met 46 pipelines late in adult Kokiri Forest (145 draws left out, mesh pipelines usable after up to 782 ms) and ended about 2 s later: the records waited for the optimised builds, and 23 of the 46 never reached the file, so the shared pipeline list folded from it would have missed them. A pipeline is now recorded as soon as a draw can use it. Co-Authored-By: Claude Opus 5.5 --- runtime/vk_pipeline.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/runtime/vk_pipeline.c b/runtime/vk_pipeline.c index dfd8c86a..2486db52 100644 --- a/runtime/vk_pipeline.c +++ b/runtime/vk_pipeline.c @@ -4728,6 +4728,11 @@ static double now_ms(void) { return (double)plat_now_ns() / 1e6; } #define READY_SLOW_MS 50.0 #define READY_LOGS 48 static void ready_note(Pipe *p, int fast) { + // A pipeline goes into pipeline-keys.bin once a draw can use it, so at its fast link too: recorded only when its + // optimised build had finished (job_build), the pipelines met in the last seconds of a session were lost. A session + // of 2026-11-13 met 46 late pipelines in adult Kokiri Forest and ended about 2 s later; 23 of them never reached the + // file, and with it the shared pipeline list (tools/pipeline_list.py merge). keys_note takes each record once. + if (fast && p->job && !p->job->prebuild) keys_note(&p->job->s); if (!p->t_miss) return; double ms = (double)(plat_now_ns() - p->t_miss) / 1e6; p->t_miss = 0;