pipe_create (src/nx/gpu/vk/pipeline.c) builds each graphics pipeline whole: all of its shader stages and all of
the draw state in PipeKey (src/nx/gpu/vk/vk.h) go into one vkCreateGraphicsPipelines. Two things follow:
The workers (pipeline_threads, pipe_worker) make new pipelines while the GPU thread goes on. The recording
thread waits for each one at its bind (vk_pipeline_resolve through bind_pipeline_run in record.c). A draw never
skips for its pipeline, because the skip broke one game's menus (the comment above typedef struct Pipe). So the
time of a full compile is a stall in the frame.
The lock fixes of 92df965c9 moved the waits for the GPU out of vk_lock. Before them, a landing held vk_lock up to
7.9 s while the recording thread waited for a pipeline. They did not change how long the recording thread waits. This
design makes that wait short. It does not change the lock order or the places that wait.
Made from docs/layers/gpu/pipeline-libraries.md at 69237645142c. GPL-3.0-or-later.