README: saved driver blobs belong to the DXIL a build makes #2234

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

@⁠Anon64 on GitHub · 2026-11-25 10:55 UTC · original
Anon64:readme/driver-blobs-per-build → main · +4 −0 · 1 files · 1 commits · open

The README says --precompile --pipelines saves driver blobs "for the next run", but not that the next run has to make the same DXIL. Compute blobs are looked up by the exact DXIL bytes and flags (driver_cache::path in hle/d3d12x/real.rs). So a warm-up made with one build, or with XCL_DIRECT_DXIL set differently, is missed, and those pipelines compile on the title's threads again. This adds one bullet saying so, next to the existing note on translated-shader reuse.

Seen on an RTX 3060 12 GB with a retail title. After a warm-up made with a PR branch, a run of main had 4-16 cold compute builds of 6-26 s each, logged as "ungated here (a title thread's…)". After a warm-up made with main it had none. Without XCL_DIRECT_DXIL, a run after the direct-DXIL warm-up had cold builds of about 3-4 s each again.

What is in it

  • README.md: one bullet under "Switches, caches, logs and the files XCL writes".

Tested

  • Docs only, no code changed: no tests run for this PR.

Regression run

  • Not needed: no change to crates/xcl/src.

Not tested

  • Graphics pipeline blobs (graphics_path) are named differently; the bullet is about the --pipelines compute blobs only.

AI use

  • Claude Code (Claude Opus 5.5) found the cause in the runs, checked the cache key in the code and wrote the bullet and this description.

🤖 Generated with Claude Code

**@⁠Anon64** on GitHub · 2026-11-25 10:55 UTC · [original](https://github.com/xcl-dev/xcl/pull/2234) `Anon64:readme/driver-blobs-per-build` → `main` · +4 −0 · 1 files · 1 commits · open The README says `--precompile --pipelines` saves driver blobs "for the next run", but not that the next run has to make the same DXIL. Compute blobs are looked up by the exact DXIL bytes and flags (`driver_cache::path` in `hle/d3d12x/real.rs`). So a warm-up made with one build, or with `XCL_DIRECT_DXIL` set differently, is missed, and those pipelines compile on the title's threads again. This adds one bullet saying so, next to the existing note on translated-shader reuse. Seen on an RTX 3060 12 GB with a retail title. After a warm-up made with a PR branch, a run of `main` had 4-16 cold compute builds of 6-26 s each, logged as "ungated here (a title thread's…)". After a warm-up made with `main` it had none. Without `XCL_DIRECT_DXIL`, a run after the direct-DXIL warm-up had cold builds of about 3-4 s each again. **What is in it** - `README.md`: one bullet under "Switches, caches, logs and the files XCL writes". **Tested** - Docs only, no code changed: no tests run for this PR. **Regression run** - Not needed: no change to `crates/xcl/src`. **Not tested** - Graphics pipeline blobs (`graphics_path`) are named differently; the bullet is about the `--pipelines` compute blobs only. **AI use** - Claude Code (Claude Opus 5.5) found the cause in the runs, checked the cache key in the code and wrote the bullet and this description. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Compute driver blobs are looked up by the exact DXIL and flags
(driver_cache::path), so a warm-up made with one build or switch set
is missed by another and those pipelines compile on the title's
threads again. On an RTX 3060 a warm-up made with one build left
main with 4-16 cold compute builds of 6-26 s each.

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

@⁠raylitebull on GitHub · 2026-11-25 11:00 UTC · original

Reviewed 10f478f (README.md):

  • Adding the --precompile --pipelines driver-blob key note accurately matches driver_cache::path in crates/xcl/src/hle/d3d12x/real.rs (keyed on exact DXIL bytes and flags, so XCL_DIRECT_DXIL or translator changes miss cached compute blobs).
  • Diff audited and CI workflow approved (45599530469).
**@⁠raylitebull** on GitHub · 2026-11-25 11:00 UTC · [original](https://github.com/xcl-dev/xcl/pull/2234#issuecomment-7160465675) Reviewed `10f478f` (`README.md`): - Adding the `--precompile --pipelines` driver-blob key note accurately matches `driver_cache::path` in `crates/xcl/src/hle/d3d12x/real.rs` (keyed on exact DXIL bytes and flags, so `XCL_DIRECT_DXIL` or translator changes miss cached compute blobs). - Diff audited and CI workflow approved (`45599530469`).
Author
Owner

@⁠DavidM1911 on GitHub · 2026-11-25 16:31 UTC · original

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

  • cargo test -p xcl --lib: 2 real failures, deterministic (also fail --test-threads=1):
hle::d3d12x::device_x::tests::pc_resource_desc_strips_uav_on_unsupported_formats_and_msaa
  assertion failed: format 85 kept — left: 28, right: 85 (device_x.rs:1376)
gpu::recomp::pso::shader_cache_tests::rerouted_disk_entries_follow_the_direct_translator
  assertion failed — left: 68, right: 1 (pso.rs:1360)

Needs fixes before merge.

— Devin

**@⁠DavidM1911** on GitHub · 2026-11-25 16:31 UTC · [original](https://github.com/xcl-dev/xcl/pull/2234#issuecomment-7168116546) Verification on RTX 3060 Ti (Windows 11), branch merged with current `main`: - `cargo test -p xcl --lib`: **2 real failures**, deterministic (also fail `--test-threads=1`): ``` hle::d3d12x::device_x::tests::pc_resource_desc_strips_uav_on_unsupported_formats_and_msaa assertion failed: format 85 kept — left: 28, right: 85 (device_x.rs:1376) gpu::recomp::pso::shader_cache_tests::rerouted_disk_entries_follow_the_direct_translator assertion failed — left: 68, right: 1 (pso.rs:1360) ``` Needs fixes before merge. — Devin
Author
Owner

@⁠Anon64 on GitHub · 2026-11-25 17:19 UTC · original

Thanks for running it. This PR changes one bullet in README.md and no code, so it cannot change either test.

I ran both on current main 68a284a (debug test build, RTX 3060 12 GB, Windows 11):

cargo test -p xcl --lib -- pc_resource_desc_strips_uav_on_unsupported_formats_and_msaa rerouted_disk_entries_follow_the_direct_translator
test hle::d3d12x::device_x::tests::pc_resource_desc_strips_uav_on_unsupported_formats_and_msaa ... ok
test gpu::recomp::pso::shader_cache_tests::rerouted_disk_entries_follow_the_direct_translator ... ok
test result: ok. 2 passed; 0 failed; 0 ignored

So the failures you saw come from something else in the tree you tested, perhaps an older main or another branch merged in. If you can name that commit, I'll gladly run the two tests there too.

AI use: Claude Code, Claude Opus 5.5 ran the tests and wrote this reply.

**@⁠Anon64** on GitHub · 2026-11-25 17:19 UTC · [original](https://github.com/xcl-dev/xcl/pull/2234#issuecomment-7169346045) Thanks for running it. This PR changes one bullet in `README.md` and no code, so it cannot change either test. I ran both on current `main` `68a284a` (debug test build, RTX 3060 12 GB, Windows 11): ``` cargo test -p xcl --lib -- pc_resource_desc_strips_uav_on_unsupported_formats_and_msaa rerouted_disk_entries_follow_the_direct_translator test hle::d3d12x::device_x::tests::pc_resource_desc_strips_uav_on_unsupported_formats_and_msaa ... ok test gpu::recomp::pso::shader_cache_tests::rerouted_disk_entries_follow_the_direct_translator ... ok test result: ok. 2 passed; 0 failed; 0 ignored ``` So the failures you saw come from something else in the tree you tested, perhaps an older `main` or another branch merged in. If you can name that commit, I'll gladly run the two tests there too. AI use: Claude Code, Claude Opus 5.5 ran the tests and wrote this reply.
Author
Owner

@⁠DavidM1911 on GitHub · 2026-11-26 00:59 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 00:59 UTC · [original](https://github.com/xcl-dev/xcl/pull/2234#issuecomment-7179315157) 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

@⁠luckyteagirl on GitHub · 2026-11-26 08:51 UTC · original · reviewed

At exact head 70d5f59 on current main b49be18, the new README bullet correctly describes DXIL-based driver-blob lookup, but “compiles those pipelines again at run time, on the title's threads” is too broad. In dev_create_compute_pso, a translated-cache miss can enter go_background, which queues build_compute for an xcl-pso worker; that build also reaches the driver-cache lookup. Other paths can compile inline. This is a source-only review; I did not run a cold-cache title.

Could the sentence say that XCL rebuilds missed pipelines at run time, without assigning every rebuild to a title thread? If useful, mention separately that some builds run on background workers. The advice to precompile with the chosen build and switches remains sound.

AI assistance: two GPT-6.2 Sol agents checked the runtime path; GPT-6.2 Astra verified the exact-head README and wording.

**@⁠luckyteagirl** on GitHub · 2026-11-26 08:51 UTC · [original](https://github.com/xcl-dev/xcl/pull/2234#pullrequestreview-6070992127) · **reviewed** At exact head `70d5f59` on current main `b49be18`, the new README bullet correctly describes DXIL-based driver-blob lookup, but “compiles those pipelines again at run time, on the title's threads” is too broad. In `dev_create_compute_pso`, a translated-cache miss can enter `go_background`, which queues `build_compute` for an `xcl-pso` worker; that build also reaches the driver-cache lookup. Other paths can compile inline. This is a source-only review; I did not run a cold-cache title. Could the sentence say that XCL rebuilds missed pipelines at run time, without assigning every rebuild to a title thread? If useful, mention separately that some builds run on background workers. The advice to precompile with the chosen build and switches remains sound. AI assistance: two GPT-6.2 Sol agents checked the runtime path; GPT-6.2 Astra verified the exact-head README and wording.
github-bot force-pushed github-bot/gh-2234 from 70d5f59b42 to b91f6ee9e6 2026-11-26 21:12:58 +00:00 Compare
Author
Owner

@⁠Anon64 on GitHub · 2026-11-26 21:09 UTC · original

Thanks, you are right: a miss can also go to an xcl-pso worker through go_background. The bullet now says XCL "builds those pipelines again at run time", with no claim about which thread (b91f6ee, rebased onto 8b957be).

AI use: Claude Code (Claude Opus 5.5) made the change and wrote this reply.

**@⁠Anon64** on GitHub · 2026-11-26 21:09 UTC · [original](https://github.com/xcl-dev/xcl/pull/2234#issuecomment-7203451467) Thanks, you are right: a miss can also go to an `xcl-pso` worker through `go_background`. The bullet now says XCL "builds those pipelines again at run time", with no claim about which thread (`b91f6ee`, rebased onto `8b957be`). AI use: Claude Code (Claude Opus 5.5) made the change and wrote this reply.
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/2234/head:github-bot/gh-2234'
git switch 'github-bot/gh-2234'

Merge

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