D3D12.X: MakeResident and Evict give the driver the pipeline behind a stand-in #2513

Open
oni-swr wants to merge 1 commit from upstream-pr/2523 into main
oni-swr commented 2026-11-25 21:33:07 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by oni-swr on 2026-11-25T21:33:07Z.


A shared stand-in (standin::shell) is a Rust object, not a D3D12Core pipeline. Device #34 MakeResident and #35 Evict keep the PC layout for console code and had no override, so a stand-in pipeline in the title's ppObjects array reached the driver as *mut Shell. Both are overridden now: each shell goes to the driver as the pipeline behind it (the real one once built, otherwise its shared driver pipeline) in a copy of the array. The title's array is not changed, and a residency call does not start or wait for a lazy build.

Fixes #2455

I checked each entry point in #2455 against main @ 6d12f58a. Title code cannot reach the others, so this PR leaves them alone:

  • #46 SetResidencyPriority, #51 EnqueueMakeResident: device slots from #44 that are not in console_slots are console extensions (console_extensions). A title call gets the logged S_OK stub and never reaches D3D12Core.
  • ID3D12PipelineLibrary::StorePipeline: console device #44 is CreatePlacedResourceX, so a title never gets a native pipeline library. Only the runtime can reach the PC CreatePipelineLibrary, and it has no shells. (#2001 would wire up a pipeline library. If it lands, StorePipeline needs this treatment.)
  • PC CreateCommandList (dev_create_command_list): title calls of #12 are split to device_x::create_command_list_pc, which resolves pInitialState. XCL's own callers pass resolved pipelines or 0 (create_list, create_raw_pc_command_list from list_x), and console-shaped lists turn shared stand-ins off.

What is in it

  • crates/xcl/src/hle/d3d12x/real.rs: dev_make_resident / dev_evict overrides via with_driver_objects, plus CPU tests (residency_tests) with a fake adopted device and fake driver methods
  • crates/xcl/src/hle/d3d12x/standin.rs: driver_object (shell → driver pipeline, any other object unchanged). The shells' vtable moves to a module static so a non-shell is told apart without making the vtable.
  • crates/xcl/src/hle/d3d12x/pso_async.rs: current, the pipeline behind a stand-in now, without building or waiting

Tested

  • AMD Ryzen 7 5700X3D, Windows 11 Pro 10.0.26200, Rust 1.100.0, debug, CPU only (XCL_ADAPTER=NONE_CPU_ONLY; the GPU was in use by another job), commit 8b290bf2
  • cargo build --workspace -j 4: OK
  • On a GPU, exact head 1838468d (clean detached checkout), AMD Radeon RX 7800 XT (driver 32.0.31035.1003), Windows 11 Pro build 26200, rustc 1.100.0, debug, no XCL_ADAPTER set (hardware adapter, no WARP), XCL_SAMPLE_* unset:
    • cargo test --workspace -j 4 --no-fail-fast -- --test-threads=4 after cargo build --workspace: 1426 passed, 1 failed, 46 ignored across all test binaries (lib: 1301 passed, 1 failed, 26 ignored). All four residency_tests ran and passed, including gpu_residency_calls_with_a_stand_in_on_a_debug_device (not skipped). 7 SKIPPED messages: six f16_programs_on_the_gpu / f32_programs_on_the_gpu cases that the lowering refuses (V_MUL_F16 / V_PK_MUL_F16 / V_CVT_F16_F32, #1426) and heap_window_out_of_memory_falls_back_to_the_switch_form (no heap windows).
    • the one failure is gpu::dxil::fuzz_tests::fuzz_validate_and_gpu_1 ("seed 722: res[30] = 0x1, CPU 0x7fffffff"). It fails the same way, same seed, on main at e120925e, so it is not caused by this PR.
  • cargo test -j 4 -p xcl --lib -- hle::d3d12x::standin:: hle::d3d12x::pso_async:: hle::d3d12x::real::residency_tests::: 19 passed, 0 failed, 0 ignored, no SKIPPED
  • Negative control: with driver_object bypassed in with_driver_objects, residency_calls_give_the_driver_the_pipeline_behind_a_stand_in fails because the driver gets the shell's address. The other two tests pass.
  • cargo clippy -p xcl --lib --tests: no warnings on the changed lines. The crate fails clippy on main already (3 approx_constant errors in gpu/dxil/lower_valu.rs, lower_wide.rs, gpu/recomp/lower.rs).
  • cargo fmt --check: no diffs on the changed lines. The tree is not rustfmt-clean, so only the new items were formatted.

Regression run
Same title, 60 s each, same machine, run one after the other. First block: main at the PR's merge base (6d12f58a). Second block: this PR's head, clean tree.

xcl-smoke v1
commit: 6d12f58a229bc73889878a448c64dc3af25eeba0
gpu: AMD Radeon RX 7800 XT
title: 2c508222
seconds: 60
exit: 0x0
frames shown: 1342 (PresentX 1342)
presents per 2 s (last 3): 60 57 56
device removals: 0
crashes: 0
peak commit: 15153 MB
xcl-smoke v1
commit: 1838468d045d3f8638e9df4dfc8c8f0c0bc2005e
gpu: AMD Radeon RX 7800 XT
title: 2c508222
seconds: 60
exit: 0x0
frames shown: 1449 (PresentX 1449)
presents per 2 s (last 3): 61 62 60
device removals: 0
crashes: 0
peak commit: 15667 MB

Not tested

  • Other adapters (NVIDIA, Intel, wave32-only GPUs): only the RX 7800 XT was used
  • A title that actually passes a stand-in pipeline to MakeResident / Evict. The fix is only checked with fake objects. The smoke run above is a regression check; it was not checked whether that title reaches MakeResident / Evict with a stand-in.

AI use

  • AI-assisted: Claude Code (Claude Sonnet 5.5); coordinated by Codex (gpt-6.2-sol) and Claude Code (Claude Opus 5.5). Earlier commands and the first version of this description: Claude Code (Claude Opus 5.5). The smoke runs above were made by Claude Code with scripts/smoke.ps1, unedited.
  • The GPU workspace test run and the check of the seed-722 failure against main were made with Claude Code (Claude Sonnet 5.5), which also added them to this description.

🤖 Generated with Claude Code

<!-- greyfinch-sync:ivall/xcl:issue:5499536415 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2523). Originally posted by [oni-swr](https://github.com/oni-swr) on 2026-11-25T21:33:07Z. --- A shared stand-in (`standin::shell`) is a Rust object, not a D3D12Core pipeline. Device #34 `MakeResident` and #35 `Evict` keep the PC layout for console code and had no override, so a stand-in pipeline in the title's `ppObjects` array reached the driver as `*mut Shell`. Both are overridden now: each shell goes to the driver as the pipeline behind it (the real one once built, otherwise its shared driver pipeline) in a copy of the array. The title's array is not changed, and a residency call does not start or wait for a lazy build. Fixes #2455 I checked each entry point in #2455 against `main @ 6d12f58a`. Title code cannot reach the others, so this PR leaves them alone: - **#46 `SetResidencyPriority`, #51 `EnqueueMakeResident`:** device slots from #44 that are not in `console_slots` are console extensions (`console_extensions`). A title call gets the logged S_OK stub and never reaches D3D12Core. - **`ID3D12PipelineLibrary::StorePipeline`:** console device #44 is `CreatePlacedResourceX`, so a title never gets a native pipeline library. Only the runtime can reach the PC `CreatePipelineLibrary`, and it has no shells. (#2001 would wire up a pipeline library. If it lands, `StorePipeline` needs this treatment.) - **PC `CreateCommandList` (`dev_create_command_list`):** title calls of #12 are split to `device_x::create_command_list_pc`, which resolves `pInitialState`. XCL's own callers pass resolved pipelines or 0 (`create_list`, `create_raw_pc_command_list` from `list_x`), and console-shaped lists turn shared stand-ins off. **What is in it** - `crates/xcl/src/hle/d3d12x/real.rs`: `dev_make_resident` / `dev_evict` overrides via `with_driver_objects`, plus CPU tests (`residency_tests`) with a fake adopted device and fake driver methods - `crates/xcl/src/hle/d3d12x/standin.rs`: `driver_object` (shell → driver pipeline, any other object unchanged). The shells' vtable moves to a module static so a non-shell is told apart without making the vtable. - `crates/xcl/src/hle/d3d12x/pso_async.rs`: `current`, the pipeline behind a stand-in now, without building or waiting **Tested** - AMD Ryzen 7 5700X3D, Windows 11 Pro 10.0.26200, Rust 1.100.0, debug, CPU only (`XCL_ADAPTER=NONE_CPU_ONLY`; the GPU was in use by another job), commit `8b290bf2` - `cargo build --workspace -j 4`: OK - On a GPU, exact head `1838468d` (clean detached checkout), AMD Radeon RX 7800 XT (driver 32.0.31035.1003), Windows 11 Pro build 26200, rustc 1.100.0, debug, no `XCL_ADAPTER` set (hardware adapter, no WARP), `XCL_SAMPLE_*` unset: - `cargo test --workspace -j 4 --no-fail-fast -- --test-threads=4` after `cargo build --workspace`: 1426 passed, 1 failed, 46 ignored across all test binaries (lib: 1301 passed, 1 failed, 26 ignored). All four `residency_tests` ran and passed, including `gpu_residency_calls_with_a_stand_in_on_a_debug_device` (not skipped). 7 SKIPPED messages: six `f16_programs_on_the_gpu` / `f32_programs_on_the_gpu` cases that the lowering refuses (V_MUL_F16 / V_PK_MUL_F16 / V_CVT_F16_F32, #1426) and `heap_window_out_of_memory_falls_back_to_the_switch_form` (no heap windows). - the one failure is `gpu::dxil::fuzz_tests::fuzz_validate_and_gpu_1` ("seed 722: res[30] = 0x1, CPU 0x7fffffff"). It fails the same way, same seed, on `main` at `e120925e`, so it is not caused by this PR. - `cargo test -j 4 -p xcl --lib -- hle::d3d12x::standin:: hle::d3d12x::pso_async:: hle::d3d12x::real::residency_tests::`: 19 passed, 0 failed, 0 ignored, no SKIPPED - Negative control: with `driver_object` bypassed in `with_driver_objects`, `residency_calls_give_the_driver_the_pipeline_behind_a_stand_in` fails because the driver gets the shell's address. The other two tests pass. - `cargo clippy -p xcl --lib --tests`: no warnings on the changed lines. The crate fails clippy on `main` already (3 `approx_constant` errors in `gpu/dxil/lower_valu.rs`, `lower_wide.rs`, `gpu/recomp/lower.rs`). - `cargo fmt --check`: no diffs on the changed lines. The tree is not rustfmt-clean, so only the new items were formatted. **Regression run** Same title, 60 s each, same machine, run one after the other. First block: `main` at the PR's merge base (`6d12f58a`). Second block: this PR's head, clean tree. ``` xcl-smoke v1 commit: 6d12f58a229bc73889878a448c64dc3af25eeba0 gpu: AMD Radeon RX 7800 XT title: 2c508222 seconds: 60 exit: 0x0 frames shown: 1342 (PresentX 1342) presents per 2 s (last 3): 60 57 56 device removals: 0 crashes: 0 peak commit: 15153 MB ``` ``` xcl-smoke v1 commit: 1838468d045d3f8638e9df4dfc8c8f0c0bc2005e gpu: AMD Radeon RX 7800 XT title: 2c508222 seconds: 60 exit: 0x0 frames shown: 1449 (PresentX 1449) presents per 2 s (last 3): 61 62 60 device removals: 0 crashes: 0 peak commit: 15667 MB ``` **Not tested** - Other adapters (NVIDIA, Intel, wave32-only GPUs): only the RX 7800 XT was used - A title that actually passes a stand-in pipeline to `MakeResident` / `Evict`. The fix is only checked with fake objects. The smoke run above is a regression check; it was not checked whether that title reaches `MakeResident` / `Evict` with a stand-in. **AI use** - AI-assisted: Claude Code (Claude Sonnet 5.5); coordinated by Codex (gpt-6.2-sol) and Claude Code (Claude Opus 5.5). Earlier commands and the first version of this description: Claude Code (Claude Opus 5.5). The smoke runs above were made by Claude Code with `scripts/smoke.ps1`, unedited. - The GPU workspace test run and the check of the seed-722 failure against `main` were made with Claude Code (Claude Sonnet 5.5), which also added them to this description. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
DavidM1911 commented 2026-11-25 22:06:51 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by DavidM1911 on 2026-11-25T21:54:05Z.


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!

<!-- greyfinch-sync:ivall/xcl:comment:7175684016 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2523#issuecomment-7175684016). Originally posted by [DavidM1911](https://github.com/DavidM1911) on 2026-11-25T21:54:05Z. --- 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!
SlopTart commented 2026-11-25 23:09:19 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by SlopTart on 2026-11-25T22:49:53Z.


Tested: current PR head merged onto current origin/main (clean), Linux (Arch, kernel 7.2.15), Mesa 26.2.5 RADV, Radeon RX 7900 XT (NAVI31), cargo target x86_64-pc-windows-gnu run under wine-11.0 (Proton), rustc 1.94.0, vkd3d-proton 3.1 with the XCL patch, official MS DXC (binaries 2026-09-29).

gpu_ suite (cold cache): 164 passed / 3 failed, no crashes. The three are the known baseline on this lane (seed-1003 fuzz, mad/mac contraction, promoted-UAV-clear driver gap, PR #2490); none caused by this PR.
Targeted run of residency_calls_give_the_driver_the_pipeline_behind_a_stand_in and residency_calls_without_stand_ins_hand_the_driver_the_titles_array: 2 passed.

Not tested: retail titles (no title data on this lane, counts only).

AI use: Hermes agent (local Qwen-class) ran both machines and drafted this; I checked it before posting.

<!-- greyfinch-sync:ivall/xcl:comment:7176837105 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2523#issuecomment-7176837105). Originally posted by [SlopTart](https://github.com/SlopTart) on 2026-11-25T22:49:53Z. --- **Tested**: current PR head merged onto current `origin/main` (clean), Linux (Arch, kernel 7.2.15), Mesa 26.2.5 RADV, Radeon RX 7900 XT (NAVI31), cargo target `x86_64-pc-windows-gnu` run under wine-11.0 (Proton), rustc 1.94.0, vkd3d-proton 3.1 with the XCL patch, official MS DXC (binaries 2026-09-29). `gpu_` suite (cold cache): 164 passed / 3 failed, no crashes. The three are the known baseline on this lane (seed-1003 fuzz, mad/mac contraction, promoted-UAV-clear driver gap, PR #2490); none caused by this PR. Targeted run of `residency_calls_give_the_driver_the_pipeline_behind_a_stand_in` and `residency_calls_without_stand_ins_hand_the_driver_the_titles_array`: 2 passed. **Not tested**: retail titles (no title data on this lane, counts only). **AI use**: Hermes agent (local Qwen-class) ran both machines and drafted this; I checked it before posting.
oni-swr commented 2026-11-26 01:05:38 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by oni-swr on 2026-11-26T00:24:54Z.


Synthetic verification on Windows for head 8b290bf2944d9dd30cfc5c1f234b4cf312975331.

  • cargo build --workspace -j 4 passed.
  • cargo test --workspace -j 4 --no-fail-fast -- --test-threads=4 --show-output reported 1,425 passed, 1 failed, and 46 ignored. Seven skip messages already reflected in Cargo’s counts covered six direct-DXIL subcases and one heap-window test.
  • All three residency tests passed. The sole failure, fuzz_validate_and_gpu_1 at seed 722, also reproduced in the preceding run on main at e1d84b7d.
  • Test host was an RX 7800 XT (driver 32.0.31035.1003), Ryzen 7 5700X3D, Windows 11 25H2 (26200.9974), and Rust 1.100.0 in debug mode. XCL_ADAPTER selected the AMD card and XCL_SAMPLE_* was unset.

Real-title smoke remains pending. The PR is still a draft.

AI use: Codex (gpt-6.2-sol) ran the verification and prepared this report.

<!-- greyfinch-sync:ivall/xcl:comment:7178730546 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2523#issuecomment-7178730546). Originally posted by [oni-swr](https://github.com/oni-swr) on 2026-11-26T00:24:54Z. --- Synthetic verification on Windows for head `8b290bf2944d9dd30cfc5c1f234b4cf312975331`. - `cargo build --workspace -j 4` passed. - `cargo test --workspace -j 4 --no-fail-fast -- --test-threads=4 --show-output` reported 1,425 passed, 1 failed, and 46 ignored. Seven skip messages already reflected in Cargo’s counts covered six direct-DXIL subcases and one heap-window test. - All three residency tests passed. The sole failure, `fuzz_validate_and_gpu_1` at seed 722, also reproduced in the preceding run on `main` at `e1d84b7d`. - Test host was an RX 7800 XT (driver 32.0.31035.1003), Ryzen 7 5700X3D, Windows 11 25H2 (26200.9974), and Rust 1.100.0 in debug mode. `XCL_ADAPTER` selected the AMD card and `XCL_SAMPLE_*` was unset. Real-title smoke remains pending. The PR is still a draft. AI use: Codex (gpt-6.2-sol) ran the verification and prepared this report.
luckyteagirl commented 2026-11-26 07:11:53 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by luckyteagirl on 2026-11-26T07:11:53Z.

Review: COMMENTED


This removes the Rust shell pointer from the driver call, but replaces it with a native pipeline state object. Microsoft's MakeResident contract and Evict contract limit residency changes to descriptor heaps, heaps, committed resources, and query heaps; a PSO is not supported even though it implements ID3D12Pageable. A mixed array with a real heap and a stand-in still reaches the native call with an unsupported PSO entry. The fake driver in the new tests records and accepts that array, so it cannot establish the real call's behavior.

Could the shell entry be handled explicitly before forwarding the supported objects, and could a real D3D12 device/debug-layer test check the HRESULT and diagnostics for a mixed array? I have not observed a driver failure or run a title; this is an exact-head API-contract review of 8b290bf2944d9dd30cfc5c1f234b4cf312975331. AI-assisted review with Codex.

<!-- greyfinch-sync:ivall/xcl:review:6069887210 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2523#pullrequestreview-6069887210). Originally posted by [luckyteagirl](https://github.com/luckyteagirl) on 2026-11-26T07:11:53Z. **Review:** COMMENTED --- This removes the Rust shell pointer from the driver call, but replaces it with a native pipeline state object. [Microsoft's `MakeResident` contract](https://learn.microsoft.com/en-us/windows/win32/api/d3d12/nf-d3d12-id3d12device-makeresident) and [`Evict` contract](https://learn.microsoft.com/en-us/windows/win32/api/d3d12/nf-d3d12-id3d12device-evict) limit residency changes to descriptor heaps, heaps, committed resources, and query heaps; a PSO is not supported even though it implements `ID3D12Pageable`. A mixed array with a real heap and a stand-in still reaches the native call with an unsupported PSO entry. The fake driver in the new tests records and accepts that array, so it cannot establish the real call's behavior. Could the shell entry be handled explicitly before forwarding the supported objects, and could a real D3D12 device/debug-layer test check the HRESULT and diagnostics for a mixed array? I have not observed a driver failure or run a title; this is an exact-head API-contract review of `8b290bf2944d9dd30cfc5c1f234b4cf312975331`. AI-assisted review with Codex.
oni-swr commented 2026-11-26 14:03:05 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by oni-swr on 2026-11-26T13:25:34Z.


@luckyteagirl Thanks, you're right. A stand-in's backing pipeline is still a PSO, which MakeResident/Evict don't support. Stand-ins are now left out of the array before the driver call (head 1838468d). The driver gets the other objects in order and its HRESULT is returned unchanged. A call with only stand-ins returns S_OK without a driver call.

Tests:

  • synthetic tests cover mixed, stand-in only, supported only, empty and null arrays, and an E_OUTOFMEMORY pass-through;
  • a real-device debug-layer test on an RX 7800 XT runs a mixed array of heap, committed buffer, descriptor heap and query heap plus a stand-in. Evict and MakeResident return S_OK with 0 debug messages.

The full suite has 1426 passed, 1 failed and 46 ignored. The failure is the existing seed-722 fuzz test (#2115), which also fails on main.

The paired scripts/smoke.ps1 run is still pending, so the PR stays a draft until the xcl-smoke blocks are added.

AI-assisted: code and reply by Claude Code (Claude Sonnet 5.5); coordinated by Codex (gpt-6.2-sol) and Claude Code (Claude Opus 5.5).

<!-- greyfinch-sync:ivall/xcl:comment:7193334312 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2523#issuecomment-7193334312). Originally posted by [oni-swr](https://github.com/oni-swr) on 2026-11-26T13:25:34Z. --- @luckyteagirl Thanks, you're right. A stand-in's backing pipeline is still a PSO, which `MakeResident`/`Evict` don't support. Stand-ins are now left out of the array before the driver call (head `1838468d`). The driver gets the other objects in order and its HRESULT is returned unchanged. A call with only stand-ins returns S_OK without a driver call. Tests: - synthetic tests cover mixed, stand-in only, supported only, empty and null arrays, and an `E_OUTOFMEMORY` pass-through; - a real-device debug-layer test on an RX 7800 XT runs a mixed array of heap, committed buffer, descriptor heap and query heap plus a stand-in. Evict and MakeResident return S_OK with 0 debug messages. The full suite has 1426 passed, 1 failed and 46 ignored. The failure is the existing seed-722 fuzz test (#2115), which also fails on `main`. The paired `scripts/smoke.ps1` run is still pending, so the PR stays a draft until the `xcl-smoke` blocks are added. AI-assisted: code and reply by Claude Code (Claude Sonnet 5.5); coordinated by Codex (gpt-6.2-sol) and Claude Code (Claude Opus 5.5).
oni-swr commented 2026-11-26 14:03:06 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by oni-swr on 2026-11-26T13:36:09Z.


Added the smoke pair under Regression run: main at the merge base (6d12f58a) and this head (1838468d), same title, 60 s each, RX 7800 XT. Head: 1449 frames vs 1342, peak commit 15667 MB vs 15153 MB, no device removals or crashes. Still a draft: the whole suite has not been run on a GPU yet (see Not tested). Run with Claude Code (Claude Sonnet 5.5); blocks pasted unedited from scripts/smoke.ps1.

<!-- greyfinch-sync:ivall/xcl:comment:7193577909 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2523#issuecomment-7193577909). Originally posted by [oni-swr](https://github.com/oni-swr) on 2026-11-26T13:36:09Z. --- Added the smoke pair under **Regression run**: `main` at the merge base (`6d12f58a`) and this head (`1838468d`), same title, 60 s each, RX 7800 XT. Head: 1449 frames vs 1342, peak commit 15667 MB vs 15153 MB, no device removals or crashes. Still a draft: the whole suite has not been run on a GPU yet (see **Not tested**). Run with Claude Code (Claude Sonnet 5.5); blocks pasted unedited from `scripts/smoke.ps1`.
oni-swr commented 2026-11-28 03:58:52 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by oni-swr on 2026-11-28T03:58:52Z.


Rebased onto xcl-dev/xcl main (e429936c), head is now 11c2abfe.

  • Conflict resolution: preserved crate::stall::span(StallKind::Residency) in dev_make_resident / dev_evict, kept dev_set_residency_priority and dev_enqueue_make_resident, deduplicated the overrides(Kind::Device) entries, and kept both test modules at the end of real.rs.
  • Targeted WARP / CPU test (XCL_WARP=1 XCL_ADAPTER=warp cargo test -p xcl --lib -j 4 residency_tests -- --skip gpu_residency_calls_with_a_stand_in_on_a_debug_device): 3 passed, 0 failed, 0 ignored (the 1 GPU debug-device test was skipped to stay CPU/WARP-only).

AI use: Antigravity (Gemini 4 Neon) completed the rebase and ran the targeted CPU/WARP unit tests.

<!-- greyfinch-sync:ivall/xcl:comment:7233568338 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2523#issuecomment-7233568338). Originally posted by [oni-swr](https://github.com/oni-swr) on 2026-11-28T03:58:52Z. --- Rebased onto `xcl-dev/xcl` `main` (`e429936c`), head is now `11c2abfe`. - Conflict resolution: preserved `crate::stall::span(StallKind::Residency)` in `dev_make_resident` / `dev_evict`, kept `dev_set_residency_priority` and `dev_enqueue_make_resident`, deduplicated the `overrides(Kind::Device)` entries, and kept both test modules at the end of `real.rs`. - Targeted WARP / CPU test (`XCL_WARP=1 XCL_ADAPTER=warp cargo test -p xcl --lib -j 4 residency_tests -- --skip gpu_residency_calls_with_a_stand_in_on_a_debug_device`): 3 passed, 0 failed, 0 ignored (the 1 GPU debug-device test was skipped to stay CPU/WARP-only). AI use: Antigravity (Gemini 4 Neon) completed the rebase and ran the targeted CPU/WARP unit tests.
andrewDoing commented 2026-11-28 04:11:18 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by andrewDoing on 2026-11-28T04:11:18Z.


I ran the previously skipped native residency fixture on rebased head 11c2abf on NVIDIA GeForce RTX 5070 with the D3D12 debug layer enabled. All four focused residency tests passed without skips.

The native fixture selected the RTX 5070 and called the production Evict and MakeResident wrappers with mixed, stand-in-only, supported-only, and empty object lists. All eight calls returned S_OK, surviving objects were forwarded to the real device, and the debug layer recorded zero messages.

The native coverage here is limited to those two methods. The other focused tests cover filtering logic; this was not a retail workload or a performance measurement.

AI use: OpenAI Codex with GPT-6.2 Astra ran the checks; Codex reviewed and prepared this report.

<!-- greyfinch-sync:ivall/xcl:comment:7233784179 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2523#issuecomment-7233784179). Originally posted by [andrewDoing](https://github.com/andrewDoing) on 2026-11-28T04:11:18Z. --- I ran the previously skipped native residency fixture on rebased head `11c2abf` on NVIDIA GeForce RTX 5070 with the D3D12 debug layer enabled. All four focused residency tests passed without skips. The native fixture selected the RTX 5070 and called the production `Evict` and `MakeResident` wrappers with mixed, stand-in-only, supported-only, and empty object lists. All eight calls returned `S_OK`, surviving objects were forwarded to the real device, and the debug layer recorded zero messages. The native coverage here is limited to those two methods. The other focused tests cover filtering logic; this was not a retail workload or a performance measurement. AI use: OpenAI Codex with GPT-6.2 Astra ran the checks; Codex reviewed and prepared this report.
Foniass commented 2026-12-01 08:16:10 +00:00 (Migrated from github.com)

Imported from ivall/xcl. Originally posted by Foniass on 2026-12-01T08:16:10Z.


Triage (#1607) – head 11c2abf

No open or merged PR overrides MakeResident / Evict for stand-ins. Main's dev_make_resident and dev_evict still forward the title's array unchanged. #2853 (StorePipeline) and #2861 (PC CreateCommandList) handle other entry points of #2455 and do not overlap.
The description is out of date. It says each shell reaches the driver as the pipeline behind it, through driver_object / with_driver_objects and a pso_async.rs change. The commit instead drops shells from the array (without_stand_ins, standin::is_shell) and does not touch pso_async.rs.
The diff also rewrites DXGI_SAMPLE_DESC to its full path in five unrelated tests in real.rs. Say why, or drop that change.
Recommendation: keep open.

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:7305094369 --> Imported from [ivall/xcl](https://github.com/xcl-dev/xcl/pull/2523#issuecomment-7305094369). Originally posted by [Foniass](https://github.com/Foniass) on 2026-12-01T08:16:10Z. --- **Triage (#1607)** – head 11c2abf No open or merged PR overrides `MakeResident` / `Evict` for stand-ins. Main's `dev_make_resident` and `dev_evict` still forward the title's array unchanged. #2853 (StorePipeline) and #2861 (PC CreateCommandList) handle other entry points of #2455 and do not overlap. The description is out of date. It says each shell reaches the driver as the pipeline behind it, through `driver_object` / `with_driver_objects` and a `pso_async.rs` change. The commit instead drops shells from the array (`without_stand_ins`, `standin::is_shell`) and does not touch `pso_async.rs`. The diff also rewrites `DXGI_SAMPLE_DESC` to its full path in five unrelated tests in `real.rs`. Say why, or drop that change. Recommendation: keep open. AI review: Claude Code (Claude Opus 5.5), diffs read only, not built or run; not checked by a human.
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/2523:upstream-pr/2523'
git switch 'upstream-pr/2523'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/2523'
git switch 'upstream-pr/2523'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/2523'
git switch 'upstream-pr/2523'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/2523'
git switch 'main'
git merge --squash 'upstream-pr/2523'
git switch 'main'
git merge --ff-only 'upstream-pr/2523'
git switch 'main'
git merge 'upstream-pr/2523'
git push origin 'main'
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!2513
No description provided.