D3D12.X: retain graphics root signature across bind state #1915

Closed
n-romanovich wants to merge 1 commit from upstream-pr/1925 into main
n-romanovich commented 2026-11-24 23:22:58 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by n-romanovich on 2026-11-24T23:22:58Z.


Fixes #1488.

State.rs_gfx previously stored the graphics root signature as an unretained raw usize, causing a COM use-after-free in graphics_bound or execute_indirect if the title released its ID3D12RootSignature reference after SetGraphicsRootSignature. execute_indirect also bound rs_gfx even on COMPUTE command lists.

This PR retains ID3D12RootSignature in State.rs_gfx (when adopted via real::is_adopted) and restricts execute_indirect's graphics root signature binding to non-dispatch indirect signatures on non-COMPUTE command lists.

What is in it

  • crates/xcl/src/hle/d3d12x/bind.rs:
    • Change State::rs_gfx from usize to Option<ID3D12RootSignature>, retaining adopted objects in set_graphics_root_signature, cloning in inherit_for_split, and clearing on reset, clear_state, and forget.
    • In execute_indirect, only bind s.rs_gfx when !signature_dispatches(sig) and list.GetType() != D3D12_COMMAND_LIST_TYPE_COMPUTE (checking s.rs_gfx before calling GetType()).
    • Add unit test graphics_root_signature_is_retained_and_skipped_on_compute_ei.

Tested
Hardware: Windows 11 x64, NVIDIA GeForce RTX 5060 Ti.

  • cargo test -p xcl --lib bind::tests -- --test-threads=4: 7 passed, 0 failed, 0 ignored (945 filtered out)
  • cargo test --workspace -- --test-threads=4: 976 passed, 0 failed, 45 ignored
    • SKIPPED: gpu::recomp wave64 and unsupported per-lane f16 tests (21 skipped: no wave64 / refused per-lane f16), shaders::tests::pso_measurement_compiles_an_exact_synthetic_record (Windows Developer Mode is required, 0x887A002D), heap_window_out_of_memory_falls_back_to_the_switch_form (no heap windows)

Regression run
Main (5478c4a7c1ae5adba127c8d27018d7fdbf3a8725):

xcl-smoke v1
commit: 5478c4a7c1ae5adba127c8d27018d7fdbf3a8725
gpu: NVIDIA GeForce RTX 5060 Ti
title: FILES
seconds: 60
exit: 0x0
frames shown: 1541 (PresentX 1541)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 15701 MB

PR (7ce63fc0422aff13e5867af651f27a44d096bc92):

xcl-smoke v1
commit: 7ce63fc0422aff13e5867af651f27a44d096bc92
gpu: NVIDIA GeForce RTX 5060 Ti
title: FILES
seconds: 60
exit: 0x0
frames shown: 1572 (PresentX 1572)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 14784 MB

Not tested

  • macOS / Linux (crate targets Windows only).
  • AMD / wave64-capable GPU.

AI use

  • Antigravity (model name not provided): implemented the fix and unit test, ran the test suite and smoke.ps1 runs, and audited the diff with an independent subagent.
<!-- greyfinch-sync:ivall/xcl:issue:5482025085 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1925). Originally posted by [n-romanovich](https://github.com/n-romanovich) on 2026-11-24T23:22:58Z. --- Fixes #1488. `State.rs_gfx` previously stored the graphics root signature as an unretained raw `usize`, causing a COM use-after-free in `graphics_bound` or `execute_indirect` if the title released its `ID3D12RootSignature` reference after `SetGraphicsRootSignature`. `execute_indirect` also bound `rs_gfx` even on `COMPUTE` command lists. This PR retains `ID3D12RootSignature` in `State.rs_gfx` (when adopted via `real::is_adopted`) and restricts `execute_indirect`'s graphics root signature binding to non-dispatch indirect signatures on non-`COMPUTE` command lists. **What is in it** - `crates/xcl/src/hle/d3d12x/bind.rs`: - Change `State::rs_gfx` from `usize` to `Option<ID3D12RootSignature>`, retaining adopted objects in `set_graphics_root_signature`, cloning in `inherit_for_split`, and clearing on `reset`, `clear_state`, and `forget`. - In `execute_indirect`, only bind `s.rs_gfx` when `!signature_dispatches(sig)` and `list.GetType() != D3D12_COMMAND_LIST_TYPE_COMPUTE` (checking `s.rs_gfx` before calling `GetType()`). - Add unit test `graphics_root_signature_is_retained_and_skipped_on_compute_ei`. **Tested** Hardware: Windows 11 x64, NVIDIA GeForce RTX 5060 Ti. - `cargo test -p xcl --lib bind::tests -- --test-threads=4`: 7 passed, 0 failed, 0 ignored (`945 filtered out`) - `cargo test --workspace -- --test-threads=4`: 976 passed, 0 failed, 45 ignored - `SKIPPED`: `gpu::recomp` wave64 and unsupported per-lane f16 tests (21 skipped: `no wave64` / refused per-lane f16), `shaders::tests::pso_measurement_compiles_an_exact_synthetic_record` (`Windows Developer Mode is required`, `0x887A002D`), `heap_window_out_of_memory_falls_back_to_the_switch_form` (`no heap windows`) **Regression run** Main (`5478c4a7c1ae5adba127c8d27018d7fdbf3a8725`): ``` xcl-smoke v1 commit: 5478c4a7c1ae5adba127c8d27018d7fdbf3a8725 gpu: NVIDIA GeForce RTX 5060 Ti title: FILES seconds: 60 exit: 0x0 frames shown: 1541 (PresentX 1541) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 15701 MB ``` PR (`7ce63fc0422aff13e5867af651f27a44d096bc92`): ``` xcl-smoke v1 commit: 7ce63fc0422aff13e5867af651f27a44d096bc92 gpu: NVIDIA GeForce RTX 5060 Ti title: FILES seconds: 60 exit: 0x0 frames shown: 1572 (PresentX 1572) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 14784 MB ``` **Not tested** - macOS / Linux (crate targets Windows only). - AMD / wave64-capable GPU. **AI use** - Antigravity (model name not provided): implemented the fix and unit test, ran the test suite and `smoke.ps1` runs, and audited the diff with an independent subagent.
futurepro62 commented 2026-11-25 00:09:06 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by futurepro62 on 2026-11-24T23:55:45Z.


Full-suite run, since this PR has no test report yet. Tested exact head cfd026d (on its base 689f2db).

Tested

  • NVIDIA GeForce RTX 5070 Ti 16 GB (Blackwell, 32-lane waves only, mesh shaders), driver 621.40, Ryzen 7 9800X3D, Windows 11 Home 26300, Rust 1.100.0 MSVC, DXC + dxil.dll 1.9.2602.17 (Windows SDK 10.0.26100), debug, D3D12 debug layer installed.
  • cargo build --workspace, then XCL_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::dxil::fuzz_tests: 966 passed, 0 failed, 43 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.
  • The new tests ran and passed: graphics_root_signature_is_retained_and_skipped_on_compute_ei.
  • Same head on the AMD Radeon integrated GPU (iGPU) of the Ryzen 7 9800X3D (RDNA2, XCL_ADAPTER=radeon), cargo test --workspace -- --test-threads=4 --skip gpu::dxil::fuzz_tests::fuzz_validate_and_gpu_1: 975 passed, 0 failed, 45 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).
  • --skip leaves out tests that fail on main 62265d3 too, not because of this PR. On NVIDIA: heap_window_out_of_memory_falls_back_to_the_switch_form (#1651) and the four gpu::recomp::lower_dxil::tests::*_programs_on_the_gpu tests (follow-up on #1651) fail because runner::skip_test turns their skips into failures under XCL_REQUIRE_GPU=mesh, and gpu::dxil::fuzz_tests seeds 70, 545, 1019 and 1507 fail CreateComputePipelineState with E_OUTOFMEMORY on this card (drivers 616.64 and 621.40). On AMD: fuzz_validate_and_gpu_1 fails on seed 540 (res[833] 0x7 vs CPU 0x6). The AMD run does not set XCL_REQUIRE_GPU.

Not tested

  • a release build, a game (test run only).

AI use

  • Claude Code (Claude Opus 5.5) ran the tests and wrote this report. I checked it before posting.
<!-- greyfinch-sync:ivall/xcl:comment:7147949202 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1925#issuecomment-7147949202). Originally posted by [futurepro62](https://github.com/futurepro62) on 2026-11-24T23:55:45Z. --- Full-suite run, since this PR has no test report yet. Tested exact head `cfd026d` (on its base `689f2db`). **Tested** - NVIDIA GeForce RTX 5070 Ti 16 GB (Blackwell, 32-lane waves only, mesh shaders), driver 621.40, Ryzen 7 9800X3D, Windows 11 Home 26300, Rust 1.100.0 MSVC, DXC + dxil.dll 1.9.2602.17 (Windows SDK 10.0.26100), debug, D3D12 debug layer installed. - `cargo build --workspace`, then `XCL_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::dxil::fuzz_tests`: **966 passed, 0 failed, 43 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`. - The new tests ran and passed: `graphics_root_signature_is_retained_and_skipped_on_compute_ei`. - Same head on the AMD Radeon integrated GPU (iGPU) of the Ryzen 7 9800X3D (RDNA2, `XCL_ADAPTER=radeon`), `cargo test --workspace -- --test-threads=4 --skip gpu::dxil::fuzz_tests::fuzz_validate_and_gpu_1`: **975 passed, 0 failed, 45 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). - `--skip` leaves out tests that fail on main `62265d3` too, not because of this PR. On NVIDIA: `heap_window_out_of_memory_falls_back_to_the_switch_form` (#1651) and the four `gpu::recomp::lower_dxil::tests::*_programs_on_the_gpu` tests ([follow-up on #1651](https://github.com/xcl-dev/xcl/issues/1651#issuecomment-7146069648)) fail because `runner::skip_test` turns their skips into failures under `XCL_REQUIRE_GPU=mesh`, and `gpu::dxil::fuzz_tests` seeds 70, 545, 1019 and 1507 fail `CreateComputePipelineState` with `E_OUTOFMEMORY` on this card (drivers 616.64 and 621.40). On AMD: `fuzz_validate_and_gpu_1` fails on seed 540 (`res[833]` 0x7 vs CPU 0x6). The AMD run does not set `XCL_REQUIRE_GPU`. **Not tested** - a release build, a game (test run only). **AI use** - Claude Code (Claude Opus 5.5) ran the tests and wrote this report. I checked it before posting.
raylitebull commented 2026-11-25 02:09:02 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by raylitebull on 2026-11-25T01:54:23Z.


Code review on cfd026d:

  • Changing State.rs_gfx in crates/xcl/src/hle/d3d12x/bind.rs to retain an Option<ID3D12RootSignature> (only when real::is_adopted(rs)), propagating it in inherit_for_split, and guarding execute_indirect with !signature_dispatches(sig) and list.GetType() != D3D12_COMMAND_LIST_TYPE_COMPUTE cleanly prevents dangling raw root-signature pointers and invalid SetGraphicsRootSignature calls on compute command lists.
  • Diff audited and CI workflow approved (running).

Remaining before merge: Build and test finishing green plus AMD verification on cfd026d.

<!-- greyfinch-sync:ivall/xcl:comment:7150096289 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1925#issuecomment-7150096289). Originally posted by [raylitebull](https://github.com/raylitebull) on 2026-11-25T01:54:23Z. --- Code review on `cfd026d`: - Changing `State.rs_gfx` in `crates/xcl/src/hle/d3d12x/bind.rs` to retain an `Option<ID3D12RootSignature>` (only when `real::is_adopted(rs)`), propagating it in `inherit_for_split`, and guarding `execute_indirect` with `!signature_dispatches(sig)` and `list.GetType() != D3D12_COMMAND_LIST_TYPE_COMPUTE` cleanly prevents dangling raw root-signature pointers and invalid `SetGraphicsRootSignature` calls on compute command lists. - Diff audited and `CI` workflow approved (running). **Remaining before merge:** `Build and test` finishing green plus **AMD** verification on `cfd026d`.
DavidM1911 commented 2026-11-25 03:05:46 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by DavidM1911 on 2026-11-25T02:34:37Z.


Verification on RTX 3060 Ti (Windows 11), branch merged with current main:

  • cargo test -p xcl --lib: 1038 passed, 1 failed in one parallel run; the failing test passes on a single-threaded rerun (1039/0). Intermittent single-test flake / 0xc0000005 abort under parallel scheduling — tracked in #1978; clean on single-threaded rerun.

Thanks!

<!-- greyfinch-sync:ivall/xcl:comment:7150901577 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1925#issuecomment-7150901577). Originally posted by [DavidM1911](https://github.com/DavidM1911) on 2026-11-25T02:34:37Z. --- Verification on RTX 3060 Ti (Windows 11), branch merged with current `main`: - `cargo test -p xcl --lib`: 1038 passed, 1 failed in one parallel run; the failing test passes on a single-threaded rerun (1039/0). Intermittent single-test flake / 0xc0000005 abort under parallel scheduling — tracked in #1978; clean on single-threaded rerun. Thanks!
JJAutoCompare commented 2026-11-25 03:05:53 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by JJAutoCompare on 2026-11-25T02:55:59Z.


PR #1925 compatibility verification

Commit cfd026db9ff9ddd9c9cde6ba6d540c492e6543a7 (detached PR head). The change keeps an owned COM reference to the title's graphics root signature in bind state, clones it when splitting a command list, and clears it on reset or clear-state. The PC fallback for ExecuteIndirect skips the graphics bind for dispatch signatures and compute lists.

Tested

  • STOR-WINLAB, Windows 11 Enterprise Evaluation build 26200.9974, AMD Ryzen 7 3800X, Intel Arc A770 16 GiB (driver 32.0.101.9175, wave sizes 8–32, DoublePrecisionFloatShaderOps=0). Rust 1.100.0 (0ef1bc386), DXC/DXIL 1.9.2609.5, XCL_ADAPTER=A770, unoptimized builds with debug info disabled.
  • cargo build --workspace and cargo test --workspace --no-run both succeeded.
  • cargo test -p xcl hle::d3d12x::bind::tests -- --nocapture reported 7 passed, 0 failed, 0 ignored, and no skips. The new regression exercised retention after caller release, split inheritance, clearing, and the compute-list guard using a mock command list.
  • cargo test -p xcl test_title_draws_with_a_root_signature_under_the_debug_layer -- --nocapture reported 1 skip because d3d12SDKLayers.dll is missing. The harness reported ok after the early return.

Workspace suite

cargo test --workspace --no-fail-fast -- --test-threads=4 ran once under the shared Arc lock and exited 101. Across 20 harness summaries, Cargo reported 951 passed, 25 failed, 45 ignored. The new regression passed again.

  • 24 library failures. Twenty DXIL/recompiler tests failed at CreateComputePipelineState (0x80070057), including FP64 cases. Four showed result mismatches in fused multiply-add, implicit mip LOD, f16 lane packing, or pixel wave reduction.
  • One test-title failure. The title rendered and read back a triangle on the A770, then reported a blue pixel where the dynamic depth-bias check expected green.
  • 22 SKIPPED lines in pr1925-suite.log (17 no wave64, 3 refused wave32 per-lane forms, 1 driver cache could not be disabled, 1 no heap windows). The separate targeted run exposed the debug-layer skip, which Cargo captured in the workspace run. Skip lines can count subcases, and skips provide no coverage.

Not tested

Debug-layer draw assertions, retail-title smoke, release builds, and other adapters. The workspace failures were measured on the PR head only, so their status on main is unverified.

AI use

T3 Code / Codex (gpt-6.2-sol, reasoningEffort: high) ran the build and verification. Coordinator #2 (T3 Code / Antigravity, gemini-4-neon) verified counts against pr1925-suite.log and published this report.

<!-- greyfinch-sync:ivall/xcl:comment:7151376913 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1925#issuecomment-7151376913). Originally posted by [JJAutoCompare](https://github.com/JJAutoCompare) on 2026-11-25T02:55:59Z. --- # PR #1925 compatibility verification Commit `cfd026db9ff9ddd9c9cde6ba6d540c492e6543a7` (detached PR head). The change keeps an owned COM reference to the title's graphics root signature in bind state, clones it when splitting a command list, and clears it on reset or clear-state. The PC fallback for `ExecuteIndirect` skips the graphics bind for dispatch signatures and compute lists. **Tested** - STOR-WINLAB, Windows 11 Enterprise Evaluation build 26200.9974, AMD Ryzen 7 3800X, Intel Arc A770 16 GiB (driver 32.0.101.9175, wave sizes 8–32, `DoublePrecisionFloatShaderOps=0`). Rust 1.100.0 (`0ef1bc386`), DXC/DXIL 1.9.2609.5, `XCL_ADAPTER=A770`, unoptimized builds with debug info disabled. - `cargo build --workspace` and `cargo test --workspace --no-run` both succeeded. - `cargo test -p xcl hle::d3d12x::bind::tests -- --nocapture` reported 7 passed, 0 failed, 0 ignored, and no skips. The new regression exercised retention after caller release, split inheritance, clearing, and the compute-list guard using a mock command list. - `cargo test -p xcl test_title_draws_with_a_root_signature_under_the_debug_layer -- --nocapture` reported 1 skip because `d3d12SDKLayers.dll` is missing. The harness reported `ok` after the early return. **Workspace suite** `cargo test --workspace --no-fail-fast -- --test-threads=4` ran once under the shared Arc lock and exited 101. Across 20 harness summaries, Cargo reported **951 passed, 25 failed, 45 ignored**. The new regression passed again. - 24 library failures. Twenty DXIL/recompiler tests failed at `CreateComputePipelineState` (0x80070057), including FP64 cases. Four showed result mismatches in fused multiply-add, implicit mip LOD, f16 lane packing, or pixel wave reduction. - One test-title failure. The title rendered and read back a triangle on the A770, then reported a blue pixel where the dynamic depth-bias check expected green. - **22 `SKIPPED ` lines** in `pr1925-suite.log` (17 no wave64, 3 refused wave32 per-lane forms, 1 driver cache could not be disabled, 1 no heap windows). The separate targeted run exposed the debug-layer skip, which Cargo captured in the workspace run. Skip lines can count subcases, and skips provide no coverage. **Not tested** Debug-layer draw assertions, retail-title smoke, release builds, and other adapters. The workspace failures were measured on the PR head only, so their status on `main` is unverified. **AI use** T3 Code / Codex (`gpt-6.2-sol`, `reasoningEffort: high`) ran the build and verification. Coordinator #2 (T3 Code / Antigravity, `gemini-4-neon`) verified counts against `pr1925-suite.log` and published this report.
luckyteagirl commented 2026-11-25 03:06:02 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by luckyteagirl on 2026-11-25T03:04:51Z.


Tested

  • Exact PR head cfd026db9ff9ddd9c9cde6ba6d540c492e6543a7 on Windows 11 build 26200, Ryzen 9 5980HX, AMD Radeon RX 6800M driver 30.0.13002.13003 (plus an AMD integrated GPU), Rust 1.99.0 MSVC, DXC/DXIL 1.9.2609.5. XCL_ADAPTER=6800M, XCL_REQUIRE_GPU=1, and XCL_DIRECT_DXIL=0 were set for the test commands.
  • cargo test --locked -p xcl --lib -j 2 hle::d3d12x::bind::tests::graphics_root_signature_is_retained_and_skipped_on_compute_ei -- --exact --test-threads=1 --nocapture: 1 passed, 0 failed, 0 ignored, no explicit skip. The test creates a D3D12 device using the system default adapter, with a WARP fallback; it does not use XCL_ADAPTER to select its device, and I did not record that device's LUID.
  • The full hle::d3d12x::bind::tests group: 7 passed, 0 failed, 0 ignored. The broader hle::d3d12x:: subset: 156 passed, 0 failed, 2 ignored, with one explicit SKIPPED line because this adapter makes no reserved cube with mips. Both subset runs used one test thread.
  • cargo build --locked --workspace -j 2 and cargo build --locked --release -p xcl -j 2: passed.

Smoke attempt

Two monitored 7-second runs of a locally owned title on the RX 6800M reached the first frame. The first logged the XCL_RUN_SECONDS: 7 s end marker; the second was stopped just after its 6-second activity sample. In both, low system commit availability triggered the local memory guard before scripts/smoke.ps1 could write its xcl-smoke v1 summary. Neither attempt is a completed smoke result, and there is no paired main run to compare. I have not counted them as a pass.

Not tested

  • A completed paired title smoke, the full workspace suite, the exact LUID of the focused test's default D3D12 device, longer gameplay, or other drivers and GPUs. The short title attempts logged zero draws, so they did not exercise root-signature binding in game draws.

AI use

OpenAI Codex (GPT-6, exact variant not exposed in this session) inspected the diff, ran the builds and tests, monitored the smoke attempts, reviewed their logs, and drafted this report.

<!-- greyfinch-sync:ivall/xcl:comment:7151569820 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1925#issuecomment-7151569820). Originally posted by [luckyteagirl](https://github.com/luckyteagirl) on 2026-11-25T03:04:51Z. --- **Tested** - Exact PR head `cfd026db9ff9ddd9c9cde6ba6d540c492e6543a7` on Windows 11 build 26200, Ryzen 9 5980HX, AMD Radeon RX 6800M driver `30.0.13002.13003` (plus an AMD integrated GPU), Rust 1.99.0 MSVC, DXC/DXIL 1.9.2609.5. `XCL_ADAPTER=6800M`, `XCL_REQUIRE_GPU=1`, and `XCL_DIRECT_DXIL=0` were set for the test commands. - `cargo test --locked -p xcl --lib -j 2 hle::d3d12x::bind::tests::graphics_root_signature_is_retained_and_skipped_on_compute_ei -- --exact --test-threads=1 --nocapture`: **1 passed, 0 failed, 0 ignored**, no explicit skip. The test creates a D3D12 device using the system default adapter, with a WARP fallback; it does not use `XCL_ADAPTER` to select its device, and I did not record that device's LUID. - The full `hle::d3d12x::bind::tests` group: **7 passed, 0 failed, 0 ignored**. The broader `hle::d3d12x::` subset: **156 passed, 0 failed, 2 ignored**, with one explicit `SKIPPED` line because this adapter makes no reserved cube with mips. Both subset runs used one test thread. - `cargo build --locked --workspace -j 2` and `cargo build --locked --release -p xcl -j 2`: passed. **Smoke attempt** Two monitored 7-second runs of a locally owned title on the RX 6800M reached the first frame. The first logged the `XCL_RUN_SECONDS: 7 s` end marker; the second was stopped just after its 6-second activity sample. In both, low system commit availability triggered the local memory guard before `scripts/smoke.ps1` could write its `xcl-smoke v1` summary. Neither attempt is a completed smoke result, and there is no paired main run to compare. I have not counted them as a pass. **Not tested** - A completed paired title smoke, the full workspace suite, the exact LUID of the focused test's default D3D12 device, longer gameplay, or other drivers and GPUs. The short title attempts logged zero draws, so they did not exercise root-signature binding in game draws. **AI use** OpenAI Codex (GPT-6, exact variant not exposed in this session) inspected the diff, ran the builds and tests, monitored the smoke attempts, reviewed their logs, and drafted this report.
Royalflamejlh commented 2026-11-25 05:08:27 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Royalflamejlh on 2026-11-25T04:55:10Z.


Linux (Wine + vkd3d-proton) + NVIDIA test of cfd026d merged on main 80f4819 with #684: 10 runs of 100 s of a retail title with it, 5 without. 9 of the 10 with it stopped presenting at 74.7 to 92.2 s (without it: 78.2 to 99.6 s); 1 stopped at 52 s and ended at the title's stall watchdog. I found nothing that ties that stall to the change.

Setup: Fedora 44, Wine 11.21 Staging, vkd3d-proton v3.1-90-g30b0eb9b with the relaxed-vtable patch from #175 and a local dxil-spirv patch, RTX 4070 12 GB (driver 615.71.09), 62 GB RAM. Release, cross-compiled to x86_64-pc-windows-gnu (rustc 1.98.0), XCL_PSO_PRELOAD=0. Retail title 1.0.2.1, the first-run screens completed once and no story progress, A pressed when the title presents steadily.

Tested

100 s without (5 runs) with cfd026d (10 runs)
frames 1377, 1405, 1420, 1566, 1357 1325, 1251, 1412, 1416, 1544, 1289, 1307, 1410, 1383, 1312
last 2 s with a present 78.2, 99.6, 90.8, 90.5, 84.1 s 76.2, 52.0, 86.4, 92.2, 84.1, 74.7, 76.1, 78.1, 86.3, 76.6 s
ended at game+0x23cf683 (the stall watchdog) 0 1 (the second, at 93.6 s)
draws skipped, with PC pipelines; dispatches skipped (last count line) 0, 0; 0 in each 0, 0; 0 in each
device removals, NVIDIA kernel messages 0 0
  • The run that stalled: XCL's activity thread logged at 52.0 s and the memory line it prints straight after came at 62.6 s; no later line has a draw or a present. That memory line reads XCL's page, pool and arena tables and DXGI's budget, not the bind state (host.rs:65-68), and it was late without the change too, by 3.3 s and 1.1 s in two runs. The audio thread kept time throughout. No thread dump was taken.
  • The kernel logged nothing during that run, and write errors on its compressed swap during 9 of the 14 others, so low memory does not single it out.

Read

  • bind.rs:177: the reference is kept only for a root signature XCL adopted, and every one the title gets is adopted where it is made (real.rs:5259 at cfd026d). Root signatures have no Release hook of XCL's, so taking and dropping the reference under the bind state's lock waits on nothing of XCL's.

Not tested: the bind the change is for (every run's last count line has 0 draws with PC pipelines); a title that releases its root signature before a draw; Windows; AMD and Intel; past 100 s.

AI use: Claude Code (Claude Fable 5.2) read the diff, built the trees, ran the title and the tests, and wrote this comment.

Posted without review by a person: the account owner was away and reads replies later.

<!-- greyfinch-sync:ivall/xcl:comment:7153282378 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1925#issuecomment-7153282378). Originally posted by [Royalflamejlh](https://github.com/Royalflamejlh) on 2026-11-25T04:55:10Z. --- Linux (Wine + vkd3d-proton) + NVIDIA test of `cfd026d` merged on `main` `80f4819` with #684: 10 runs of 100 s of a retail title with it, 5 without. 9 of the 10 with it stopped presenting at 74.7 to 92.2 s (without it: 78.2 to 99.6 s); 1 stopped at 52 s and ended at the title's stall watchdog. I found nothing that ties that stall to the change. **Setup:** Fedora 44, Wine 11.21 Staging, vkd3d-proton v3.1-90-g30b0eb9b with the relaxed-vtable patch from #175 and a local dxil-spirv patch, RTX 4070 12 GB (driver 615.71.09), 62 GB RAM. Release, cross-compiled to `x86_64-pc-windows-gnu` (rustc 1.98.0), `XCL_PSO_PRELOAD=0`. Retail title 1.0.2.1, the first-run screens completed once and no story progress, A pressed when the title presents steadily. **Tested** | 100 s | without (5 runs) | with `cfd026d` (10 runs) | |---|---|---| | frames | 1377, 1405, 1420, 1566, 1357 | 1325, 1251, 1412, 1416, 1544, 1289, 1307, 1410, 1383, 1312 | | last 2 s with a present | 78.2, 99.6, 90.8, 90.5, 84.1 s | 76.2, 52.0, 86.4, 92.2, 84.1, 74.7, 76.1, 78.1, 86.3, 76.6 s | | ended at `game+0x23cf683` (the stall watchdog) | 0 | 1 (the second, at 93.6 s) | | draws skipped, with PC pipelines; dispatches skipped (last count line) | 0, 0; 0 in each | 0, 0; 0 in each | | device removals, NVIDIA kernel messages | 0 | 0 | - The run that stalled: XCL's activity thread logged at 52.0 s and the memory line it prints straight after came at 62.6 s; no later line has a draw or a present. That memory line reads XCL's page, pool and arena tables and DXGI's budget, not the bind state (`host.rs:65-68`), and it was late without the change too, by 3.3 s and 1.1 s in two runs. The audio thread kept time throughout. No thread dump was taken. - The kernel logged nothing during that run, and write errors on its compressed swap during 9 of the 14 others, so low memory does not single it out. **Read** - `bind.rs:177`: the reference is kept only for a root signature XCL adopted, and every one the title gets is adopted where it is made (`real.rs:5259` at `cfd026d`). Root signatures have no `Release` hook of XCL's, so taking and dropping the reference under the bind state's lock waits on nothing of XCL's. **Not tested:** the bind the change is for (every run's last count line has 0 draws with PC pipelines); a title that releases its root signature before a draw; Windows; AMD and Intel; past 100 s. **AI use:** Claude Code (Claude Fable 5.2) read the diff, built the trees, ran the title and the tests, and wrote this comment. Posted without review by a person: the account owner was away and reads replies later.
throny commented 2026-11-25 19:09:01 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by throny on 2026-11-25T18:18:50Z.


Two contributors checked independently and found that #1764 solves the same problem (for #1488) in a different way: #1607, group D93. You may want to compare them with the other author and agree on one, or say in the PR why both are needed.

This is a hint from the community triage in #1607, not a maintainer decision.

AI use: Claude Code (Claude Opus 5.5), posted by a script from the #1607 table.

<!-- greyfinch-sync:ivall/xcl:comment:7170737399 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1925#issuecomment-7170737399). Originally posted by [throny](https://github.com/throny) on 2026-11-25T18:18:50Z. --- <!-- xcl-1607-hint:D93 --> Two contributors checked independently and found that #1764 solves the same problem (for #1488) in a different way: #1607, group D93. You may want to compare them with the other author and agree on one, or say in the PR why both are needed. This is a hint from the community triage in #1607, not a maintainer decision. AI use: Claude Code (Claude Opus 5.5), posted by a script from the #1607 table.
upstream-sync closed this pull request 2026-11-25 23:07:50 +00:00
CalvyPZ commented 2026-11-25 23:09:14 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by CalvyPZ on 2026-11-25T22:42:39Z.


This PR has been marked as a duplicate and closed after multiple agreeing checks in #1607. If you believe this is incorrect please re-open with why.

<!-- greyfinch-sync:ivall/xcl:comment:7176696240 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1925#issuecomment-7176696240). Originally posted by [CalvyPZ](https://github.com/CalvyPZ) on 2026-11-25T22:42:39Z. --- This PR has been marked as a duplicate and closed after multiple agreeing checks in #1607. If you believe this is incorrect please re-open with why.
upstream-sync reopened this pull request 2026-11-26 00:04:43 +00:00
DavidM1911 commented 2026-11-26 07:03:37 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by DavidM1911 on 2026-11-26T06:41:20Z.


Re-verification on RTX 3060 Ti (Windows 11), new head merged with current main:

  • cargo test -p xcl --lib: all passed, 0 failed, 27 ignored. The earlier merge conflict is resolved.

Thanks!

— Devin

<!-- greyfinch-sync:ivall/xcl:comment:7184681772 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1925#issuecomment-7184681772). Originally posted by [DavidM1911](https://github.com/DavidM1911) on 2026-11-26T06:41:20Z. --- Re-verification on RTX 3060 Ti (Windows 11), new head merged with current `main`: - `cargo test -p xcl --lib`: all passed, 0 failed, 27 ignored. The earlier merge conflict is resolved. Thanks! — Devin
github-actions[bot] commented 2026-11-30 08:43:31 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by github-actions[bot] on 2026-11-30T08:43:31Z.


Nothing has happened on this PR for 3 days, so it is marked stale and will be closed in 4 days. A push or a comment takes the mark off: rebase it onto main if it conflicts, and say in one line what it still fixes. If it only waits for a maintainer, a comment saying so is enough.

<!-- greyfinch-sync:ivall/xcl:comment:7273264625 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1925#issuecomment-7273264625). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-11-30T08:43:31Z. --- Nothing has happened on this PR for 3 days, so it is marked `stale` and will be closed in 4 days. A push or a comment takes the mark off: rebase it onto `main` if it conflicts, and say in one line what it still fixes. If it only waits for a maintainer, a comment saying so is enough.
Foniass commented 2026-12-01 07:06:01 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Foniass on 2026-12-01T07:06:01Z.


Triage (#1607) – head 7ce63fc

#1764 makes the same change in crates/xcl/src/hle/d3d12x/bind.rs. It keeps a COM reference to the graphics root signature in State instead of a raw usize, carries it across splits and resets, and does not bind it on a COMPUTE list in execute_indirect. #1764 was opened first (2026-11-24 20:23 vs 23:22), is built on current main (install_reset / prepare_split), merges cleanly, and also keeps a reference to the compute root signature.
This PR conflicts with main. It also only keeps a reference when real::is_adopted(rs). A root signature that is not adopted is no longer bound in graphics_bound (before, the raw pointer was bound).
Recommendation: close (duplicate of #1764).

AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.

<!-- greyfinch-sync:ivall/xcl:comment:7303644623 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1925#issuecomment-7303644623). Originally posted by [Foniass](https://github.com/Foniass) on 2026-12-01T07:06:01Z. --- **Triage (#1607)** – head 7ce63fc #1764 makes the same change in `crates/xcl/src/hle/d3d12x/bind.rs`. It keeps a COM reference to the graphics root signature in `State` instead of a raw `usize`, carries it across splits and resets, and does not bind it on a COMPUTE list in `execute_indirect`. #1764 was opened first (2026-11-24 20:23 vs 23:22), is built on current main (`install_reset` / `prepare_split`), merges cleanly, and also keeps a reference to the compute root signature. This PR conflicts with main. It also only keeps a reference when `real::is_adopted(rs)`. A root signature that is not adopted is no longer bound in `graphics_bound` (before, the raw pointer was bound). Recommendation: close (duplicate of #1764). AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.
throny commented 2026-12-01 16:13:20 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by throny on 2026-12-01T16:13:20Z.


Closing as superseded: the same change is in #1764 (open, mergeable, required checks green). From Foniass's rechecked close list on #1607, checked again by script just now. If something here is still missing, say so and reopen it, or ask and I will.

AI use: Claude Code (Claude Opus 5.5).

<!-- greyfinch-sync:ivall/xcl:comment:7317238167 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/1925#issuecomment-7317238167). Originally posted by [throny](https://github.com/throny) on 2026-12-01T16:13:20Z. --- Closing as superseded: the same change is in #1764 (open, mergeable, required checks green). From Foniass's rechecked close list on #1607, checked again by script just now. If something here is still missing, say so and reopen it, or ask and I will. AI use: Claude Code (Claude Opus 5.5).

Pull request closed

Sign in to join this conversation.
No reviewers
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
xcl-dev/xcl!1915
No description provided.