Skip to content

D3D12.X: record first use of synchronously created compute PSOs - #2409

Draft
ettehn wants to merge 2 commits into
xcl-dev:mainfrom
ettehn:codex/pso-manifest-sync-first-use
Draft

ettehn wants to merge 2 commits into
xcl-dev:mainfrom
ettehn:codex/pso-manifest-sync-first-use

Conversation

@ettehn

@ettehn ettehn commented Nov 25, 2026

Copy link
Copy Markdown
Contributor

Stacked on #2096. The only commit added by this PR is cd9fb4d6, on top of bb4dea40.

A compute pipeline created synchronously could skip the pending-entry path and never record its first bind. This leaves milestone precompilation with an incomplete prefix. This follow-up covers eager ready handles and already-translated synchronous pipelines.

What is in it

  • Record the first bind for both synchronous paths, with one use event across repeated binds. Keep the existing used-pipeline log behavior.
  • Add a GPU regression that creates and binds a compute pipeline twice, checks one ready use event after build, and verifies dispatch output.

Tested

  • Windows 11 25H2 (26200.9974), Ryzen 9 8945HX, RTX 5070 Ti Laptop, NVIDIA 621.24, Rust 1.97.1 MSVC, SDK DXC 1.8.2502.11, debug.
  • cargo build --workspace --offline --locked -j 2 passed. cargo test --workspace --offline --locked -j 2 --no-fail-fast -- --test-threads=1 --nocapture: 1,154 passed, 4 failed, 46 ignored. The new regression and all three manifest unit tests passed.
  • The four DXIL fuzz shards failed at seeds 70, 545, 1019, and 1507 with CreateComputePipelineState returning 0x8007000E. The same four seeds failed with the same error on the unchanged D3D12.X: XCL_PSO_MANIFEST=1 writes the order a run asks for its pipelines (#2088) #2096 parent bb4dea40. The workspace run printed 24 explicit skips for native wave64, unsupported per-lane operations, and unavailable heap windows.

Regression run

  • Paired retail xcl-smoke runs are pending.

Not tested

  • Retail title, AMD, native wave64 and Linux/Wine.

AI use

  • OpenAI Codex (GPT-6.2 Sol) assisted with the implementation, regression test, and Windows verification.

Anon64 and others added 2 commits November 25, 2026 03:17
…ines (xcl-dev#2088)

Part of xcl-dev#2088, workstream 1 (the recording only): which pipelines a title
needs before each point of its start, in the order it needs them, and which
it had to wait for.

With XCL_PSO_MANIFEST=1, pso-manifest.txt beside used-pipelines.txt (a new
file each run) gets one tab-separated event a line, numbered in file order
with the milliseconds since the first:
- use: a pipeline's first use (pso_async's note_use), its shader-set key,
  compute or graphics, and whether it was built by then (ready / cold);
- build: each driver compile (driver_compile_identified): kind, DXIL bytes,
  the console record's hash and whether a driver blob was supplied, time in
  the driver and time waiting for a compile slot;
- present: the title's presents at milestones (1, 2, 4 ... 1024, then every
  1024th), so a manifest shows where presents stop and whether they return.

A first use's line is written, under the manifest's lock, before the
pipeline is marked used: a second bind of it (and a present after that) comes
after the line in the file (found in review by ettehn).

Recording only, off by default: nothing is built, ordered or skipped
differently.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Track eager ready handles and first binds that skip a pending entry, so an ordered manifest can select the complete prefix through a Present event.
@DavidM1911

Copy link
Copy Markdown
Contributor

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

Thanks!

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