GPU: say in device-removed reports which user data is a table #421

Open
GamingRipperDoc wants to merge 1 commit from upstream-pr/421 into main
GamingRipperDoc commented 2026-11-25 00:36:22 +00:00 (Migrated from github.com)

Imported from fxceless/victory-fork. Originally posted by GamingRipperDoc on 2026-11-25T00:36:22Z.


Device-removed reports: say which user data is a table. Ported from upstream Marvisak/VIctory#427 (two approvals there, checked in real reports by a tester).

Why

op_text prints [heap N: …] after every user-data value, whatever the shader does with it. On upstream Marvisak/VIctory#304 that made u13=0x0 [heap 0: … TEXTURE1D …] read as "this mesh draw reads heap slot 0", when u13 is a plain constant (RootType::Constants) in every shader that has it; it took a diagnostic run to find out.

What

Each user-data value is labelled:

u8=0xa12100 table [heap 329992: null]          (a table: the view it starts at)
u13=0x0 const [as heap index 0: Shader(0, …)]   (a constant: the view at that index, labelled as a guess)
u15=0x… host                                    (a word VIctory computes: no view)

The host case is new in this port: this tree's loop also reads host-computed words (RootType::Other, through host_word, e.g. the title-memory base), which are addresses, not heap indices, so they get no view. The tuple is named root, not kind (the upstream review fix), so it doesn't shadow op_text's kind: String. Only diagnostics builds change; one file.

Tested

Windows 10, AMD RX 9070 XT, on main 31714de: cargo clippy -p victory-gpu --all-targets --features diagnostics -- -D warnings clean; rustfmt --check on draw.rs reports the same places as main, none in the changed lines. The upstream version was confirmed in six real device-removed reports on an RX 9070 XT (all values labelled, none in the old form); the host label hasn't appeared in a real report here yet.

No game data used.

AI-assisted (Claude Code); I ran the checks above on my machine.

<!-- greyfinch-sync:fxceless/victory-fork:issue:6594387277 --> Imported from [fxceless/victory-fork](https://github.com/fxceless/victory-fork/pull/421). Originally posted by [GamingRipperDoc](https://github.com/GamingRipperDoc) on 2026-11-25T00:36:22Z. --- Device-removed reports: say which user data is a table. Ported from upstream Marvisak/VIctory#427 (two approvals there, checked in real reports by a tester). ## Why `op_text` prints `[heap N: …]` after every user-data value, whatever the shader does with it. On upstream Marvisak/VIctory#304 that made `u13=0x0 [heap 0: … TEXTURE1D …]` read as "this mesh draw reads heap slot 0", when `u13` is a plain constant (`RootType::Constants`) in every shader that has it; it took a diagnostic run to find out. ## What Each user-data value is labelled: ``` u8=0xa12100 table [heap 329992: null] (a table: the view it starts at) u13=0x0 const [as heap index 0: Shader(0, …)] (a constant: the view at that index, labelled as a guess) u15=0x… host (a word VIctory computes: no view) ``` The `host` case is new in this port: this tree's loop also reads host-computed words (`RootType::Other`, through `host_word`, e.g. the title-memory base), which are addresses, not heap indices, so they get no view. The tuple is named `root`, not `kind` (the upstream review fix), so it doesn't shadow `op_text`'s `kind: String`. Only diagnostics builds change; one file. ## Tested Windows 10, AMD RX 9070 XT, on `main` `31714de`: `cargo clippy -p victory-gpu --all-targets --features diagnostics -- -D warnings` clean; `rustfmt --check` on `draw.rs` reports the same places as `main`, none in the changed lines. The upstream version was confirmed in six real device-removed reports on an RX 9070 XT (all values labelled, none in the old form); the `host` label hasn't appeared in a real report here yet. No game data used. AI-assisted (Claude Code); I ran the checks above on my machine.
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/421:upstream-pr/421'
git switch 'upstream-pr/421'

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.

git switch 'main'
git merge --no-ff 'upstream-pr/421'
git switch 'upstream-pr/421'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/421'
git switch 'upstream-pr/421'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/421'
git switch 'main'
git merge --squash 'upstream-pr/421'
git switch 'main'
git merge --ff-only 'upstream-pr/421'
git switch 'main'
git merge 'upstream-pr/421'
git push origin 'main'
Sign in to join this conversation.
No reviewers
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
fxceless/victory-fork!421
No description provided.