d3d12: do not copy a structure whose build was refused #461

Merged
NickStallman merged 1 commit from upstream-pr/461 into main 2026-11-29 14:36:19 +00:00
NickStallman commented 2026-11-29 09:19:55 +00:00 (Migrated from github.com)

Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-29T09:19:55Z.


Summary

A build into title memory that is refused publishes no structure (#442), so scenes leave its instances out. The storage chosen for it stays in the pool, and a copy takes a source with storage for a structure that was built (#436). So a copy of a refused build still goes to the host, reading either storage nothing was built into or the structure that was there before. An update in place and a size query have the same fault.

#436 and #442 are each right alone; this is the gap between them.

The storage is now withdrawn when the build is refused, as for a write that can't run, and the recording list keeps it for lists that still use it. A copy of such a structure isn't run, its size reads as zero, and an update there is built in full.

Found by reading. No title is known to do this.

Tested

Rebased onto main (6e2c5dab, with #455): c204da6e. check --no-gpu passed on it, and the full check: RTX 5090 187 pass, 0 fail; AMD iGPU 186 pass, 0 fail, guest-present-4k-splash skipped. Both include the new scene. The Lanes failing-first run below is for 2f8174fd, the version before #455. The change there is the same except for the call shape of publish_locked.

  • Unit test a_refused_build_leaves_no_structure_to_copy: fails on main (75453953), passes here. It checks the bookkeeping without a device, not a GPU copy.
  • python tuxbox.py check --no-gpu: passed.
  • Lanes ray-tracing-refused-structure, the third scene, over main's runtime (75453953) and with this change, on an RTX 5090 (620.70.10) and an AMD iGPU (1002:13c0, RADV), GE-Proton11-14: without it, "ray onto the copy of the refused rebuild: expected instance -1, found 7"; with it, pass. Same on both cards.
  • Full tuxbox.py check on 2f8174fd: RTX 5090 181 pass, 0 fail; AMD iGPU 180 pass, 0 fail, guest-present-4k-splash skipped (software display).
  • Not run: Windows. It was in a game build (with #462 and others), where nothing shows whether the case arose.

🤖 Generated with Claude Code

<!-- greyfinch-sync:brcly/TuxBox:issue:5549355632 --> Imported from [brcly/TuxBox](https://github.com/brcly/TuxBox/pull/461). Originally posted by [NickStallman](https://github.com/NickStallman) on 2026-11-29T09:19:55Z. --- ## Summary A build into title memory that is refused publishes no structure (#442), so scenes leave its instances out. The storage chosen for it stays in the pool, and a copy takes a source with storage for a structure that was built (#436). So a copy of a refused build still goes to the host, reading either storage nothing was built into or the structure that was there before. An update in place and a size query have the same fault. #436 and #442 are each right alone; this is the gap between them. The storage is now withdrawn when the build is refused, as for a write that can't run, and the recording list keeps it for lists that still use it. A copy of such a structure isn't run, its size reads as zero, and an update there is built in full. Found by reading. No title is known to do this. ## Tested Rebased onto `main` (6e2c5dab, with #455): c204da6e. `check --no-gpu` passed on it, and the full check: RTX 5090 187 pass, 0 fail; AMD iGPU 186 pass, 0 fail, guest-present-4k-splash skipped. Both include the new scene. The Lanes failing-first run below is for 2f8174fd, the version before #455. The change there is the same except for the call shape of `publish_locked`. - Unit test `a_refused_build_leaves_no_structure_to_copy`: fails on `main` (75453953), passes here. It checks the bookkeeping without a device, not a GPU copy. - `python tuxbox.py check --no-gpu`: passed. - Lanes `ray-tracing-refused-structure`, the third scene, over `main`'s runtime (75453953) and with this change, on an RTX 5090 (620.70.10) and an AMD iGPU (`1002:13c0`, RADV), GE-Proton11-14: without it, "ray onto the copy of the refused rebuild: expected instance -1, found 7"; with it, pass. Same on both cards. - Full `tuxbox.py check` on 2f8174fd: RTX 5090 181 pass, 0 fail; AMD iGPU 180 pass, 0 fail, guest-present-4k-splash skipped (software display). - **Not run:** Windows. It was in a game build (with #462 and others), where nothing shows whether the case arose. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
brcly commented 2026-11-29 12:02:55 +00:00 (Migrated from github.com)

Imported from brcly/TuxBox. Originally posted by brcly on 2026-11-29T12:02:55Z.


Just need you to rebase, then I can merge.

<!-- greyfinch-sync:brcly/TuxBox:comment:7255528463 --> Imported from [brcly/TuxBox](https://github.com/brcly/TuxBox/pull/461#issuecomment-7255528463). Originally posted by [brcly](https://github.com/brcly) on 2026-11-29T12:02:55Z. --- Just need you to rebase, then I can merge.
NickStallman commented 2026-11-29 12:21:31 +00:00 (Migrated from github.com)

Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-29T12:21:31Z.


Rebased onto 6e2c5dab as c204da6e. check --no-gpu passes on it. The GPU results in the description are for the version before #455; I've queued the Lanes case and both full checks on the new head and will post them, so you can merge now or wait for that.

<!-- greyfinch-sync:brcly/TuxBox:comment:7255753985 --> Imported from [brcly/TuxBox](https://github.com/brcly/TuxBox/pull/461#issuecomment-7255753985). Originally posted by [NickStallman](https://github.com/NickStallman) on 2026-11-29T12:21:31Z. --- Rebased onto `6e2c5dab` as `c204da6e`. `check --no-gpu` passes on it. The GPU results in the description are for the version before #455; I've queued the Lanes case and both full checks on the new head and will post them, so you can merge now or wait for that.
NickStallman commented 2026-11-29 12:42:33 +00:00 (Migrated from github.com)

Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-11-29T12:42:33Z.


Both full checks passed on c204da6e: RTX 5090 187 pass, 0 fail; AMD iGPU 186 pass, 0 fail (one skip: guest-present-4k-splash, software display). Ready when you are.

<!-- greyfinch-sync:brcly/TuxBox:comment:7256006776 --> Imported from [brcly/TuxBox](https://github.com/brcly/TuxBox/pull/461#issuecomment-7256006776). Originally posted by [NickStallman](https://github.com/NickStallman) on 2026-11-29T12:42:33Z. --- Both full checks passed on `c204da6e`: RTX 5090 187 pass, 0 fail; AMD iGPU 186 pass, 0 fail (one skip: `guest-present-4k-splash`, software display). Ready when you are.
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
brcly/TuxBox!461
No description provided.