mirror of
https://github.com/tangerineturtle1/NX2navi.git
synced 2026-11-17 11:29:58 -04:00
Build the shared pipeline list before play on every start, and build every listed pipeline at install.
A new install met every pipeline in play: in Hyrule Field one 600-frame stretch of a first visit had 1,769 draws wait 461 ms in all for pipelines, the longest frame 88 ms. The boot now reads seed-pipeline-keys.bin, the release's list, as recorded pipelines after the install's own (keys_open_seed, NX2NAVI_PIPE_SEED, default 1): their pairs go into the vertex output unions and the prewarm builds them as it builds the install's. The preparation builds every listed pipeline (NX2NAVI_PREPARE_PIPELINES now defaults to all), with the unions of the same list, so the first boot of a new install finds them in the caches. The list's mesh pipelines are left out at the boot on a GPU without mesh shaders, as the preparation leaves them out. Nothing of the list goes into pipeline-keys.bin. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -160,15 +160,18 @@ of them.
|
||||
|
||||
What this step leaves for play, and the shared pipeline list. The step translates every shader's default variant
|
||||
and the shader list's variants and builds each one's stage library or compute pipeline. A whole graphics pipeline
|
||||
is built ahead only at the start of a game folder that has drawn it before (`pipeline-keys.bin`); a pipeline met
|
||||
for the first time is linked from its stage libraries in 2 to 6 ms, except a mesh pipeline, which has no libraries
|
||||
and compiles whole (0.2 to 1.1 s, its draws left out of the picture meanwhile). `tools/pipeline_list.py merge`
|
||||
folds the `pipeline-keys.bin` and `shader-answers.bin` of game folders that were played into a pipeline list;
|
||||
`prepare_shaders.py` reads it from `tools\data\pipeline_list.bin` (`data\pipeline_list.bin` in a release folder, or
|
||||
`--pipeline-list`), adds the shader variants it names to the seed and writes its records next to the game as
|
||||
`seed-pipeline-keys.bin`, and `--prepare-shaders` builds the mesh pipelines among them into the pipeline cache and
|
||||
the driver's (`runtime/vk_pipeline.c` `seed_pipelines`; `NX2NAVI_PREPARE_PIPELINES=all` builds the vertex pipelines
|
||||
too). `--warm-shaders` builds them again, and `nx2navi.exe --prepare-pipelines` does that step alone. The list is
|
||||
is built ahead at the start of a game folder that has drawn it before (`pipeline-keys.bin`) or whose release
|
||||
listed it (below); a pipeline met for the first time is linked from its stage libraries in 2 to 6 ms, except a mesh
|
||||
pipeline, which has no libraries and compiles whole (0.2 to 1.1 s, its draws left out of the picture meanwhile),
|
||||
and many of them on a first visit add up to hitches. `tools/pipeline_list.py merge` folds the `pipeline-keys.bin`
|
||||
and `shader-answers.bin` of game folders that were played into a pipeline list; `prepare_shaders.py` reads it from
|
||||
`tools\data\pipeline_list.bin` (`data\pipeline_list.bin` in a release folder, or `--pipeline-list`), adds the
|
||||
shader variants it names to the seed and writes its records next to the game as `seed-pipeline-keys.bin`, and
|
||||
`--prepare-shaders` builds every one of them into the pipeline cache and the driver's (`runtime/vk_pipeline.c`
|
||||
`seed_pipelines`; `NX2NAVI_PREPARE_PIPELINES=mesh` builds only the mesh pipelines). Every start then counts the
|
||||
list as known pipelines beside the folder's own and builds them before play, from those caches (`keys_open_seed`;
|
||||
`pipe_seed = 0` in `nx2navi.ini` leaves the list out). `--warm-shaders` builds them again, and
|
||||
`nx2navi.exe --prepare-pipelines` does that step alone. The list is
|
||||
derived from game data: it is not in the repository (`tools/check_content.py` refuses it), and a kit, a launcher
|
||||
release or an installer release takes one with `--pipeline-list` (`tools/make_kit.py`, `make_launcher.py`,
|
||||
`make_release.py`). A list belongs to the record layout of the runtime that wrote it; another runtime says so and
|
||||
|
||||
Reference in New Issue
Block a user