GPU pipeline cache: retain first-used keys when the warmup list fills #3668
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/3668"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T04:50:22Z.
When a run uses more than 8,192 distinct pipeline keys, the warmup list takes a subset in
HashSetorder. That can discard pipelines used during the first frames. Save the first uses observed in this run in order and retain the previous runs' order for any remaining slots. The limit and the one-key-per-line file format stay the same.I compared the exact old and new list logic over 40 runs with 10,240 generated keys. In a group of the first 512, the old list retained 391–424 keys, with a median of 410. The new list kept all 512 and saved exactly the first 8,192 keys on every run. Duplicate uses, mixed old and new keys and reading a saved list are covered. This measures list retention on generated input.
All 15 pipeline library and worker-queue tests passed, along with strict GPU Clippy and the asset policy.
Please retain the Git author on cherry-pick or rebase, or add
Co-authored-by: andrewpozdnakov7-jpg <[email protected]>if folding this change into another commit.AI-assisted with OpenAI Codex.
Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T04:53:48Z.
Windows CI passed at
8c2792e, including Clippy on both build configurations and the repository test job. The 40 comparisons in the description apply to the same commit. The warmup file contained the first 8,192 observed keys in every trial.The next run uses those retained keys for early pipeline starts. The next step is maintainer review.
Please retain the Git author on cherry-pick or rebase, or add
Co-authored-by: andrewpozdnakov7-jpg <[email protected]>if folding this change into another commit.AI-assisted with OpenAI Codex.
Imported from Marvisak/VIctory. Originally posted by andrewpozdnakov7-jpg on 2026-11-28T05:17:27Z.
I checked #3668 with #3188 and #2328 on
63bcca43. Combined commit26fbae7preserves all three heads. The resolution keeps the save mutex around early-only and full saves, and retains the tests for ordered keys and both lock modes.A temporary restart fixture on app-local WARP 1.0.22 with Agility 1.620.2 recorded 10,240 generated keys twice each. I blocked the first replacement of
early-pipelines.txtin a fresh test directory. The retry saved exactly the first 8,192 keys in first-use order. The seeded library and prebuilt manifest matched byte for byte before and after the retry. In a fresh process,wanted_earlyfound all 8,192 saved keys and excluded all 2,048 later keys and the displaced previous-run key.All 17 existing pipeline-library tests passed. Strict all-features GPU Clippy and the asset policy passed. This checks cache files and the lookup on restart with synthetic data. Game startup timing was outside the run.
Please retain the Git authors on cherry-pick or rebase, or add
Co-authored-by: andrewpozdnakov7-jpg <[email protected]>if folding the integration into another commit.AI-assisted with OpenAI Codex.
Imported from Marvisak/VIctory. Originally posted by cloph-dsp on 2026-11-28T12:24:00Z.
Independent local verification (Windows, Rust 1.100.0/MSVC, no game data):
8c2792e4f6fd88be374c789356433d1aa2c99c58, base/parent63bcca43c6a00a758510398fa43096ce7e4f7df0.cargo test --locked -p victory-gpu --lib -- pipeline::library::tests::a_run_over_capacity_keeps_its_earliest_pipeline_uses --exact --test-threads=1 --quiet→ 1 passed, 0 failed, 232 filtered, exit 0.git grep -Ffor the test name on the base returned no match (test is new on this PR);git diff --check 63bcca4 HEADclean (1 file, +54/-14).CARGO_TARGET_DIR(never shared) withCARGO_BUILD_JOBS=2.AI-assisted (Hy4 flash).
Imported from Marvisak/VIctory. Originally posted by futurepro62 on 2026-11-29T23:46:55Z.
NVIDIA full-suite run, to go with the reports above by cloph-dsp, since none of them names a GPU run. Tested exact head
8c2792e(on its base63bcca4).Tested
dxil.dllfrom Windows SDK 10.0.26100 (the loader's default), debug.cargo build --workspace --locked, thencargo test --workspace --locked --no-fail-fast -- --test-threads=4 --skip emit::memory_tests::heap_direct_texture_reads_mark_their_heap_index --skip descriptor::host::tests::dynamic_slots_are_held_until_released --skip memory::tests::lists_share_a_table_and_copies_keep_their_views --skip emit::stride_tests::a_heap_buffer_read_by_element_takes_the_views_stride --skip emit::stride_tests::a_heap_buffer_read_where_no_buffer_view_is_reads_zeros --skip emit::synthetic_tests::gathers_at_a_level_match_the_hardware: 867 passed, 0 failed, 10 ignored.a_run_over_capacity_keeps_its_earliest_pipeline_uses.--skipleaves out tests that fail on main63bcca4on this card too, not because of this PR:heap_direct_texture_reads_mark_their_heap_indexends thevictory-shadertest process with0xc0000005(#2571), so without the skip the rest of that crate never reports;dynamic_slots_are_held_until_released,lists_share_a_table_and_copies_keep_their_viewsand the twostride_testshit the 1,000,000-view heap cap of NVIDIA drivers (#1835, #2317);gathers_at_a_level_match_the_hardwarefails on lane 0 (#1744).Not tested
AI use
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.