Capped adapters: the dynamic pool still gets 262,144 slots, and the copy fault budget never recovers #102

Open
opened 2026-11-26 03:25:18 +00:00 by kalijerry · 0 comments
kalijerry commented 2026-11-26 03:25:18 +00:00 (Migrated from github.com)
Contributor

Imported from avatarmanz/VIctory-7900XTX. Originally posted by kalijerry on 2026-11-26T03:25:18Z.


Follow-up to #35 (the PORTABLE_VIEWS cap) and #47 (the range search), measured on an RTX 3080 10 GB.

The measurement the two overflow cases miss

With the builder on, the copy tracker reports, per frame, on the same build:

  • 3,125 pages (had no copy) - v_readfirstlane/A drain runs out of its fault budget and stops filling pages
  • 53126 page faults, 800 watches, 413 guard faults
  • 937 drain runs, 501 fallbacks

FAULTS is 128 and FAULTS_ALL 2048, and self.faulted only ever counts up, so after the first frame's cap is spent the rest of the session gets no more pages. 75 MB of the same 4 MiB window is also copied whole twice a frame (15.1 ms + 4.4 ms) regardless of what changed in it.

Sizing: room past the cap is not the only problem

dynamic_slots returns DYNAMIC (262,144) whenever the null slot is below PORTABLE_VIEWS, so on a 3080 that fits a 1,835,008 heap the pool still only gets 262,144 slots, and the title's own slots past the cap are made afresh in it. Refusals of 2-slot tables at that size show the pool full as well as cut up - more room past the title is enough, but only if the heap is allowed to grow first.

PR #96 takes the largest heap the card makes instead of the portable fallback and gives the pool room out of the title's slots past the cap, keeping a quarter of the limit for direct title slots.

Suggested order

  1. Let the heap grow to what the card makes (PR #96) - without it the pool has nowhere to come from.
  2. Make the fault budget recoverable: return budget for pages that were found, or let faulted decay, and raise FAULTS/FAULTS_ALL.
  3. Copy only the dirty pieces of the two 4 MiB windows instead of the whole window twice a frame.

Verification

  • RTX 3080, 0a43566 + builder + PR #96: draws dropped per frame 2,800 -> single digits.
  • cargo test -p victory-gpu --lib on the PR branch: 328 passed.
<!-- greyfinch-sync:avatarmanz/VIctory-7900XTX:issue:6618828213 --> Imported from [avatarmanz/VIctory-7900XTX](https://github.com/avatarmanz/VIctory-7900XTX/issues/102). Originally posted by [kalijerry](https://github.com/kalijerry) on 2026-11-26T03:25:18Z. --- Follow-up to #35 (the PORTABLE_VIEWS cap) and #47 (the range search), measured on an RTX 3080 10 GB. ## The measurement the two overflow cases miss With the builder on, the copy tracker reports, per frame, on the same build: - 3,125 pages (`had no copy`) - v_readfirstlane/A drain runs out of its fault budget and stops filling pages - 53126 page faults, 800 watches, 413 guard faults - 937 drain runs, 501 fallbacks FAULTS is 128 and FAULTS_ALL 2048, and `self.faulted` only ever counts up, so after the first frame's cap is spent the rest of the session gets no more pages. 75 MB of the same 4 MiB window is also copied whole twice a frame (15.1 ms + 4.4 ms) regardless of what changed in it. ## Sizing: room past the cap is not the only problem `dynamic_slots` returns `DYNAMIC` (262,144) whenever the null slot is below `PORTABLE_VIEWS`, so on a 3080 that fits a 1,835,008 heap the pool still only gets 262,144 slots, and the title's own slots past the cap are made afresh in it. Refusals of 2-slot tables at that size show the pool full as well as cut up - more room past the title is enough, but only if the heap is allowed to grow first. PR #96 takes the largest heap the card makes instead of the portable fallback and gives the pool room out of the title's slots past the cap, keeping a quarter of the limit for direct title slots. ## Suggested order 1. Let the heap grow to what the card makes (PR #96) - without it the pool has nowhere to come from. 2. Make the fault budget recoverable: return budget for pages that were found, or let `faulted` decay, and raise FAULTS/FAULTS_ALL. 3. Copy only the dirty pieces of the two 4 MiB windows instead of the whole window twice a frame. ## Verification - RTX 3080, 0a43566 + builder + PR #96: draws dropped per frame 2,800 -> single digits. - `cargo test -p victory-gpu --lib` on the PR branch: 328 passed.
Sign in to join this conversation.
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
avatarmanz/VIctory-7900XTX#102
No description provided.