Tests: d3d12_depth_resolve no longer expects a refused list to replay #232

Closed
github-bot wants to merge 1 commit from gh-pr/232/head into gh-pr/232/base
Owner

@⁠Andretuta on GitHub · 2026-11-24 02:49 UTC · original
ubiquitarianism:old-pr/9965 → main · +9 −8 · 1 files · 1 commits · closed without merging

Carried over from old PR 9965 by BatSmacker84 in the original Leonida repository, which went private on 23 Nov 2026. The code is the branch old-pr/9965, exactly that PR's last commit. All carried-over PRs are listed in #17.
Opened as a draft, and the CI runs the opening started were cancelled so 250 PRs don't fill the queue. Re-run CI here when you review it.
BatSmacker84: this is your work. Feel free to take it over, by pushing to the branch or opening your own PR and closing this one.


Original description (mentions and #N references are disabled; the numbers refer to the old repository):

Claim: https://github.com/ProjectLeonida/Leonida/issues/9677#issuecomment-7116934259. This fixes tugasky's finding https://github.com/ProjectLeonida/Leonida/issues/9677#issuecomment-7116620428, which isn't in the tables yet.

d3d12_depth_resolve fails on every Vulkan device with eight lines like refused D24S8 depth AVERAGE rect 1: Close 0x80070057, destination changed. The cause is #6610: since it landed, ExecuteCommandLists refuses a whole batch that holds a list whose Close failed, as the D3D12 runtime does. The test was written a day earlier. For its refused cases it still executes the list on the layer and compares the readback with the destination's clear. That clear is in the refused list, so it never runs.

The host-comparison lines (63 of 97 match, 18 host quirks) and the edge … (information) lines are only printed, never failures, so they aren't the cause.

Change (test only):

  • Refused cases check that Close returns E_INVALIDARG, and still execute the list, so the layer's batch refusal stays exercised.
  • A mode the device lacks is no longer compared against the clears, for the same reason. It didn't trigger on RDNA3 (depth 0xf, stencil 0xd), but it would on a device missing a mode that D3D12 accepts.

Tested on Windows 11, AMD Radeon RX 7800 XT (Adrenalin 26.11.2), MSVC 19.44, Vulkan SDK 1.4.363.0. Current main (c95d93572) doesn't build on MSVC (the console descriptor heap of #9576), so I built on top of #9873, one of the open build fixes; this PR needs whichever of them lands.

  • ctest -R d3d12_depth_resolve with this change: pass.
  • Same build with the test unchanged: fails with the eight destination changed lines.

Depends on: #9873 (or any of the MSVC build fixes, to build on Windows)

AI-assisted (Claude Code).

🤖 Generated with Claude Code

**@⁠Andretuta** on GitHub · 2026-11-24 02:49 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/232) `ubiquitarianism:old-pr/9965` → `main` · +9 −8 · 1 files · 1 commits · closed without merging > Carried over from **old PR 9965** by `BatSmacker84` in the original Leonida repository, which went private on 23 Nov 2026. The code is the branch `old-pr/9965`, exactly that PR's last commit. All carried-over PRs are listed in #17. > Opened as a draft, and the CI runs the opening started were cancelled so 250 PRs don't fill the queue. Re-run CI here when you review it. > `BatSmacker84`: this is your work. Feel free to take it over, by pushing to the branch or opening your own PR and closing this one. --- Original description (mentions and `#N` references are disabled; the numbers refer to the old repository): Claim: https://github.com/ProjectLeonida/Leonida/issues/9677#issuecomment-7116934259. This fixes tugasky's finding https://github.com/ProjectLeonida/Leonida/issues/9677#issuecomment-7116620428, which isn't in the tables yet. `d3d12_depth_resolve` fails on every Vulkan device with eight lines like `refused D24S8 depth AVERAGE rect 1: Close 0x80070057, destination changed`. The cause is `#6610`: since it landed, `ExecuteCommandLists` refuses a whole batch that holds a list whose `Close` failed, as the D3D12 runtime does. The test was written a day earlier. For its refused cases it still executes the list on the layer and compares the readback with the destination's clear. That clear is in the refused list, so it never runs. The host-comparison lines (`63 of 97 match, 18 host quirks`) and the `edge … (information)` lines are only printed, never failures, so they aren't the cause. Change (test only): - Refused cases check that `Close` returns `E_INVALIDARG`, and still execute the list, so the layer's batch refusal stays exercised. - A mode the device lacks is no longer compared against the clears, for the same reason. It didn't trigger on RDNA3 (`depth 0xf, stencil 0xd`), but it would on a device missing a mode that D3D12 accepts. Tested on Windows 11, AMD Radeon RX 7800 XT (Adrenalin 26.11.2), MSVC 19.44, Vulkan SDK 1.4.363.0. Current `main` (c95d93572) doesn't build on MSVC (the console descriptor heap of `#9576`), so I built on top of `#9873`, one of the open build fixes; this PR needs whichever of them lands. - `ctest -R d3d12_depth_resolve` with this change: pass. - Same build with the test unchanged: fails with the eight `destination changed` lines. Depends on: `#9873` (or any of the MSVC build fixes, to build on Windows) AI-assisted (Claude Code). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Since #6610, ExecuteCommandLists refuses a whole batch that holds a list whose
Close failed, as the D3D12 runtime does. The test still executed its refused
resolves on the layer and compared the readback with the destination's clear,
which never ran, so all eight refused cases failed with "destination changed"
on every Vulkan device. The host-comparison counts it printed were not the
cause.

The refused cases now check Close (E_INVALIDARG) and still execute the list,
so the layer's batch refusal stays exercised. A mode the device lacks is no
longer compared against the clears either, for the same reason.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 08:49:42 +00:00
github-bot closed this pull request 2026-11-26 08:49:42 +00:00
Author
Owner

@⁠aslan2142 on GitHub · 2026-11-24 19:50 UTC · original

Thanks for this. Closing it as superseded: #66 (merged) fixes the same eight refused … destination changed failures in
d3d12_depth_resolve_test a different way.

  • It runs the clears, the resolve and the read-back as three separate lists, each its own batch.
  • When the layer refuses the resolve, it drops only that batch.
  • So the test can still check both that Close returns E_INVALIDARG and that the destination keeps its clears. That is
    stricter than checking Close alone.

The diagnosis here was right: the layer was correct to refuse the whole batch, and the test was wrong. The branch stays as
old-pr/9965, listed in #17. If you see a case #66 doesn't cover, please open a new PR against current main.

AI-assisted (Claude Code, Claude Opus 5.5).

**@⁠aslan2142** on GitHub · 2026-11-24 19:50 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/232#issuecomment-7142653915) Thanks for this. Closing it as superseded: #66 (merged) fixes the same eight `refused … destination changed` failures in `d3d12_depth_resolve_test` a different way. - It runs the clears, the resolve and the read-back as three separate lists, each its own batch. - When the layer refuses the resolve, it drops only that batch. - So the test can still check both that `Close` returns `E_INVALIDARG` **and** that the destination keeps its clears. That is stricter than checking `Close` alone. The diagnosis here was right: the layer was correct to refuse the whole batch, and the test was wrong. The branch stays as `old-pr/9965`, listed in #17. If you see a case #66 doesn't cover, please open a new PR against current `main`. AI-assisted (Claude Code, Claude Opus 5.5).

Pull request closed

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