D3D12.X: log a command list submitted while its previous submit runs #2160
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
goal:world-load
good first issue
help wanted
invalid
keep-open
off-goal
question
stale
test-only
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/xcl-dev--xcl!2160
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/2160/head"
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?
@throny on GitHub · 2026-11-25 06:34 UTC · original
throny:d3d12x-resubmit-diagnostic→main· +93 −4 · 2 files · 1 commits · merged 2026-11-25 10:42 UTCPC D3D12 does not allow submitting a command list whose previous execution the GPU has not finished (debug layer id 553, "the command queue fence has not advanced past previous executions of the command list"); a console lets a title do it. During the retail title's world load the debug layer reports id 553 from about 86 s, a few seconds before the device removal of #1452. This logs it without the debug layer: one warning line when a PC list is submitted while its previous submit is still running, saying whether it is the same recording and the same queue. It is what showed the path the fix in the stacked PR takes.
Part of #1452.
What is in it
crates/xcl/src/hle/d3d12x/alloc_pool.rs:executednow signals its per-queue fence after every submit (before: only submits of the title lists it tracks), and remembers each PC list's last submit (queue, fence value, recording number). Newnote_resubmitslogs a list whose last submit is still running (the first 8, then at powers of two). Unit/GPU testa_resubmit_while_the_previous_submit_runs_is_noticed.crates/xcl/src/hle/d3d12x/real.rs:q_execute_command_listscalls it before eachExecuteCommandListschunk.alloc_pooldoes not track (the PC lists behind console lists).Tested
cargo build --workspace && cargo test --workspace -- --test-threads=4on637b82a(onmain6020a33): 1 155 passed, 0 failed, 46 ignored, first run.SKIPPED(25 lines): the wave64 GPU tests (no wave64), three per-lane forms the per-lane path refuses,heap_window_out_of_memory_falls_back_to_the_switch_form(no heap windows),pso_measurement_compiles_an_exact_synthetic_record(driver cache cannot be disabled without Developer Mode).XCL_DIRECT_DXIL=1, the same commit on top ofmain177cd40, where the removal of #1452 is reproducible here): from 89.3 s, 8 lists logged as "a new recording, the same queue", 64+ by 97 s; device removed at 101 s. With the D3D12 debug layer on, the same run shows id 553 at the same point (#1452).Regression run
scripts/smoke.ps1, the retail title, 60 s, release builds of both commits,mainfirst.main:
PR:
Not tested
AI use
🤖 Generated with Claude Code
@JJAutoCompare on GitHub · 2026-11-25 07:05 UTC · original
Independent Windows x64 + Intel Arc A770 test report on commit
637b82a72ccad39d365e302e600cdc0b6ca0dbb2.Environment
32.0.101.9175, Tiled Resources Tier 4, Resource Heap Tier 1,DoublePrecisionFloatShaderOps=0)rustc 1.100.0 (0ef1bc386 2026-11-09)(debug build), DXC1.9.2609.5 (01b62ad47)Command
Executed under serialized Arc A770 GPU mutex (
XCL_ADAPTER=A770) with pre/in/post-mutex executable SHA-256 verified (3A3AB38543C51DE1A34904719F94965BBAB0276568835F4D2AD11338C614B639):Results
xcl: D3D12.X: a command list is submitted while its previous submit is still on the GPU (the same recording, the same queue; #1 so far) – the PC does not allow it (debug layer id 553).Not tested
AI use
gemini-4-neon).@futurepro62 on GitHub · 2026-11-25 07:05 UTC · original · edited 2026-11-25 07:15 UTC
Full-suite run, since this PR has no test report yet. Tested exact head
637b82a(on its base6020a33).Tested
cargo build --workspace, thenXCL_REQUIRE_GPU=mesh cargo test --workspace -- --test-threads=4 --skip heap_window_out_of_memory_falls_back_to_the_switch_form --skip gpu::recomp::lower_dxil::tests::f16_programs_on_the_gpu --skip gpu::recomp::lower_dxil::tests::f32_programs_on_the_gpu --skip gpu::recomp::lower_dxil::tests::integer_programs_on_the_gpu --skip gpu::recomp::lower_dxil::tests::f64_programs_on_the_gpu --skip gpu::recomp::lower_dxil::tests::const_and_null_mask_operands_agree_with_hlsl_on_the_gpu --skip gpu::recomp::lower_dxil::tests::mask_ff0_and_flbit_agree_with_hlsl_on_the_gpu --skip gpu::dxil::fuzz_tests: 1143 passed, 0 failed, 44 ignored. SKIPPED (no wave64):a_2d_or_3d_group_agrees_with_the_hlsl_path_on_the_gpu,a_per_lane_2d_or_3d_group_runs_on_the_gpu,coalesced_guarded_runs_agree_with_the_hlsl_path_on_the_gpu,cross_lane_reads_agree_with_the_hlsl_path_on_the_gpu,gpu_geometry_wave32_prefix_count_over_a_mask,gpu_wave32_program_in_wave64_hardware,the_wave64_lowering_agrees_with_the_hlsl_path_on_the_gpu.a_resubmit_while_the_previous_submit_runs_is_noticed.XCL_ADAPTER=radeon),cargo test --workspace -- --test-threads=4 --skip gpu::dxil::fuzz_tests::fuzz_validate_and_gpu_1: 1154 passed, 0 failed, 46 ignored. SKIPPED:f16_programs_on_the_gpu(f16 arithmetic, wave32, per-lane form: refused (unsupported V_MUL_F16 (its #1426 semantics differ from the console's))),f16_programs_on_the_gpu(f16 arithmetic, wave64, per-lane form: refused (unsupported V_MUL_F16 (its #1426 semantics differ from the console's))),f16_programs_on_the_gpu(f16 packed, wave32, per-lane form: refused (unsupported V_PK_MUL_F16: VOP3 modifiers (its #1426 semantics differ from the console's))),f16_programs_on_the_gpu(f16 packed, wave64, per-lane form: refused (unsupported V_PK_MUL_F16: VOP3 modifiers (its #1426 semantics differ from the console's))),f32_programs_on_the_gpu(f32 conversions, wave32, per-lane form: refused (unsupported V_CVT_F16_F32 (its #1426 semantics differ from the console's))),f32_programs_on_the_gpu(f32 conversions, wave64, per-lane form: refused (unsupported V_CVT_F16_F32 (its #1426 semantics differ from the console's))),heap_window_out_of_memory_falls_back_to_the_switch_form(no heap windows).--skipleaves out tests that fail on main568e7dbtoo, not because of this PR. On NVIDIA:heap_window_out_of_memory_falls_back_to_the_switch_form(#1651), the fourgpu::recomp::lower_dxil::tests::*_programs_on_the_gputests,const_and_null_mask_operands_agree_with_hlsl_on_the_gpuandmask_ff0_and_flbit_agree_with_hlsl_on_the_gpu(follow-up on #1651) fail becauserunner::skip_testturns their skips into failures underXCL_REQUIRE_GPU=mesh, andgpu::dxil::fuzz_testsseeds 70, 545, 1019 and 1507 failCreateComputePipelineStatewithE_OUTOFMEMORYon this card (drivers 616.64 and 621.40). On AMD:fuzz_validate_and_gpu_1fails on seed 540 (res[833]0x7 vs CPU 0x6). The AMD run does not setXCL_REQUIRE_GPU.Not tested
AI use
@DavidM1911 on GitHub · 2026-11-25 07:20 UTC · original
Verification on RTX 3060 Ti (Windows 11), branch merged with current
main:cargo test -p xcl --lib: all passed, 0 failed, ~26 ignored. (Intermittent single-test flake / 0xc0000005 abort under parallel scheduling — tracked in #1978; clean on single-threaded rerun.)Thanks!