feat(gpu,shader): opt-in VirtualDescriptorPager + SLOT_VIEW_MAP (t252) for NVIDIA 1M view heap cap #1300

Open
github-bot wants to merge 2 commits from github-bot/gh-1300 into main AGit
Owner

@⁠POMXARK on GitHub · 2026-11-26 13:05 UTC · original
POMXARK:feat/virtual-descriptor-pager → main · +653 −82 · 8 files · 2 commits · open

Ref #1199 (Follow-up Virtual Descriptor Pager Draft PR ported cleanly onto ceb9e1f).

100% opt-in via VICTORY_VIEW_PAGER=1 (auto on PORTABLE_VIEWS capped hosts) or VICTORY_VIEW_PAGER=force — completely inactive by default (VIEW_PAGER = false, shader translation_fingerprint keys cleanly on view_heap_paged()).

Design summary

  • victory-shader (emit/shader.rs, emit/lower.rs, emit/mod.rs): adds root SRV SLOT_VIEW_MAP (t252, SLOT_VIEW_MAP_COUNT = 2^21) and translates RootType::ResourceHeap indices through a bounds-clamped lookup into t252 only when view_heap_paged is enabled.
  • victory-gpu (descriptor/pager.rs, descriptor/host.rs, draw.rs, pipeline/host.rs): preserves direct 1:1 physical slots below count, reserves [count + pool .. null_slot) for disjoint DYNAMIC tables, and pages overflow virtual slots through a Clock Second-Chance VirtualDescriptorPager with view_map updates and made_now lock-free fast-path guarded cleanly (index < self.count).

Verification (Windows 11 + NVIDIA GeForce RTX 5080 on ceb9e1f)

  • cargo test --release -p victory-shader: 220 passed; 0 failed (3 ignored, including paged_resource_heap_emits_valid_dxil_with_view_map_srv DXIL validator check)
  • cargo test --release -p victory-gpu descriptor::: 37 passed; 0 failed (including paged_host_heap_maps_slots_past_portable_views_on_d3d12 and all pager::tests)
**@⁠POMXARK** on GitHub · 2026-11-26 13:05 UTC · [original](https://github.com/fxceless/victory-fork/pull/1300) `POMXARK:feat/virtual-descriptor-pager` → `main` · +653 −82 · 8 files · 2 commits · open Ref #1199 (Follow-up Virtual Descriptor Pager Draft PR ported cleanly onto `ceb9e1f`). 100% opt-in via **`VICTORY_VIEW_PAGER=1`** (`auto` on `PORTABLE_VIEWS` capped hosts) or **`VICTORY_VIEW_PAGER=force`** — completely inactive by default (`VIEW_PAGER = false`, shader `translation_fingerprint` keys cleanly on `view_heap_paged()`). ### Design summary - **`victory-shader`** (`emit/shader.rs`, `emit/lower.rs`, `emit/mod.rs`): adds root SRV `SLOT_VIEW_MAP` (`t252`, `SLOT_VIEW_MAP_COUNT = 2^21`) and translates `RootType::ResourceHeap` indices through a bounds-clamped lookup into `t252` only when `view_heap_paged` is enabled. - **`victory-gpu`** (`descriptor/pager.rs`, `descriptor/host.rs`, `draw.rs`, `pipeline/host.rs`): preserves direct `1:1` physical slots below `count`, reserves `[count + pool .. null_slot)` for disjoint `DYNAMIC` tables, and pages overflow virtual slots through a Clock Second-Chance `VirtualDescriptorPager` with `view_map` updates and `made_now` lock-free fast-path guarded cleanly (`index < self.count`). ### Verification (Windows 11 + NVIDIA GeForce RTX 5080 on `ceb9e1f`) - `cargo test --release -p victory-shader`: **`220 passed; 0 failed`** (`3` ignored, including `paged_resource_heap_emits_valid_dxil_with_view_map_srv` DXIL validator check) - `cargo test --release -p victory-gpu descriptor::`: **`37 passed; 0 failed`** (including `paged_host_heap_maps_slots_past_portable_views_on_d3d12` and all `pager::tests`)
- Ref #1199 (completely gated behind VICTORY_VIEW_PAGER=1|force, off by default)
- Keep direct physical slots < count and route overflow virtual slots through Clock Second-Chance VirtualDescriptorPager backed by SLOT_VIEW_MAP (t252)
- Port onto ceb9e1f sharded kept + lock-free made_now fast-path (index < self.count guard)
- Preserve disjoint DYNAMIC tables at [count + pool .. null_slot)

Tests (Windows 11 + RTX 5080 on ceb9e1f):
- cargo test --release -p victory-shader: 220 passed, 0 failed (3 ignored)
- cargo test --release -p victory-gpu descriptor:: : 37 passed, 0 failed
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 13:08:31 +00:00
# Conflicts:
#	crates/victory-gpu/src/descriptor/host.rs
#	crates/victory-shader/src/emit/mod.rs
Author
Owner

@⁠POMXARK on GitHub · 2026-11-26 19:35 UTC · original

Merged fxceless/victory-fork:main into feat/virtual-descriptor-pager and resolved both merge conflicts (crates/victory-gpu/src/descriptor/host.rs release(id, first, n) + crates/victory-shader/src/emit/mod.rs).

Re-verified on Windows 11 + NVIDIA RTX 5080:

  • cargo check -p victory-gpu -p victory-shader: PASS
  • cargo test --release -p victory-shader: 234 passed; 0 failed (4 ignored)
  • cargo test --release -p victory-gpu descriptor::: 43 passed; 0 failed

Marked Ready for Review.

**@⁠POMXARK** on GitHub · 2026-11-26 19:35 UTC · [original](https://github.com/fxceless/victory-fork/pull/1300#issuecomment-7201746399) Merged `fxceless/victory-fork:main` into `feat/virtual-descriptor-pager` and resolved both merge conflicts (`crates/victory-gpu/src/descriptor/host.rs` `release(id, first, n)` + `crates/victory-shader/src/emit/mod.rs`). Re-verified on **Windows 11 + NVIDIA RTX 5080**: - `cargo check -p victory-gpu -p victory-shader`: **PASS** - `cargo test --release -p victory-shader`: **234 passed; 0 failed** (`4 ignored`) - `cargo test --release -p victory-gpu descriptor::`: **43 passed; 0 failed** Marked Ready for Review.
This pull request has changes conflicting with the target branch.
  • crates/victory-gpu/src/descriptor/host.rs
  • crates/victory-shader/src/emit/lower.rs
  • crates/victory-shader/src/emit/mod.rs
View command line instructions

Manual merge helper

Use this merge commit message when completing the merge manually.

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/1300/head:github-bot/gh-1300'
git switch 'github-bot/gh-1300'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-1300'
git switch 'github-bot/gh-1300'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-1300'
git switch 'github-bot/gh-1300'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-1300'
git switch 'main'
git merge --squash 'github-bot/gh-1300'
git switch 'main'
git merge --ff-only 'github-bot/gh-1300'
git switch 'main'
git merge 'github-bot/gh-1300'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.