d3d12: on c1139ab2, ProjectScarlett stops after the account picker at 3840x2160: handoffs::plan refuses a batch with no phases (RX 6700 XT, RADV) #661

Closed
opened 2026-12-02 20:07:47 +00:00 by JeffreyBytes · 5 comments
JeffreyBytes commented 2026-12-02 20:07:47 +00:00 (Migrated from github.com)
Contributor

Imported from brcly/TuxBox. Originally posted by JeffreyBytes on 2026-12-02T20:07:47Z.


What I see

On main c1139ab2, ProjectScarlett ends the same way in all three of my runs on an RX 6700 XT, right after the account picker at 3840x2160. The direct queue refuses a batch it can't order. The present fails, and then the title's watchdog (#215) exits with code 5. NickStallman hit the same refusal on an RTX 5090, and 1093i3511 hit it on an RX 6600 (four runs, exit 5 at 116-121 s). Both reports are in #533, so this isn't vendor-specific. This crash also blocks the 3840x2160 memory run brcly asked for in #292.

Two clean runs ended at 113.6 s and 119.1 s. A run with a local logging build ended at 117.3 s. Every run logs:

command list cannot record cannot order buffer and texture accesses: HRESULT(0x80004001)
Project TuxBox: direct queue rejected a guest command-list batch (0x80004001); its later batches are dropped
PresentX failed planes=1 HRESULT=0x80004001

Then come 11-12 winevulkan signaller_worker wait timed out with non-empty poll list lines and an access violation at game_scarlett_master.exe+0x23CF683, which is the watchdog. The game exits with code 5. Frames drop from about 400 per 10 s to 154-282 just before. I see no GPU fault and no VK_ERROR_DEVICE_LOST, and the kernel log has nothing related.

Which check refuses it

I added local logging at each refusal branch of handoffs::plan and Phase::resolve. It isn't meant for merging. It printed this once:

TuxBox DIAG refusal: plan.no_phases: overlap=FixedOrMirroredBuffer pair=Some((Span{from:0,to:65536,mapped:true,write:false}, Span{from:0,to:65536,mapped:false,write:true})) phases=0 gate=false direct=false ...

So the refusal comes from phases.is_empty() || copies.untracked || overlap == FixedOrMirroredBuffer in runtime/d3d12/src/device/placement/handoffs.rs (around line 169). The batch has no phases. A write through a fixed or mirrored buffer also overlaps the first 64 KiB of a mapped image the batch reads. Both conditions are true, so I can't say yet which one is the real problem. I also haven't traced why the batch has no phases.

Before c1139ab2

On 1b4ed472, two runs failed earlier, at 72.5 s and 71.5 s. Both logged import SRV at 0xd43200000, 118064 bytes stride=4 fmt=39 ... failed HRESULT(0x80004001) and then fail-fast with exit 2. That's the same failure DrArroway posted in #656. From the code (not tested), I think the GPU reservation ID that 1b4ed472 gave the 0x900200000 aperture makes buffer_at and fixed_placement (from 9c3cf86f) return E_NOTIMPL there. gpu_buffer_for_view in c1139ab2 removes it, and none of my three runs on c1139ab2 had an import failure. Those earlier crashes hid any later failure, so on this card I can't tell whether the refusal is new in c1139ab2. 1093i3511 saw the same line on 1b4ed472.

Not tested

I haven't tried a lower resolution. 1093i3511 hit it with the Series S profile, so my guess is resolution doesn't matter, but I haven't checked. I also haven't tested NVIDIA on c1139ab2. 1093i3511 reports the refusal doesn't appear with TUXBOX_XMEM_PRIVATE_VIEWS=1; I haven't tried that either.

Next

I'm working on a fix. First I'll trace why this batch reaches plan with no phases. Then I'll add a unit test to runtime/d3d12/src/tests/device/placement/handoffs.rs that builds a batch like this one and fails on this refusal. Nothing to share yet.

Setup: RX 6700 XT (1002:73df), Mesa 26.3.1 RADV, Linux 7.3.6 (CachyOS), GE-Proton11-15. I launch with tuxbox.py run (offline), warm shader caches, and no forced resolution. The title presents at 3840x2160 on a 4K display.

<!-- greyfinch-sync:brcly/TuxBox:issue:6753505096 --> Imported from [brcly/TuxBox](https://github.com/brcly/TuxBox/issues/661). Originally posted by [JeffreyBytes](https://github.com/JeffreyBytes) on 2026-12-02T20:07:47Z. --- ## What I see On main c1139ab2, ProjectScarlett ends the same way in all three of my runs on an RX 6700 XT, right after the account picker at 3840x2160. The direct queue refuses a batch it can't order. The present fails, and then the title's watchdog (#215) exits with code 5. NickStallman hit the same refusal on an RTX 5090, and 1093i3511 hit it on an RX 6600 (four runs, exit 5 at 116-121 s). Both reports are in #533, so this isn't vendor-specific. This crash also blocks the 3840x2160 memory run brcly asked for in #292. Two clean runs ended at 113.6 s and 119.1 s. A run with a local logging build ended at 117.3 s. Every run logs: ``` command list cannot record cannot order buffer and texture accesses: HRESULT(0x80004001) Project TuxBox: direct queue rejected a guest command-list batch (0x80004001); its later batches are dropped PresentX failed planes=1 HRESULT=0x80004001 ``` Then come 11-12 `winevulkan signaller_worker wait timed out with non-empty poll list` lines and an access violation at `game_scarlett_master.exe+0x23CF683`, which is the watchdog. The game exits with code 5. Frames drop from about 400 per 10 s to 154-282 just before. I see no GPU fault and no `VK_ERROR_DEVICE_LOST`, and the kernel log has nothing related. ## Which check refuses it I added local logging at each refusal branch of `handoffs::plan` and `Phase::resolve`. It isn't meant for merging. It printed this once: ``` TuxBox DIAG refusal: plan.no_phases: overlap=FixedOrMirroredBuffer pair=Some((Span{from:0,to:65536,mapped:true,write:false}, Span{from:0,to:65536,mapped:false,write:true})) phases=0 gate=false direct=false ... ``` So the refusal comes from `phases.is_empty() || copies.untracked || overlap == FixedOrMirroredBuffer` in `runtime/d3d12/src/device/placement/handoffs.rs` (around line 169). The batch has no phases. A write through a fixed or mirrored buffer also overlaps the first 64 KiB of a mapped image the batch reads. Both conditions are true, so I can't say yet which one is the real problem. I also haven't traced why the batch has no phases. ## Before c1139ab2 On 1b4ed472, two runs failed earlier, at 72.5 s and 71.5 s. Both logged `import SRV at 0xd43200000, 118064 bytes stride=4 fmt=39 ... failed HRESULT(0x80004001)` and then fail-fast with exit 2. That's the same failure DrArroway posted in #656. From the code (not tested), I think the GPU reservation ID that 1b4ed472 gave the 0x900200000 aperture makes `buffer_at` and `fixed_placement` (from 9c3cf86f) return E_NOTIMPL there. `gpu_buffer_for_view` in c1139ab2 removes it, and none of my three runs on c1139ab2 had an import failure. Those earlier crashes hid any later failure, so on this card I can't tell whether the refusal is new in c1139ab2. 1093i3511 saw the same line on 1b4ed472. ## Not tested I haven't tried a lower resolution. 1093i3511 hit it with the Series S profile, so my guess is resolution doesn't matter, but I haven't checked. I also haven't tested NVIDIA on c1139ab2. 1093i3511 reports the refusal doesn't appear with `TUXBOX_XMEM_PRIVATE_VIEWS=1`; I haven't tried that either. ## Next I'm working on a fix. First I'll trace why this batch reaches `plan` with no phases. Then I'll add a unit test to `runtime/d3d12/src/tests/device/placement/handoffs.rs` that builds a batch like this one and fails on this refusal. Nothing to share yet. Setup: RX 6700 XT (1002:73df), Mesa 26.3.1 RADV, Linux 7.3.6 (CachyOS), GE-Proton11-15. I launch with `tuxbox.py run` (offline), warm shader caches, and no forced resolution. The title presents at 3840x2160 on a 4K display.
Kayotic1337 commented 2026-12-02 20:38:29 +00:00 (Migrated from github.com)
Author
Contributor

Imported from brcly/TuxBox. Originally posted by Kayotic1337 on 2026-12-02T20:38:29Z.


Same stop on RDNA4. RX 9070 XT (1002:7550), Mesa 26.3.1 RADV, GE-Proton11-15, main c1139ab2, tuxbox.py run, warm caches, 3840x2160.

  • Defaults: exit 5 after 130.8 s, with the same three lines as yours: command list cannot record cannot order buffer and texture accesses: HRESULT(0x80004001), the batch rejected, PresentX failed planes=1 HRESULT=0x80004001. No GPU fault, nothing in the kernel log.
  • TUXBOX_XMEM_PRIVATE_VIEWS=1: exit 3 after 34.1 s, before the title menu. radv/amdgpu: The CS has been rejected, see dmesg for more information (-1), then VK_ERROR_DEVICE_LOST. The kernel log has nothing for it. The refusal line doesn't appear, but that run never got as far as the place where it shows up. So it doesn't tell whether private views avoid it. The early CS rejection looks like what #660 describes. I haven't tested #660.

One run each.

<!-- greyfinch-sync:brcly/TuxBox:comment:7358071587 --> Imported from [brcly/TuxBox](https://github.com/brcly/TuxBox/issues/661#issuecomment-7358071587). Originally posted by [Kayotic1337](https://github.com/Kayotic1337) on 2026-12-02T20:38:29Z. --- Same stop on RDNA4. RX 9070 XT (`1002:7550`), Mesa 26.3.1 RADV, GE-Proton11-15, main `c1139ab2`, `tuxbox.py run`, warm caches, 3840x2160. - **Defaults:** exit 5 after 130.8 s, with the same three lines as yours: `command list cannot record cannot order buffer and texture accesses: HRESULT(0x80004001)`, the batch rejected, `PresentX failed planes=1 HRESULT=0x80004001`. No GPU fault, nothing in the kernel log. - **`TUXBOX_XMEM_PRIVATE_VIEWS=1`:** exit 3 after 34.1 s, before the title menu. `radv/amdgpu: The CS has been rejected, see dmesg for more information (-1)`, then `VK_ERROR_DEVICE_LOST`. The kernel log has nothing for it. The refusal line doesn't appear, but that run never got as far as the place where it shows up. So it doesn't tell whether private views avoid it. The early CS rejection looks like what #660 describes. I haven't tested #660. One run each.
DrArroway commented 2026-12-02 20:41:19 +00:00 (Migrated from github.com)
Author
Contributor

Imported from brcly/TuxBox. Originally posted by DrArroway on 2026-12-02T20:41:19Z.


Confirming we reproduce the exact same handoffs::plan 0x80004001 refusal on c1139ab2 right after the account picker on AMD Radeon RX 6900 XT (1002:73bf) (3840x2160, RADV / GE-Proton11-15, TUXBOX_XMEM_PRIVATE_VIEWS=1).

FWIW, when we let FixedOrMirroredBuffer degrade locally, three adjacent refusal sites fired immediately behind it before reaching the 3D world:

  • handoffs.rs: direct=true from BufferCopies's address-blind reads/writes booleans (e.g., placed upload copies alongside heap-backed draws/dispatches).
  • remapped.rs: mapped textures with has_null hitting E_NOTIMPL on !stable RT/UAV writes.
  • shader_buffers.rs: conservative accesses.indirect scans rejecting on unrelated dead Backing::Fixed imports.

Letting those coarse overlaps degrade to whole-submission ordering via report_alias — while keeping intra-command QueueBacked draw/dispatch alias rejections strict — cleared the account picker into the 3D world and passed lanes-selftest 32/32 with TUXBOX_XMEM_PRIVATE_VIEWS=1 on AMD Radeon RX 6900 XT (1002:73bf).

Happy to test your PR branch on both AMD Radeon RX 6900 XT (1002:73bf) and AMD Raphael Radeon 610M iGPU (1002:164e) once it's up.

<!-- greyfinch-sync:brcly/TuxBox:comment:7358150246 --> Imported from [brcly/TuxBox](https://github.com/brcly/TuxBox/issues/661#issuecomment-7358150246). Originally posted by [DrArroway](https://github.com/DrArroway) on 2026-12-02T20:41:19Z. --- Confirming we reproduce the exact same `handoffs::plan` `0x80004001` refusal on `c1139ab2` right after the account picker on `AMD Radeon RX 6900 XT (1002:73bf)` (`3840x2160`, RADV / `GE-Proton11-15`, `TUXBOX_XMEM_PRIVATE_VIEWS=1`). FWIW, when we let `FixedOrMirroredBuffer` degrade locally, three adjacent refusal sites fired immediately behind it before reaching the 3D world: - `handoffs.rs`: `direct=true` from `BufferCopies`'s address-blind `reads`/`writes` booleans (e.g., placed upload copies alongside heap-backed draws/dispatches). - `remapped.rs`: mapped textures with `has_null` hitting `E_NOTIMPL` on `!stable` RT/UAV writes. - `shader_buffers.rs`: conservative `accesses.indirect` scans rejecting on unrelated dead `Backing::Fixed` imports. Letting those coarse overlaps degrade to whole-submission ordering via `report_alias` — while keeping intra-command `QueueBacked` draw/dispatch alias rejections strict — cleared the account picker into the 3D world and passed `lanes-selftest` `32/32` with `TUXBOX_XMEM_PRIVATE_VIEWS=1` on `AMD Radeon RX 6900 XT (1002:73bf)`. Happy to test your PR branch on both `AMD Radeon RX 6900 XT (1002:73bf)` and `AMD Raphael Radeon 610M iGPU (1002:164e)` once it's up.
DrArroway commented 2026-12-02 21:12:16 +00:00 (Migrated from github.com)
Author
Contributor

Imported from brcly/TuxBox. Originally posted by DrArroway on 2026-12-02T21:12:16Z.


Quick heads-up @JeffreyBytes: as noted on #635, we're stepping away for now so please don't wait on us for PR testing on AMD Radeon RX 6900 XT (1002:73bf) or AMD Raphael Radeon 610M iGPU (1002:164e).

For reference, we posted the rest of our c1139ab2 findings and local patch notes here: https://github.com/brcly/TuxBox/issues/533#issuecomment-7358936475. Good luck with the fix!

<!-- greyfinch-sync:brcly/TuxBox:comment:7358942358 --> Imported from [brcly/TuxBox](https://github.com/brcly/TuxBox/issues/661#issuecomment-7358942358). Originally posted by [DrArroway](https://github.com/DrArroway) on 2026-12-02T21:12:16Z. --- Quick heads-up @JeffreyBytes: as noted on `#635`, we're stepping away for now so please don't wait on us for PR testing on `AMD Radeon RX 6900 XT (1002:73bf)` or `AMD Raphael Radeon 610M iGPU (1002:164e)`. For reference, we posted the rest of our `c1139ab2` findings and local patch notes here: https://github.com/brcly/TuxBox/issues/533#issuecomment-7358936475. Good luck with the fix!
JeffreyBytes commented 2026-12-02 21:25:18 +00:00 (Migrated from github.com)
Author
Contributor

Imported from brcly/TuxBox. Originally posted by JeffreyBytes on 2026-12-02T21:25:18Z.


latest run on be1f7246, this issue no longer persists.

<!-- greyfinch-sync:brcly/TuxBox:comment:7359255785 --> Imported from [brcly/TuxBox](https://github.com/brcly/TuxBox/issues/661#issuecomment-7359255785). Originally posted by [JeffreyBytes](https://github.com/JeffreyBytes) on 2026-12-02T21:25:18Z. --- latest run on be1f7246, this issue no longer persists.
NickStallman commented 2026-12-02 21:28:45 +00:00 (Migrated from github.com)
Author
Contributor

Imported from brcly/TuxBox. Originally posted by NickStallman on 2026-12-02T21:28:45Z.


One data point on 7b308cd4 from an RTX 5090 (NVIDIA 620.70.10, GE-Proton11-15, warm caches, default settings, TUXBOX_TRACE_GPU_FAULT=1), one headless run:

  • No "cannot order buffer and texture accesses" refusal this time. The run got past the account picker and the intro.
  • At 206 s it lost the device with an MMU fault (Xid 13). The GPU fault trace names 15 started-but-unfinished commands, mostly mesh draws PS 8fdb2b7d MS 4db9a403. That's the same draw family as the AMD faults on #603 and the faults we see at the cutscene-to-gameplay switch on the ca7d1bc9 line.

So on this card 7b308cd4 gets past this issue's refusal and stops at the next known fault, not a new one. It's a single run, so I can't say whether the refusal is gone or just didn't happen this time.

<!-- greyfinch-sync:brcly/TuxBox:comment:7359337655 --> Imported from [brcly/TuxBox](https://github.com/brcly/TuxBox/issues/661#issuecomment-7359337655). Originally posted by [NickStallman](https://github.com/NickStallman) on 2026-12-02T21:28:45Z. --- One data point on `7b308cd4` from an RTX 5090 (NVIDIA 620.70.10, GE-Proton11-15, warm caches, default settings, `TUXBOX_TRACE_GPU_FAULT=1`), one headless run: - No "cannot order buffer and texture accesses" refusal this time. The run got past the account picker and the intro. - At 206 s it lost the device with an MMU fault (Xid 13). The GPU fault trace names 15 started-but-unfinished commands, mostly mesh draws `PS 8fdb2b7d MS 4db9a403`. That's the same draw family as the AMD faults on #603 and the faults we see at the cutscene-to-gameplay switch on the `ca7d1bc9` line. So on this card `7b308cd4` gets past this issue's refusal and stops at the next known fault, not a new one. It's a single run, so I can't say whether the refusal is gone or just didn't happen this time.
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
brcly/TuxBox#661
No description provided.