Skip to content

README: document XCL_LAZY_PSO - #3202

Draft
romeawayfromhome-rgb wants to merge 1 commit into
xcl-dev:mainfrom
romeawayfromhome-rgb:docs/lazy-pso-readme
Draft

romeawayfromhome-rgb wants to merge 1 commit into
xcl-dev:mainfrom
romeawayfromhome-rgb:docs/lazy-pso-readme

Conversation

@romeawayfromhome-rgb

Copy link
Copy Markdown

Documents the existing XCL_LAZY_PSO switch in the README. The switch already exists in crates/xcl/src/hle/d3d12x/pso_async.rs; this change only documents it.

What is in it

  • README.md: one bullet on lazy pipeline creation and XCL_LAZY_PSO=0.

Tested

  • Source check against main 10d2729: lazy() in pso_async.rs is on unless the value is exactly "0" (and background building is enabled), and its comment states that a title's pipelines with console shaders get their stand-in when made and are built when first used; real.rs sends non-lazy pipelines to the workers eagerly. The README had no XCL_LAZY_PSO mention, and a search of open PRs found no README PR documenting it (Docs: ARCHITECTURE.md - module map, generated files, XCL_* variables #601 adds docs/ARCHITECTURE.md only).

Regression run

  • Not required: README.md only, no runtime change.

Not tested

  • Not built or tested locally: this was prepared on Linux, where XCL does not build, so there is no Windows or GPU run. Docs-only change.

AI use

  • Muse (Muse Spark model), directed by the account holder: scouted the switch, verified it against the source, and drafted the change and this description.

@JJAutoCompare

Copy link
Copy Markdown

Tested

Independently reran the pinned standalone CPU executable at 55beb04c6e6346842a1241aeb5c0e487e354d033 on Windows 11 x64 build 26200.9974 with a Ryzen 7 3800X. The binary was built with Rust 1.100.1 (x86_64 MSVC). The 91-byte enabled() and 167-byte lazy() helpers matched byte for byte across the tested head, the harness, and the checked main revisions.

Ran pso_switches.exe lazy_and_async_pso_switches --exact --nocapture --test-threads=1 --color=never in 12 fresh processes with child-only XCL_VERIFY_CASE_3202 indices 0–11. The matrix crossed XCL_ASYNC_PSO unset, 0, and " 0 " with XCL_LAZY_PSO unset, empty, 0, and " 0 ".

All 12 processes exited 0. Total was 12 passed, 0 failed, 0 ignored, 0 skipped. Native UTF-16 enumeration, direct lookup, and Rust agreed for both variables in every case. All three predicate reads agreed within each child. enabled() was false only for literal async 0, and lazy() was false whenever either switch was literal 0.

Not tested

Pipeline creation or scheduling, waits, GPU and cache behavior, retail titles, and the Cargo workspace suite.

AI use

T3 Code through Codex (gpt-6.2-sol, high) prepared the standalone harness, verified the source and executable pins, independently reran all 12 cases, and drafted this report.

@Foniass

Foniass commented Dec 1, 2026

Copy link
Copy Markdown
Contributor

Review (head 55beb04, diff read, not a merge-check; draft, README only, conflicts with main):

  • "so pipelines the title never uses are never built" isn't true by default. Up to XCL_PSO_AHEAD (default 4096) lazy pipelines no earlier run used are built ahead of their first use, while 8 GiB of commit is free (ahead_cap / ahead_room, pso_async.rs ~4925-4950). "...are built on first use, or ahead of it in the background within XCL_PSO_AHEAD" would match. README: document XCL_PSO_AHEAD #3227 documents that switch.
  • Precision: only the exact value 0 turns it off (lazy(), ~4421, doesn't trim), and the README line could say that a compute pipeline is built at its first bind while a graphics one's first bind sends it to the workers (the doc comment at ~4415).

Fine: it applies only while background building is on (enabled() &&), as written, and the README doesn't name the variable yet.

AI review: Claude Code (Claude Opus 5.5), posted by Foniass without a human check of each point.

@Foniass

Foniass commented Dec 1, 2026

Copy link
Copy Markdown
Contributor

Triage (#1607) – head 55beb04

The other README PRs of this series (#3118, #3155, #3215, #3227, #3274, #3285, #3311, #3334) each document a different variable; no PR documents XCL_LAZY_PSO. The text matches pso_async::lazy(): it is on unless set to 0, and only when background pipeline building (enabled()) is on. No problems found in the diff.

Recommendation: keep open.

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants