D3D12.X: a pipeline the driver gave up on is not built again #1665

Open
github-bot wants to merge 1 commit from github-bot/gh-1665 into main AGit
Owner

@⁠zorde23 on GitHub · 2026-11-24 18:57 UTC · original
zorde23:preload-skip → main · +202 −13 · 2 files · 1 commits · open

Part of #1035. No longer stacked: #1918 (in main) logs the driver's refusal of a huge compute program, which is what #1300 did.

The pipeline preload (#690) builds every pipeline an earlier run used. On an AMD RX 6750 XT two compute programs of a retail
title (~14 MB and ~23 MB of translated DXIL) each kept the driver busy 45-55 s, took the commit to the limit and were
refused with E_OUTOFMEMORY, in every run, because a failed build leaves nothing behind and the key stays in
used-pipelines.txt (#1918 logs the refusal). #1398 (retry without DXC GVN) and the switch-form retry of #680 do not
change that here (numbers below); another RX 6750 XT on #1398 also reports the ~14 MB one still refused.

#1524 (in main now) changes when these builds run, not whether they fail: big programs go to the driver a few at a time
(XCL_HUGE_PSO_CONCURRENCY, default 1, and ≥ 4 MiB in a lane of its own), which this preload already did one at a time.
Each of the two programs alone still takes the driver to its limit here. #1996 caps the builds a title waits for and
gives them a slot without waiting for commit; #2178 drops queued builds the title already released. Neither keeps a
refused build from coming back next run. The turn this PR checks is a slot driver_compile_identified took through the
commit check (since #1996, a slot taken for a waiting title thread is not one).

When the driver returns E_OUTOFMEMORY after working 1 s or more on a build ahead that had its big-compile turn (commit
free, no title thread waiting for it), the shader set gets a !<key> line in used-pipelines.txt. Pipelines of such a
set get their stand-in at once (what they got before, when the build failed) instead of being built again, ahead or at a
bind. Other failures, an out-of-memory next to a title thread that waits for the pipeline (when the build started or by
the time it failed), and an attempt followed by a retry that fails for another reason are tried again next run. Older builds pass over the new lines.

What is in it

  • crates/xcl/src/hle/d3d12x/real.rs: driver_compile_identified also returns whether the compile had its turn (its
    slot came through big_compile_turn's commit check; the other callers ignore it); each attempt of
    translated_compute_pso_once (the cached-blob one, its cold retry, the switch-form retry) sets
    pso_async::note_driver_gave_up(driver_gave_up(hr, turn, time in the driver)): E_OUTOFMEMORY, the turn, ≥ 1 s.
  • crates/xcl/src/hle/d3d12x/pso_async.rs: used::skipped / skip / is_skipped (!<key> lines, one write_all per
    line); build(.., preload = true) marks the set when the driver gave up; the preload worker drops queued pipelines of a
    marked set; submit_as completes a marked set's pipeline as failed at once. Tests: a_skipped_key_is_read_from_the_file,
    a_pipeline_the_driver_gave_up_on_is_not_built_again (fails on main: the second pipeline is not done at once),
    a_build_ahead_that_fails_otherwise_is_tried_again (also: gave up, then a retry that fails otherwise; gave up while
    a title thread waited),
    only_a_long_out_of_memory_in_its_turn_is_giving_up (real.rs).

Tested

  • AMD Radeon RX 6750 XT, driver 32.0.21045.29003; AMD Ryzen 7 5700X, 32 GB (commit limit ~46 GB, page file auto);
    Windows 11 Pro 26200; Rust 1.100 MSVC; release.
  • cargo test --workspace --no-fail-fast -- --test-threads=4 (debug build first): at this PR on 06c9f55 1268 passed,
    1 failed, 46 ignored; at main 06c9f55 1264 / 1 / 46. The same test fails on both here and this change does not
    touch it: gpu::dxil::fuzz_tests::fuzz_validate_and_gpu_1.
    SKIPPED on both: f16_programs_on_the_gpu / f32_programs_on_the_gpu (some forms refused),
    pso_measurement_compiles_an_exact_synthetic_record (no Developer Mode), test_title_draws_with_a_root_signature_under_the_debug_layer
    and uploads_start_from_each_subresources_state (no debug layer), heap_window_out_of_memory_falls_back_to_the_switch_form.
  • Retail title, preload on, no input, XCL_NETWORK=0, release, a watchdog that ends the run at 90 % of the system commit
    limit (peaks below are system commit). #1321 applied to all four (without it main's commit grows from b8b1f49):
    • main + #1321: 90 s, no refusal, peak 35.8 GB; 240 s: ended by the watchdog at ~140 s (42.9 GB).
    • this PR + #1321, with the two ! lines: 240 s, peak 34.3 GB.
    • main + #1321 + #1398: ended by the watchdog at ~49 s (42.9 GB).
    • this PR + #1321 + #1398: 240 s, peak 36.0 GB; with only the ~14 MB set's line, ended at ~33 s (43.9 GB).
  • The two ! lines were written by runs of this change on main 47efa2e (preload on, 90 s): peak 53.0 → 53.1 → 19.6 →
    20.7 GB over four runs, one set marked in each of the first two (the ~23 MB one only shows once the first is skipped).
  • @⁠papasmurph0 ran the smoke pair on NVIDIA (RTX 4080 SUPER, 64 GB, 60 s, main 85e3826 vs 599c69c, comment above):
    99.7 % of main's frames, 123 % of its peak commit, no crash or device removal. A 60 s run there does not reach the world
    load, where this change applies; on NVIDIA nothing is refused, so nothing is marked. Thanks!

Regression run

Both on main 06c9f55 and this PR rebased onto it, release, scripts/smoke.ps1 -Seconds 60 -Title retail-a, preload on,
a watchdog at 90 % of the system commit limit (not reached). The PR's run starts with the two ! lines already in
used-pipelines.txt (its log: 2 shader sets not built again); main passes over them and builds those two sets ahead
(no refusal within 60 s). System commit peak: main 33.7 GB, PR 34.2 GB.

main:

xcl-smoke v1
commit: 06c9f5505f63f10c5ec49ef932d75b2c28177324
gpu: AMD Radeon RX 6750 XT
title: retail-a
seconds: 60
exit: 0x0
frames shown: 1566 (PresentX 1566)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 16533 MB

PR:

xcl-smoke v1
commit: cd46e3fc2bd9d298143d20dc5c49b209027621d0
gpu: AMD Radeon RX 6750 XT
title: retail-a
seconds: 60
exit: 0x0
frames shown: 1526 (PresentX 1527)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 17789 MB

Not tested

  • Other GPUs/drivers. A newer AMD driver (RDNA4, 32.0.31044.16, comment on #1035) does not grow; there nothing is marked.
  • Linux/Wine (dxil-spirv/RADV in #1035): builds that never return are never marked. Nor is growth inside DXC (the other
    reports in #1035: NVIDIA on Windows and Linux, RADV): only a driver's E_OUTOFMEMORY answer marks a set.
  • The mark is written only when the driver answers. On a machine whose commit runs out first (here the watchdog ended
    main's runs before any refusal), the first runs still pay the full cost and may end the title; it converges one set per
    run that survives. The main run above does not write marks (it has no such code): the lines came from runs of this change on 47efa2e.
  • XCL never removes a ! line (driver update, more memory, a recompiler change that shrinks the DXIL, XCL_HEAP_WINDOWS):
    the user deletes it to retry; the log line says so. The mark also applies with XCL_PSO_PRELOAD=0.
  • The E_OUTOFMEMORY / slot / 1 s rule is unit-tested (driver_gave_up); the driver answering it was only seen in the
    runs above.
  • The slot means 3 GB of commit were free when the build started. The title loading, another process, or a second huge
    compile beside it (#1524's ≥ 4 MiB lane runs next to the other one by default; #1996 lets builds a title waits for skip
    the commit check) can use up the commit during a 30-60 s
    build; the driver then answers E_OUTOFMEMORY too and the set is marked, for good, though it might build on another run.
    Marking only after two such runs would avoid that, at the price of one more run at the limit; not done here.
  • Graphics pipelines and first-use (non-preload) builds are not marked. A skipped pipeline counts as a failed background
    build in the stats.
  • Not merged with #889 (all compute through the preload: then any compute built ahead in its turn could be marked),
    #1113 (textual overlap in used::get and the file format) or #1398 (merges cleanly; its retry resets the timer, so the
    1 s is measured on the last attempt).

AI use

  • Claude Code (Claude Opus 5.5) investigated, wrote the code, tests and this text from runs on my machine; Claude Fable 5.2
    reviewed the design and the rebased diff and tried to break it (its findings changed the marking rule). I reviewed and
    ran everything.

Written with Claude Code from runs on this machine.

🤖 Generated with Claude Code

**@⁠zorde23** on GitHub · 2026-11-24 18:57 UTC · [original](https://github.com/xcl-dev/xcl/pull/1665) `zorde23:preload-skip` → `main` · +202 −13 · 2 files · 1 commits · open Part of #1035. No longer stacked: #1918 (in `main`) logs the driver's refusal of a huge compute program, which is what #1300 did. The pipeline preload (#690) builds every pipeline an earlier run used. On an AMD RX 6750 XT two compute programs of a retail title (~14 MB and ~23 MB of translated DXIL) each kept the driver busy 45-55 s, took the commit to the limit and were refused with E_OUTOFMEMORY, in every run, because a failed build leaves nothing behind and the key stays in `used-pipelines.txt` (#1918 logs the refusal). #1398 (retry without DXC GVN) and the switch-form retry of #680 do not change that here (numbers below); another RX 6750 XT on #1398 also reports the ~14 MB one still refused. #1524 (in `main` now) changes when these builds run, not whether they fail: big programs go to the driver a few at a time (`XCL_HUGE_PSO_CONCURRENCY`, default 1, and ≥ 4 MiB in a lane of its own), which this preload already did one at a time. Each of the two programs alone still takes the driver to its limit here. #1996 caps the builds a title waits for and gives them a slot without waiting for commit; #2178 drops queued builds the title already released. Neither keeps a refused build from coming back next run. The turn this PR checks is a slot `driver_compile_identified` took through the commit check (since #1996, a slot taken for a waiting title thread is not one). When the driver returns E_OUTOFMEMORY after working 1 s or more on a build ahead that had its big-compile turn (commit free, no title thread waiting for it), the shader set gets a `!<key>` line in `used-pipelines.txt`. Pipelines of such a set get their stand-in at once (what they got before, when the build failed) instead of being built again, ahead or at a bind. Other failures, an out-of-memory next to a title thread that waits for the pipeline (when the build started or by the time it failed), and an attempt followed by a retry that fails for another reason are tried again next run. Older builds pass over the new lines. **What is in it** - `crates/xcl/src/hle/d3d12x/real.rs`: `driver_compile_identified` also returns whether the compile had its turn (its slot came through `big_compile_turn`'s commit check; the other callers ignore it); each attempt of `translated_compute_pso_once` (the cached-blob one, its cold retry, the switch-form retry) sets `pso_async::note_driver_gave_up(driver_gave_up(hr, turn, time in the driver))`: E_OUTOFMEMORY, the turn, ≥ 1 s. - `crates/xcl/src/hle/d3d12x/pso_async.rs`: `used::skipped` / `skip` / `is_skipped` (`!<key>` lines, one `write_all` per line); `build(.., preload = true)` marks the set when the driver gave up; the preload worker drops queued pipelines of a marked set; `submit_as` completes a marked set's pipeline as failed at once. Tests: `a_skipped_key_is_read_from_the_file`, `a_pipeline_the_driver_gave_up_on_is_not_built_again` (fails on main: the second pipeline is not done at once), `a_build_ahead_that_fails_otherwise_is_tried_again` (also: gave up, then a retry that fails otherwise; gave up while a title thread waited), `only_a_long_out_of_memory_in_its_turn_is_giving_up` (real.rs). **Tested** - AMD Radeon RX 6750 XT, driver 32.0.21045.29003; AMD Ryzen 7 5700X, 32 GB (commit limit ~46 GB, page file auto); Windows 11 Pro 26200; Rust 1.100 MSVC; release. - `cargo test --workspace --no-fail-fast -- --test-threads=4` (debug build first): at this PR on 06c9f55 1268 passed, 1 failed, 46 ignored; at main 06c9f55 1264 / 1 / 46. The same test fails on both here and this change does not touch it: `gpu::dxil::fuzz_tests::fuzz_validate_and_gpu_1`. SKIPPED on both: `f16_programs_on_the_gpu` / `f32_programs_on_the_gpu` (some forms refused), `pso_measurement_compiles_an_exact_synthetic_record` (no Developer Mode), `test_title_draws_with_a_root_signature_under_the_debug_layer` and `uploads_start_from_each_subresources_state` (no debug layer), `heap_window_out_of_memory_falls_back_to_the_switch_form`. - Retail title, preload on, no input, `XCL_NETWORK=0`, release, a watchdog that ends the run at 90 % of the system commit limit (peaks below are system commit). #1321 applied to all four (without it main's commit grows from b8b1f49): - main + #1321: 90 s, no refusal, peak 35.8 GB; 240 s: ended by the watchdog at ~140 s (42.9 GB). - this PR + #1321, with the two `!` lines: 240 s, peak 34.3 GB. - main + #1321 + #1398: ended by the watchdog at ~49 s (42.9 GB). - this PR + #1321 + #1398: 240 s, peak 36.0 GB; with only the ~14 MB set's line, ended at ~33 s (43.9 GB). - The two `!` lines were written by runs of this change on main 47efa2e (preload on, 90 s): peak 53.0 → 53.1 → 19.6 → 20.7 GB over four runs, one set marked in each of the first two (the ~23 MB one only shows once the first is skipped). - @⁠papasmurph0 ran the smoke pair on NVIDIA (RTX 4080 SUPER, 64 GB, 60 s, main 85e3826 vs 599c69c, comment above): 99.7 % of main's frames, 123 % of its peak commit, no crash or device removal. A 60 s run there does not reach the world load, where this change applies; on NVIDIA nothing is refused, so nothing is marked. Thanks! **Regression run** Both on `main` 06c9f55 and this PR rebased onto it, release, `scripts/smoke.ps1 -Seconds 60 -Title retail-a`, preload on, a watchdog at 90 % of the system commit limit (not reached). The PR's run starts with the two `!` lines already in `used-pipelines.txt` (its log: 2 shader sets not built again); `main` passes over them and builds those two sets ahead (no refusal within 60 s). System commit peak: main 33.7 GB, PR 34.2 GB. main: ``` xcl-smoke v1 commit: 06c9f5505f63f10c5ec49ef932d75b2c28177324 gpu: AMD Radeon RX 6750 XT title: retail-a seconds: 60 exit: 0x0 frames shown: 1566 (PresentX 1566) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 16533 MB ``` PR: ``` xcl-smoke v1 commit: cd46e3fc2bd9d298143d20dc5c49b209027621d0 gpu: AMD Radeon RX 6750 XT title: retail-a seconds: 60 exit: 0x0 frames shown: 1526 (PresentX 1527) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 17789 MB ``` **Not tested** - Other GPUs/drivers. A newer AMD driver (RDNA4, 32.0.31044.16, comment on #1035) does not grow; there nothing is marked. - Linux/Wine (dxil-spirv/RADV in #1035): builds that never return are never marked. Nor is growth inside DXC (the other reports in #1035: NVIDIA on Windows and Linux, RADV): only a driver's E_OUTOFMEMORY answer marks a set. - The mark is written only when the driver answers. On a machine whose commit runs out first (here the watchdog ended main's runs before any refusal), the first runs still pay the full cost and may end the title; it converges one set per run that survives. The main run above does not write marks (it has no such code): the lines came from runs of this change on 47efa2e. - XCL never removes a `!` line (driver update, more memory, a recompiler change that shrinks the DXIL, `XCL_HEAP_WINDOWS`): the user deletes it to retry; the log line says so. The mark also applies with `XCL_PSO_PRELOAD=0`. - The E_OUTOFMEMORY / slot / 1 s rule is unit-tested (`driver_gave_up`); the driver answering it was only seen in the runs above. - The slot means 3 GB of commit were free when the build started. The title loading, another process, or a second huge compile beside it (#1524's ≥ 4 MiB lane runs next to the other one by default; #1996 lets builds a title waits for skip the commit check) can use up the commit during a 30-60 s build; the driver then answers E_OUTOFMEMORY too and the set is marked, for good, though it might build on another run. Marking only after two such runs would avoid that, at the price of one more run at the limit; not done here. - Graphics pipelines and first-use (non-preload) builds are not marked. A skipped pipeline counts as a failed background build in the stats. - Not merged with #889 (all compute through the preload: then any compute built ahead in its turn could be marked), #1113 (textual overlap in `used::get` and the file format) or #1398 (merges cleanly; its retry resets the timer, so the 1 s is measured on the last attempt). **AI use** - Claude Code (Claude Opus 5.5) investigated, wrote the code, tests and this text from runs on my machine; Claude Fable 5.2 reviewed the design and the rebased diff and tried to break it (its findings changed the marking rule). I reviewed and ran everything. Written with Claude Code from runs on this machine. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
The preload builds every pipeline an earlier run used (used-pipelines.txt). On an
AMD RX 6750 XT two retail compute programs (14 and 23 MB of DXIL) kept the driver
busy 45-55 s each, took the process to ~53 GB of commit and were refused with
E_OUTOFMEMORY, in every run, since nothing was kept. When the driver runs out of
memory after working for 1 s or more on a build ahead that had its big-compile
turn (commit free, no title thread waiting for it), its key now gets a !<key>
line; such pipelines get the stand-in at once (as when the build failed) instead
of being built again, ahead or at a bind. Other failures, and an out-of-memory
next to a title that waits for the pipeline, are tried again next run; each
attempt (a retry in the switch form too) is judged on its own. Older builds pass
over the new lines.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 05:00:55 +00:00
Author
Owner

@⁠papasmurph0 on GitHub · 2026-11-24 20:08 UTC · original

Regression run for this PR on Windows / NVIDIA, since it has no xcl-smoke pair yet.

Tested

  • NVIDIA GeForce RTX 4080 SUPER (driver 32.0.16.1088), Ryzen 7 7800X3D, 64 GB RAM, Windows 11 build 26200, rustc 1.100.0 MSVC, release; scripts/smoke.ps1 -Seconds 60 on the retail title of #505 (game folder passed as a neutral junction, hence title: t1), each build from a clean worktree of the exact commit.

main:

xcl-smoke v1
commit: 85e38262ff94aecd75d6f83fa8156a8b7697bd13
gpu: NVIDIA GeForce RTX 4080 SUPER
title: t1
seconds: 60
exit: 0x0
frames shown: 1537 (PresentX 1537)
presents per 2 s (last 3): 57 60 60
device removals: 0
crashes: 0
peak commit: 15976 MB

this PR:

xcl-smoke v1
commit: 599c69c58bfd4ebe35ee03c76a345e46dacdb497
gpu: NVIDIA GeForce RTX 4080 SUPER
title: t1
seconds: 60
exit: 0x0
frames shown: 1532 (PresentX 1533)
presents per 2 s (last 3): 59 48 53
device removals: 0
crashes: 0
peak commit: 19686 MB

Both runs started from the same state: the title showed its first-run screens (terms, screen narration) in both, so the pair is like for like. The title saved its settings during this PR's run, so later runs on this machine skip those screens and are not comparable with these two.

The PR's run is within the limits: 99.7 % of main's frames, 123 % of its peak commit, no crash, no device removal.

Not tested: the world load, where the PR's change applies; a 60 s run does not reach it here. On this machine (125 GB commit limit) the title's screen-probe programs reach the in-title driver build in longer runs, so a longer run of this PR is possible if useful.

AI use: Claude Code (Claude Opus 5.5) built the trees, made the runs on my PC and wrote this report; I asked for it to be posted.

**@⁠papasmurph0** on GitHub · 2026-11-24 20:08 UTC · [original](https://github.com/xcl-dev/xcl/pull/1665#issuecomment-7143102210) Regression run for this PR on Windows / NVIDIA, since it has no `xcl-smoke` pair yet. **Tested** - NVIDIA GeForce RTX 4080 SUPER (driver 32.0.16.1088), Ryzen 7 7800X3D, 64 GB RAM, Windows 11 build 26200, rustc 1.100.0 MSVC, release; `scripts/smoke.ps1 -Seconds 60` on the retail title of #505 (game folder passed as a neutral junction, hence `title: t1`), each build from a clean worktree of the exact commit. `main`: ``` xcl-smoke v1 commit: 85e38262ff94aecd75d6f83fa8156a8b7697bd13 gpu: NVIDIA GeForce RTX 4080 SUPER title: t1 seconds: 60 exit: 0x0 frames shown: 1537 (PresentX 1537) presents per 2 s (last 3): 57 60 60 device removals: 0 crashes: 0 peak commit: 15976 MB ``` this PR: ``` xcl-smoke v1 commit: 599c69c58bfd4ebe35ee03c76a345e46dacdb497 gpu: NVIDIA GeForce RTX 4080 SUPER title: t1 seconds: 60 exit: 0x0 frames shown: 1532 (PresentX 1533) presents per 2 s (last 3): 59 48 53 device removals: 0 crashes: 0 peak commit: 19686 MB ``` Both runs started from the same state: the title showed its first-run screens (terms, screen narration) in both, so the pair is like for like. The title saved its settings during this PR's run, so later runs on this machine skip those screens and are not comparable with these two. The PR's run is within the limits: 99.7 % of `main`'s frames, 123 % of its peak commit, no crash, no device removal. **Not tested:** the world load, where the PR's change applies; a 60 s run does not reach it here. On this machine (125 GB commit limit) the title's screen-probe programs reach the in-title driver build in longer runs, so a longer run of this PR is possible if useful. AI use: Claude Code (Claude Opus 5.5) built the trees, made the runs on my PC and wrote this report; I asked for it to be posted.
Author
Owner

@⁠DavidM1911 on GitHub · 2026-11-24 21:26 UTC · original

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

  • cargo test -p xcl --lib: all passed, 0 failed, ~22 ignored.

Thanks!

**@⁠DavidM1911** on GitHub · 2026-11-24 21:26 UTC · [original](https://github.com/xcl-dev/xcl/pull/1665#issuecomment-7144934587) Verification on RTX 3060 Ti (Windows 11), branch merged with current `main`: - `cargo test -p xcl --lib`: all passed, 0 failed, ~22 ignored. Thanks!
Author
Owner

@⁠JJAutoCompare on GitHub · 2026-11-25 04:44 UTC · original

XCL PR #1665 verification

Head daf72219421f6815e2faa88c089ccd119327c72a (clean detached checkout). The PR changes crates/xcl/src/hle/d3d12x/{pso_async,real}.rs.

STOR-WINLAB, Windows 11 Enterprise Evaluation x64 build 26200.9974, AMD Family 23 Model 113 (12 logical CPUs), Intel Arc A770 (16 GiB), driver 32.0.101.9175, DXC 1.9.2609.5, rustc 1.100.0 (0ef1bc386, x86_64-pc-windows-msvc). Unoptimized dev/test profiles, debug info and incremental compilation disabled.

Tested

  • cargo build --workspace and cargo test --workspace --no-run succeeded outside the Arc mutex.
  • With XCL_ADAPTER=NONE_CPU_ONLY, cargo test -p xcl --lib pso_async::used_tests -- --test-threads=1 had 9 passed, 0 failed, 0 ignored, 0 skipped. New tests checked parsing !<key> markers, returning the stand-in at the next bind without executing the replacement build after a simulated driver failure, and retrying when the final attempt failed for another reason.
  • With the same adapter setting, cargo test -p xcl --lib only_a_long_out_of_memory_in_its_turn_is_giving_up -- --test-threads=1 had 1 passed, 0 failed, 0 ignored, 0 skipped. It checked that only E_OUTOFMEMORY after at least one second with a compile slot qualifies.
  • Under Invoke-ArcTest.ps1 with XCL_ADAPTER=A770 and RUST_TEST_NOCAPTURE=1, cargo test --workspace --no-fail-fast -- --test-threads=4 exited 101. All four new unit tests passed again. Summing pr1665-suite.log gave 944 harness passes, 19 failures, and 43 ignored across 20 results (19 executables and one doctest target).

Workspace failures and skips

  • The library target had 14 CreateComputePipelineState failures (0x80070057) and four result mismatches. The e2e target failed the test title's dynamic depth-bias pixel check (blue where green was expected).
  • 25 exact SKIPPED lines provide no coverage. Reasons include missing wave64 (17), per-lane lowering refusal (3), missing debug layer (2), and one each for tiled tier below 2, unavailable cache control, and unavailable heap windows.

Not tested

Matched main run, retail-title smoke, real driver OOM, on-disk skip-marker write and reuse across processes, or other adapters.

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 pr1665-suite.log and published.

**@⁠JJAutoCompare** on GitHub · 2026-11-25 04:44 UTC · [original](https://github.com/xcl-dev/xcl/pull/1665#issuecomment-7153122785) # XCL PR #1665 verification Head `daf72219421f6815e2faa88c089ccd119327c72a` (clean detached checkout). The PR changes `crates/xcl/src/hle/d3d12x/{pso_async,real}.rs`. STOR-WINLAB, Windows 11 Enterprise Evaluation x64 build 26200.9974, AMD Family 23 Model 113 (12 logical CPUs), Intel Arc A770 (16 GiB), driver 32.0.101.9175, DXC 1.9.2609.5, rustc 1.100.0 (`0ef1bc386`, x86_64-pc-windows-msvc). Unoptimized dev/test profiles, debug info and incremental compilation disabled. **Tested** - `cargo build --workspace` and `cargo test --workspace --no-run` succeeded outside the Arc mutex. - With `XCL_ADAPTER=NONE_CPU_ONLY`, `cargo test -p xcl --lib pso_async::used_tests -- --test-threads=1` had 9 passed, 0 failed, 0 ignored, 0 skipped. New tests checked parsing `!<key>` markers, returning the stand-in at the next bind without executing the replacement build after a simulated driver failure, and retrying when the final attempt failed for another reason. - With the same adapter setting, `cargo test -p xcl --lib only_a_long_out_of_memory_in_its_turn_is_giving_up -- --test-threads=1` had 1 passed, 0 failed, 0 ignored, 0 skipped. It checked that only `E_OUTOFMEMORY` after at least one second with a compile slot qualifies. - Under `Invoke-ArcTest.ps1` with `XCL_ADAPTER=A770` and `RUST_TEST_NOCAPTURE=1`, `cargo test --workspace --no-fail-fast -- --test-threads=4` exited 101. All four new unit tests passed again. Summing `pr1665-suite.log` gave 944 harness passes, 19 failures, and 43 ignored across 20 results (19 executables and one doctest target). **Workspace failures and skips** - The library target had 14 `CreateComputePipelineState` failures (`0x80070057`) and four result mismatches. The `e2e` target failed the test title's dynamic depth-bias pixel check (blue where green was expected). - 25 exact `SKIPPED ` lines provide no coverage. Reasons include missing wave64 (17), per-lane lowering refusal (3), missing debug layer (2), and one each for tiled tier below 2, unavailable cache control, and unavailable heap windows. **Not tested** Matched `main` run, retail-title smoke, real driver OOM, on-disk skip-marker write and reuse across processes, or other adapters. **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 `pr1665-suite.log` and published.
Author
Owner

@⁠Chrysana on GitHub · 2026-11-25 20:13 UTC · original

RDNA4 run of cd46e3f, for "Other GPUs/drivers" under Not tested (your note says RDNA4 on driver 32.0.31044.16 doesn't grow; on 32.0.32015.2008 it does). On an RX 9070 XT the change works as described: the driver's refusals of builds ahead in their turn get a ! line, and the next run doesn't build those sets again. But the largest program here, 95cc13288a27a96e (ActivateRays, 2.4 MB DXIL), is never marked: it is refused and built again in every run. That one is where most of the memory goes on this card (#1598).

Setup: AMD Radeon RX 9070 XT 16 GB (RDNA4), driver 32.0.32015.2008; Ryzen 7 9800X3D, 31 GB RAM (commit ceiling 79 GB with the page files at their maximum); Windows 11 26200.9974; rustc 1.100.0 MSVC, release. Retail title 1.0.2.1, preload on (1181 shader sets in used-pipelines.txt, no ! lines at the start), XCL_NETWORK=0 XCL_ACTIVITY=1, A pressed every 4 s from 12 to 120 s, 200 s runs, cd46e3f as pushed (its base is 06c9f55).

How I got the refusals without running the whole PC out of commit: (a first try at a 37 GB limit was stopped by my own system-memory guard at ~142 s, before any refusal.) on main here, ActivateRays alone grows the process by ~16 GB and is refused only when the system nears its limit, at ~44 GB of process commit after 69 s in the driver (numbers in #1598). That took other programs down with it once, so I ran the title in a Windows job object with a 33 GB commit limit for all its processes (JOB_OBJECT_LIMIT_JOB_MEMORY). The driver's allocations fail inside the title, it returns 0x8007000e as at the system limit, and the rest of the machine keeps its headroom. The catch: the refusals come sooner (after 4–13 s in the driver), and some programs that would build with more headroom get refused here.

Run 1 under the cap, no ! lines at the start: six compute programs refused with 0x8007000e, two of them marked:

record DXIL its compile refused at ! line
67e870153afb3a94 413,472 B ungated here 119.0 s, 12.2 s in the driver no
95cc13288a27a96e (ActivateRays) 2,420,640 B ungated here 119.2 s, 12.5 s no
68d630a8567ab575 333,764 B ungated here 131.2 s, 5.8 s no
517e7bab67ece93f 1,021,324 B gated (waited 114983 ms) 131.8 s, 12.8 s !6c3726c018616a2f
b6dd852172e5f719 1,011,788 B gated (waited 5288 ms) 181.1 s, 4.3 s !7edd0762558da1f5
33743bd6d1e45443 1,040,856 B ungated here 199.7 s, 3.9 s no

The two marks match the two gated builds (same thread and time as their the driver gave up on a pipeline built ahead (shaders …): not built again lines). The four ungated here ones are what your description leaves to be tried again.

Run 2, same cap, with those two lines:

  • At start: 2 shader sets the driver gave up on in an earlier run are not built again (stand-ins; …).
  • Neither 517e7bab67ece93f nor b6dd852172e5f719 is compiled (no driver compile start for either).
  • ActivateRays is compiled again from 105.1 s and refused again after 11.1 s. This time its compile is logged gated (waited 101125 ms), so it had its turn, and it is still not marked.
  • Six more builds ahead were refused under the cap and marked (8 ! lines at the end). These are artefacts of the 33 GB limit: with more headroom some of them would build.

Both runs ran the full 200 s, exit 0, no device removal. First #101 at 105.2 / 103.7 s; presents stop 2–3 s after it in both (the four-queue wait of #1993, the same as main).

What this means on RDNA4, as far as I can tell:

  • The mark works, and skipping the two sets in run 2 is visible.
  • ActivateRays is the build that takes this machine to its limit, and it falls in the cases you retry on purpose. On main without the cap (69 s in the driver) and in run 1 here, its compile is ungated here (a title thread's). In run 2 it is gated, but its compile starts 1.4 s after the first #101, as the world load binds it. Going by build(), a gated refusal isn't marked when the build isn't the preload's own or a title thread came to wait for it, and I'd guess the latter, though the log doesn't say which. So under this PR it comes back each run, as on main. Whether a refusal the title waited for should be remembered too is your call.
  • A ! line stays until someone deletes it. On a machine that is short of commit for a moment (other programs open, as here under the cap), a build ahead that would succeed later is skipped in every run after. The log line says how to retry; it may be worth logging the free commit when the mark is written, so it's possible to tell a real "never fits" from a busy moment.

Not tested

  • These refusals at the real system limit with this PR (only under the 33 GB job limit; main reached it without the cap in #1598's runs).
  • The PR's suite, the smoke pair (papasmurph0's covers that), XCL_PSO_PRELOAD=0, the RDNA2 iGPU.
  • The marked sets' stand-ins on screen: presents stop at the world load here either way.

AI use

  • Claude Code (Claude Opus 5.5) built the PR, wrote the job-limited run script, ran the title, read the logs and drafted this comment. I checked it before posting.
**@⁠Chrysana** on GitHub · 2026-11-25 20:13 UTC · [original](https://github.com/xcl-dev/xcl/pull/1665#issuecomment-7173359971) RDNA4 run of `cd46e3f`, for "Other GPUs/drivers" under **Not tested** (your note says RDNA4 on driver 32.0.31044.16 doesn't grow; on 32.0.32015.2008 it does). **On an RX 9070 XT the change works as described: the driver's refusals of builds ahead in their turn get a `!` line, and the next run doesn't build those sets again. But the largest program here, `95cc13288a27a96e` (ActivateRays, 2.4 MB DXIL), is never marked: it is refused and built again in every run.** That one is where most of the memory goes on this card (#1598). **Setup:** AMD Radeon RX 9070 XT 16 GB (RDNA4), driver 32.0.32015.2008; Ryzen 7 9800X3D, 31 GB RAM (commit ceiling 79 GB with the page files at their maximum); Windows 11 26200.9974; rustc 1.100.0 MSVC, release. Retail title 1.0.2.1, preload on (1181 shader sets in `used-pipelines.txt`, no `!` lines at the start), `XCL_NETWORK=0 XCL_ACTIVITY=1`, A pressed every 4 s from 12 to 120 s, 200 s runs, `cd46e3f` as pushed (its base is `06c9f55`). **How I got the refusals without running the whole PC out of commit:** (a first try at a 37 GB limit was stopped by my own system-memory guard at ~142 s, before any refusal.) on `main` here, ActivateRays alone grows the process by ~16 GB and is refused only when the system nears its limit, at ~44 GB of process commit after 69 s in the driver (numbers in #1598). That took other programs down with it once, so I ran the title in a Windows job object with a 33 GB commit limit for all its processes (`JOB_OBJECT_LIMIT_JOB_MEMORY`). The driver's allocations fail inside the title, it returns `0x8007000e` as at the system limit, and the rest of the machine keeps its headroom. The catch: the refusals come sooner (after 4–13 s in the driver), and some programs that would build with more headroom get refused here. **Run 1 under the cap, no `!` lines at the start:** six compute programs refused with `0x8007000e`, two of them marked: | record | DXIL | its compile | refused at | `!` line | |---|---|---|---|---| | `67e870153afb3a94` | 413,472 B | `ungated here` | 119.0 s, 12.2 s in the driver | no | | `95cc13288a27a96e` (ActivateRays) | 2,420,640 B | `ungated here` | 119.2 s, 12.5 s | no | | `68d630a8567ab575` | 333,764 B | `ungated here` | 131.2 s, 5.8 s | no | | `517e7bab67ece93f` | 1,021,324 B | `gated (waited 114983 ms)` | 131.8 s, 12.8 s | **`!6c3726c018616a2f`** | | `b6dd852172e5f719` | 1,011,788 B | `gated (waited 5288 ms)` | 181.1 s, 4.3 s | **`!7edd0762558da1f5`** | | `33743bd6d1e45443` | 1,040,856 B | `ungated here` | 199.7 s, 3.9 s | no | The two marks match the two gated builds (same thread and time as their `the driver gave up on a pipeline built ahead (shaders …): not built again` lines). The four `ungated here` ones are what your description leaves to be tried again. **Run 2, same cap, with those two lines:** - At start: `2 shader sets the driver gave up on in an earlier run are not built again (stand-ins; …)`. - Neither `517e7bab67ece93f` nor `b6dd852172e5f719` is compiled (no `driver compile start` for either). - ActivateRays is compiled again from 105.1 s and refused again after 11.1 s. This time its compile is logged `gated (waited 101125 ms)`, so it had its turn, and it is still not marked. - Six more builds ahead were refused under the cap and marked (8 `!` lines at the end). These are artefacts of the 33 GB limit: with more headroom some of them would build. Both runs ran the full 200 s, exit 0, no device removal. First `#101` at 105.2 / 103.7 s; presents stop 2–3 s after it in both (the four-queue wait of #1993, the same as `main`). **What this means on RDNA4, as far as I can tell:** - The mark works, and skipping the two sets in run 2 is visible. - ActivateRays is the build that takes this machine to its limit, and it falls in the cases you retry on purpose. On `main` without the cap (69 s in the driver) and in run 1 here, its compile is `ungated here` (a title thread's). In run 2 it is gated, but its compile starts 1.4 s after the first `#101`, as the world load binds it. Going by `build()`, a gated refusal isn't marked when the build isn't the preload's own or a title thread came to wait for it, and I'd guess the latter, though the log doesn't say which. So under this PR it comes back each run, as on `main`. Whether a refusal the title waited for should be remembered too is your call. - A `!` line stays until someone deletes it. On a machine that is short of commit for a moment (other programs open, as here under the cap), a build ahead that would succeed later is skipped in every run after. The log line says how to retry; it may be worth logging the free commit when the mark is written, so it's possible to tell a real "never fits" from a busy moment. **Not tested** - These refusals at the real system limit with this PR (only under the 33 GB job limit; `main` reached it without the cap in #1598's runs). - The PR's suite, the smoke pair (papasmurph0's covers that), `XCL_PSO_PRELOAD=0`, the RDNA2 iGPU. - The marked sets' stand-ins on screen: presents stop at the world load here either way. **AI use** - Claude Code (Claude Opus 5.5) built the PR, wrote the job-limited run script, ran the title, read the logs and drafted this comment. I checked it before posting.
Author
Owner

@⁠DavidM1911 on GitHub · 2026-11-26 06:07 UTC · original

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

**@⁠DavidM1911** on GitHub · 2026-11-26 06:07 UTC · [original](https://github.com/xcl-dev/xcl/pull/1665#issuecomment-7184119418) 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
Author
Owner

@⁠bmjask on GitHub · 2026-11-25 21:22 UTC · original · reviewed

No concrete source-level defect found. Marker parsing/preload behavior and retry-state replacement look sound; current Windows CI is green. Residual documented tradeoff: a transient long E_OUTOFMEMORY can suppress a shader set until user deletes its ! line. Consider logging available commit at mark time to support that manual recovery decision. I found no blocker.

**@⁠bmjask** on GitHub · 2026-11-25 21:22 UTC · [original](https://github.com/xcl-dev/xcl/pull/1665#pullrequestreview-6065159278) · **reviewed** No concrete source-level defect found. Marker parsing/preload behavior and retry-state replacement look sound; current Windows CI is green. Residual documented tradeoff: a transient long E_OUTOFMEMORY can suppress a shader set until user deletes its ! line. Consider logging available commit at mark time to support that manual recovery decision. I found no blocker.
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/1665/head:github-bot/gh-1665'
git switch 'github-bot/gh-1665'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-1665'
git switch 'github-bot/gh-1665'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-1665'
git switch 'github-bot/gh-1665'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-1665'
git switch 'main'
git merge --squash 'github-bot/gh-1665'
git switch 'main'
git merge --ff-only 'github-bot/gh-1665'
git switch 'main'
git merge 'github-bot/gh-1665'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.