d3d12: keep a rewritten heap descriptor's recorded ray scene instead of refusing the batch #671
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/671"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-12-03T09:02:53Z.
Summary
A ray-query dispatch whose scene comes from a heap descriptor is checked again at submit. If the descriptor named a different scene, or none, from when the dispatch was recorded, the whole batch was refused ("inline ray scene or geometry changed after recording, rejecting submission"). The queue then kept the error and dropped every later batch. In ProjectScarlett runs this ended about one run in three, after the title rewrote a descriptor between recording and submit ("now names no scene").
A heap descriptor may change after recording: it is volatile, and the console's GPU reads it when the dispatch runs. A recorded list can't follow the new contents, so the dispatch now keeps the scene it recorded, whose storage the check holds until the list is done, and the batch runs. The rewrite is logged at powers of two. A root view's address is fixed in the recorded list, so its scene, its storage and the side tables are checked as before, and a successor or a removal there still refuses the batch.
#569 handles the root-view successor case in the same file by replaying the dispatch in queue order. This change doesn't touch that path; it only changes the heap-descriptor branch of
SceneCheck.Claimed on #533 (top-level scenes line, #382).
Tested
Run the checks relevant to this change.
106120caon this card (#656), see belowa_heap_descriptor_scene_may_change_after_recording_and_a_root_view_may_not). There's no Lanes scenario that rewrites a scene descriptor between recording and submit yet.GPU, driver and backend: RTX 5090 (
10de:2b85, NVIDIA 620.70.10) and AMD Ryzen 9 9950X graphics, RDNA 2 (1002:13c0, RADV, Mesa 26.0.8), both through GE-Proton11-15.tuxbox.py check --changed 106120ca, which selects thelanes,lanes-*,d3d12-*,guest-frameandpresentsuites and the D3D12 regression controls.The
Evidence:linetuxbox.py checkprints last, one per card (it names the commit it tested; run it on this pull request's head):Commands run and their results:
A first attempt that ran the AMD and NVIDIA checks at the same time had scattered 30-second guest timeouts on both cards, in different suites each time. Run one at a time, the results are the ones above.
Game run. This change ran in ProjectScarlett only as part of a combined build, on an RTX 5090. On the older line, that build (this change plus other fixes) gave 3 of 3 clean 15-minute runs into gameplay. On current upstream the game still loses the GPU to a separate mesh-draw MMU fault (Xid 13), which this change doesn't address. It hasn't been run in the game on its own.
Checks
CI runs the code checks: the Python and Rust unit tests, the translator tests through DXC, a Windows typecheck, clippy, formatting, rustdoc, and Miri on the providers. It has no GPU.
No evidence JSON changes.
🤖 Generated with Claude Code
Imported from brcly/TuxBox. Originally posted by JeffreyBytes on 2026-12-03T15:07:20Z.
AMD run on a discrete card, head
cebe780e. RX 6700 XT 12 GB (1002:73df), Mesa 26.3.1 RADV, GE-Proton11-15, full check:All the Lanes selftests passed here, including
queue-page-mappingsandray-tracing-rehydrate, so the three failures you saw on the iGPU (#656) don't show up on this card. Main106120caalso passed 17 of 17 on the same card and prefix. The kernel log had no amdgpu faults or resets. I didn't run the game on it.View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.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.