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 <noreply@anthropic.com>
This commit is contained in:
chrg6
2026-11-13 12:31:04 -05:00
parent 0e0cfe0827
commit 7aa29ff12a

View File

@@ -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;