The title's own lists borrow their host list while recording (VICTORY_BORROW_RECORDING=1) #1

Closed
github-bot wants to merge 1 commit from github-bot/gh-1 into main AGit
Owner

@⁠tbarnavon on GitHub · 2026-11-28 17:52 UTC · original
tbarnavon:windows/borrow-title-lists → main · +17 −3 · 2 files · 1 commits · closed without merging

What

VICTORY_BORROW_RECORDING only reached VICTORY_THIN's back lists. This lets the title's own lists use it too: a submitted list gives its host list up and takes one from the pool (fresh_list) at its next reset, instead of being handed a new closed one at once. The switch read moves into list::borrow_recording(), shared by both paths.

Off by default; nothing changes without the switch.

Why

Without it every list of the title's holds a host list for good. The title keeps some 730 lists, so about that many host lists are alive from the loading screen on, each with its allocators, prelude and indirect budget.

On Windows this ended every run in the world's first minutes:

  • RX 6900 XT 16 GB, Ryzen, 32 GB RAM, Windows 11, AMD driver 32.0.21045, D3D12 Agility 1.620
  • ~1,100 host lists alive at each loss; the PC's memory shared with the card at ~9 GB of its 15.5 GB budget
  • removal reason 0x887A0007, empty breadcrumbs, no driver event (no TDR)
  • the D3D12 debug layer's last message: Kernel memory failure. There might be a memory leak.
  • independent of output size, console profile and the other speed switches (also with none of them)

With VICTORY_BORROW_RECORDING=1 the same setup played a 23-minute session and several shorter ones with no loss.

Tested

  • cargo check -p victory-gpu and cargo check -p victory --features diagnostics: no new warnings
  • In game on the PC above (diag build). Not tested on Linux / RADV.

🤖 Generated with Claude Code

**@⁠tbarnavon** on GitHub · 2026-11-28 17:52 UTC · [original](https://github.com/lobomfz/VIctory-xmem/pull/1) `tbarnavon:windows/borrow-title-lists` → `main` · +17 −3 · 2 files · 1 commits · closed without merging ## What `VICTORY_BORROW_RECORDING` only reached `VICTORY_THIN`'s back lists. This lets the title's own lists use it too: a submitted list gives its host list up and takes one from the pool (`fresh_list`) at its next reset, instead of being handed a new closed one at once. The switch read moves into `list::borrow_recording()`, shared by both paths. Off by default; nothing changes without the switch. ## Why Without it every list of the title's holds a host list for good. The title keeps some 730 lists, so about that many host lists are alive from the loading screen on, each with its allocators, prelude and indirect budget. On Windows this ended every run in the world's first minutes: - RX 6900 XT 16 GB, Ryzen, 32 GB RAM, Windows 11, AMD driver 32.0.21045, D3D12 Agility 1.620 - ~1,100 host lists alive at each loss; the PC's memory shared with the card at ~9 GB of its 15.5 GB budget - removal reason `0x887A0007`, empty breadcrumbs, no driver event (no TDR) - the D3D12 debug layer's last message: `Kernel memory failure. There might be a memory leak.` - independent of output size, console profile and the other speed switches (also with none of them) With `VICTORY_BORROW_RECORDING=1` the same setup played a 23-minute session and several shorter ones with no loss. ## Tested - `cargo check -p victory-gpu` and `cargo check -p victory --features diagnostics`: no new warnings - In game on the PC above (diag build). Not tested on Linux / RADV. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
The switch only reached VICTORY_THIN's back lists. A list of the title's
always held a host list: at submission it was given a new closed one at
once, whether the title would record into it again soon or not. The title
keeps some 730 lists, so as many host lists stayed alive from the loading
screen on, each with its allocators, prelude and indirect budget.

On Windows with an RX 6900 XT (32 GB, driver 32.0.21045) every run lost
the device in the world's first minutes: ~1,100 host lists alive, the
PC's memory shared with the card at ~9 GB of 15.5, no driver event, and
the debug layer's last word "Kernel memory failure". With the switch on
the title's lists, a 23-minute session ran without a loss.

Off by default, as before.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
github-bot locked as GitHub sync and limited conversation to collaborators 2026-12-01 07:40:57 +00:00
Author
Owner

@⁠Luxuride on GitHub · 2026-12-04 12:00 UTC · original · edited 2026-12-05 11:22 UTC

The switch this flips no longer exists, so the patch is aimed at code that is gone rather than at something wrong.

2773fdf made borrowing permanently off (crates/victory-gpu/src/list.rs:644 is now borrow_recording: false, crates/victory-gpu/src/list/thin.rs:311 sets back.borrow_recording = false;), and git grep VICTORY_BORROW_RECORDING origin/main returns nothing. The problem the PR measured is now bounded differently, by idle-list age trimming: crates/victory-gpu/src/list.rs:302-320 (age_trim, ALLOCATOR_TRIM, TRIMMED_LISTS) plus VICTORY_KEEP_HOST_BUFFERS.

The patch itself is clean, and it conflicts in list.rs/thin.rs after 400+ commits. Whether that leaves anything worth reviewing here is the maintainer's call, not mine.

If you still see host lists piling up on the 6900 XT, the reviewable artefact would be an issue with a TRIMMED_LISTS / VICTORY_KEEP_HOST_BUFFERS reading from the current tree rather than a rebase of this.

**@⁠Luxuride** on GitHub · 2026-12-04 12:00 UTC · [original](https://github.com/lobomfz/VIctory-xmem/pull/1#issuecomment-7410834394) · edited 2026-12-05 11:22 UTC The switch this flips no longer exists, so the patch is aimed at code that is gone rather than at something wrong. `2773fdf` made borrowing permanently off (`crates/victory-gpu/src/list.rs:644` is now `borrow_recording: false`, `crates/victory-gpu/src/list/thin.rs:311` sets `back.borrow_recording = false;`), and `git grep VICTORY_BORROW_RECORDING origin/main` returns nothing. The problem the PR measured is now bounded differently, by idle-list age trimming: `crates/victory-gpu/src/list.rs:302-320` (`age_trim`, `ALLOCATOR_TRIM`, `TRIMMED_LISTS`) plus `VICTORY_KEEP_HOST_BUFFERS`. The patch itself is clean, and it conflicts in `list.rs`/`thin.rs` after 400+ commits. Whether that leaves anything worth reviewing here is the maintainer's call, not mine. If you still see host lists piling up on the 6900 XT, the reviewable artefact would be an issue with a `TRIMMED_LISTS` / `VICTORY_KEEP_HOST_BUFFERS` reading from the current tree rather than a rebase of this.
github-bot closed this pull request 2026-12-05 17:31:36 +00:00

Pull request closed

This discussion has been locked. Commenting is limited to contributors.
No description provided.