Repository navigation
Conversation
a68f609 made res_release ask the resource for its desc on the last release (to log a buffer's GPU address). The fake resource in release_tests::the_last_release_drops_entries_before_the_object_goes has only AddRef and Release in its vtable, so the GetDesc slot is a null pointer: the child process the test runs in (XCL_LATE_RELEASE=0) dies with an access violation (0xC0000005) before printing anything, and the parent's assertion fails with an empty output. Fails on CI and on a PC alike. The fake now answers GetDesc with a texture's desc, which takes no GPU address, so the test checks what it checked before. Assisted-by: Claude Code (Claude Opus 5.5) Signed-off-by: Enrique Villa <eevilla@up.edu.ph>
On nvidia-dev, a_gpu_view_tile_is_filled_from_its_cpu_view_and_follows_its_writes sizes its GPU view by software(): 53 tiles on a software device, 3 GiB on a GPU. software() only looked at DXGI_ADAPTER_FLAG_SOFTWARE. On the CI runner the default adapter is the Microsoft Basic Render Driver (0 MiB VRAM), and the CI log of af2cecc shows the test reserving the 3 GiB view there; the device is then removed (0x887a0020) and the device-removal handler ends the test process, so the CI job fails on nvidia-dev and on every PR against it. software() now also counts the Microsoft software adapter by its IDs (vendor 0x1414, device 0x8c), which WARP and the Basic Render Driver share. small_runs_go_up_in_dispatches_and_leave_what_lies_between uses the same check and skips there as its comment intends. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit 9d967cf) Signed-off-by: Enrique Villa <eevilla@up.edu.ph>
console_ms_in_as_slot_and_ms_with_as_are_refused_cleanly (xcl-dev#2015) expects the "in the AS slot" refusal. xcl-dev#541 (70f9185) removed that refusal on purpose: a console MS alone in the AS slot is now translated as the mesh shader it is. nvidia-dev has both, so the test failed on every GPU run. The synthetic container has no NGG variant, so it is still refused with E_INVALIDARG, now by the MS translation ("MS: no NGG hardware variant"). The test now expects that. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit 2331f2e) Signed-off-by: Enrique Villa <eevilla@up.edu.ph>
|
Review (head 95e3651, diff read, not a merge-check; draft, base
Fine: every hunk is test code ( AI review: Claude Code (Claude Opus 5.5), posted by Foniass without a human check of each point. |
|
All three commits of this PR are already on AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human. |
On
amd-dev(f33df5a), every PR'sBuild and test (Windows, no GPU)job fails inhle::d3d12x.There are two separate test-only causes:
real::release_tests::the_last_release_drops_entries_before_the_object_goes: a68f609 maderes_releasecallGetDescon a resource's last release (to log a buffer's GPU address). Thetest's fake resource only has AddRef and Release in its vtable, so
GetDesccalls a nullpointer. The child process the test runs in (
XCL_LATE_RELEASE=0) dies with 0xC0000005 beforeit prints anything, and the parent's
output.status.success()assertion fails with emptyoutput. This happens on a PC with a GPU as well as on CI.
sparse::tests::a_gpu_write_into_a_gpu_view_lands_in_its_cpu_viewdoes not fail on its own.It runs next to
a_gpu_view_tile_is_filled_from_its_cpu_view_and_follows_its_writes, whichuses
software()to size its GPU view: 53 tiles on a software device, 3 GiB on a GPU.software()only checksDXGI_ADAPTER_FLAG_SOFTWARE. The CI runner's default adapter isthe Microsoft Basic Render Driver, which does not have that flag, so the test reserves 3 GiB
there (the
0xc0000000 bytesreservation in the CI logs). The shared device is then removed,the next
Map(ina_gpu_write_…) returns 0x887a0005, andstop_if_device_removedends thewhole test process. That is why the failing test name changes between runs (D3D12.X: add opt-in XCL_SPARSE_VRAM_CAP_MB to overflow sparse pools to L0 system memory #3112's log ends
before
a_gpu_write_…prints FAILED). main and nvidia-dev already fixed this in 9d967cf(Tests: sparse tests take CI's Basic Render Driver for a software device #2837), which never reached amd-dev. This PR cherry-picks it.
What is in it
Tests: give the last-release test's fake resource a GetDesc: the fake's vtable gets aGetDesc(slotpc_slot!("ID3D12Resource", "GetDesc")) that returns a texture's desc, sores_releaseskips the buffer-address log and the test checks the same things as before.No assertion was changed.
Tests: sparse tests take CI's Basic Render Driver for a software device: a cherry-pick of9d967cf from main (author kept,
-x).software()also treats vendor 0x1414 / device 0x8cas software (WARP and the Basic Render Driver).
Tests: a console MS in the AS slot is refused by its MS translation: a cherry-pick of 2331f2e from main (-x).tests/d3d12_mesh_stream.rson amd-dev still expects the pre-D3D12.X: a console MS in the AS slot is translated as the mesh shader it is #541 refusal text (in the AS slot); since D3D12.X: a console MS in the AS slot is translated as the mesh shader it is #541 an MS in the AS slot is translated as the MS and refused for having no NGG variant. It only showed up once the lib tests passed, because cargo stops at the first failing test binary.Only
#[cfg(test)]code and a test file change.Tested
Windows 11, AMD RX 6650 XT, branch head 95e3651:
cargo test --lib release_tests -- --test-threads=1: 1 passed (before the fix: 1 failed, child exit 0xC0000005).cargo test -q --lib hle::d3d12x::sparse::tests::a_gpu_write_into_a_gpu_view_lands_in_its_cpu_view -- --exact, run 10 times on the GPU and 10 times withXCL_TEST_WARP=1: 20 of 20 passed.XCL_TEST_WARP=1 cargo test -q --lib hle::d3d12x::sparse:: -- --test-threads=4, run 3 times: 77 passed, 0 failed, 1 ignored each time.cargo test --lib hle::d3d12x:: -- --test-threads=1: 654 passed, 7 failed, 2 ignored. All 7 also fail on unmodified amd-dev f33df5a on this PC, and none is touched here:sparse::private_physical_pages_reach_the_gpu_on_mapping,sparse::a_tile_decommitted_and_committed_again_keeps_its_video_memory,sparse::flush_parked_does_not_free_or_reuse_tiles_while_unmap_is_in_flight,title_textures::placed_title_textures_share_vram_and_preserve_pixels, and the threetitle_textures::stream_recheck_*(PoisonError left by theplaced_…panic).cargo test --test d3d12_mesh_stream -- --test-threads=1: 3 passed (before: 1 failed).Not run to the end:
cargo test --workspacelocally (it has GPU/game-dependent failures of its own on this PC, e.g.e2eandgpu::tests that also fail on amd-dev).Regression run
Only
#[cfg(test)]code changes, butscripts/pr_check.pycountsreal.rsandsparse.rsas runtime files, so here are the two 60 sscripts/smoke.ps1runs (XCL_PREPARE=0, same title, RX 6650 XT, compute pipeline cache warmed withxcl pso-precompile --used). Firstmaind8bd9a38, then this PR's head.Peak commit is past the 1.25x rule, but that is
amd-dev's: unmodifiedamd-devf33df5a7peaks at 25,028 MB in the same run, and the cause is in #3360. This PR does not change it.Not tested
cargo test --workspace -- --test-threads=4) was not run. Only thehle::d3d12xtests were.hle::d3d12xafter this is not known. On main's CI,placed_title_textures_…skips (no reserved cube with mips) and thestream_recheck_*tests pass.AI use
Claude Code (Claude Opus 5.5, medium effort, subagent) found the cause, wrote the fix and ran the tests; coordinated by Claude Code (Claude Sonnet 5.5); the account owner did not write it. The second commit is a cherry-pick of an existing main commit (9d967cf, its own AI disclosure is in its message).