Repository navigation
Conversation
…ist of its own Since ItsNotRexed#6610, ExecuteCommandLists refuses a batch with a list whose Close failed. The test executed such a list and read the destination back through the same list, so its readback buffer was never written and every refused case reported "destination changed". The clears now run in a list of their own, the refused list is still executed (the layer must refuse it), and a third list reads the destination back. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
0xKaji
left a comment
There was a problem hiding this comment.
Reviewed: splits clear and resolve/readback into separate command lists and adds the refused-resolve readback check. Looks consistent with the commit message.
|
Tested
Note: #7905 fixes the same test the same way and also passes here, so one of the two can probably be closed. |
|
I compared this PR (
Both PRs also gave the same native reference results: 37/97 matches against Intel D3D12 (32 host quirks), 69/71 against WARP, and seven matching refusals on each reference. The two WARP differences were the whole and rectangular D24S8 depth-as-R24_X8 edge AVERAGE cases. They were already present on As a control, I changed the destination depth clear from 0 to 0.25 for just the refused D32 DECOMPRESS case, leaving the expected depth at 0. Both PRs then exited 1 and identified exactly that case as changed. Either implementation restores the refused-resolve check on this adapter. Synthetic test only. AI-assisted review. |
|
Tested on an RTX 4070 Ti SUPER, NVIDIA 621.14, Windows 11 Pro 26200, RelWithDebInfo (this test's target only):
The logic looks right: the refused list is still submitted and refused as a whole, so the target stays in RESOLVE_DEST; the third list's RESOLVE_DEST -> COPY_SOURCE barrier matches that, and the fence is waited before Map, including on the early host return. Small gap, not blocking: the destination is cleared to depth 0.0, which is what a fresh readback buffer already holds, so in the D32 refused cases (no stencil) "kept" would also pass if the readback list never ran. Clearing to a non-zero depth, or pre-filling the readback buffer with a marker, would close it; the stencil cases already catch it through 0x5a. AI-assisted (Claude Code). |
|
Tested 4c1e45c merged onto main 2a3b3b5 (Windows 11, one laptop with two GPUs: RTX 5090 Laptop (Blackwell, NVIDIA 621.35) and Intel Arrow Lake-HX iGPU (Xe-LPG, Intel 101.9175); MSVC 14.44, Windows SDK 10.0.26100, Vulkan SDK 1.4.363.0, built with
#7905 and #8415 fix the same test and also pass here; only one is needed. AI-assisted (Claude Code); no game files involved. |
|
Tested 4c1e45c on RTX 5070 Ti (Blackwell, subgroup 32), NVIDIA 621.01, Windows 11, MSVC 14.44 (VS 2022 17.14 Build Tools), CMake 4.5.1 + Ninja, Vulkan headers sdk-1.4.363.0 (fetched), SPIRV-Tools 2026.4, no game copy: pass. I applied the diff (runtime/test/d3d12_depth_resolve_test.cpp) to a build of main at dfe4e4a, rebuilt only d3d12_depth_resolve_test and ran it. On main the test fails here with the eight refused resolves reporting "Close 0x80070057, destination changed" (D24S8 depth AVERAGE rect 1, D24S8 stencil AVERAGE rect 0, and six more), the same list as #8720. With this PR it exits 0: 51 of 51 resolves match the host on the RTX 5070 Ti with 0 host quirks and 7 refusals alike, 37 of 37 match against WARP, and the summary line reads "88 host comparisons matched, 12 refusals kept the destination, 0 edge MIN/MAX pairs differ". The edge cases were skipped because glslangValidator was not available at build time. I also ran #7905 and #8828 the same way and they give the same result here, so all three fix the same failure; it is worth picking one and closing the others. AI-assisted (Claude Code): built and ran the test as described above. No game data was used. |
Claim: #7599 (comment)
Depends on: none.
Failure
On
main(1d2103085),d3d12_depth_resolvefails its refused-resolve checks on every run. The layer is running its own path here, so this is not specific to Wine or to the GPU:Cause
The test records the clears, the resolve and the readback copies in one list. For a refused resolve,
Closefails, and the test then executes that list anyway (run_invalid) and reads the destination back. Since #6610,ExecuteCommandListsrefuses a batch that contains a list whoseClosefailed (runtime/shims/d3d12_com.cpp:1550). That is the right behaviour, because on the PC runtime such a list is invalid. Under the new rule, nothing in that list runs, including the copies into the readback buffer. The test therefore compares memory that was never written: a case passes or fails depending on what a recycled allocation happened to hold.Fix (test only)
resolve_and_readnow uses three lists:Closesucceeds, it runs as before. IfClosefails andrun_invalidis set, the list is still executed, and the layer has to refuse it.So "a refused resolve fails
Closeand keeps the destination" is still checked, and now against a destination that really was cleared. The host is still never given a list whoseClosefailed. For such a list it only waits for the clears. The layer's code is unchanged.Tested
Linux; Windows build cross-compiled with clang-cl + xwin (SDK 10.0.26100); Wine 11.20 Staging; NVIDIA GeForce RTX 4070 Ti SUPER, driver 615.78.08.
ctest -R '^d3d12_depth_resolve$'passes. Three direct runs in a row all print12 refusals kept the destination ... 20 edge MIN/MAX pairs differand exit 0. Host comparisons are skipped under Wine, as before.python3 -I scripts/check_no_game_data.py runtime/test/d3d12_depth_resolve_test.cppandgit diff --checkare clean.Not tested: native Windows / MSVC, and the host-comparison half that only runs on Windows. That half only gains the separate clear list and a wait before returning on a refused
Close.#6091 and #7638 touch the same file for other reasons, so whichever of them lands second needs a small rebase.
Synthetic resources only, no game data. AI-assisted (Claude Code).
🤖 Generated with Claude Code