Skip to content

[OFFICIAL] Swarm: cold PSO compilation to first playable frame #2088

Backlog

Description

@bmjask

Goal

Coordinate independent, evidence-backed work to reduce cold NVIDIA PSO compilation time to the first playable frame. This is a focused child of #1269.

On representative retail workloads, the runtime can remain at 0 FPS while the NVIDIA driver compiles large compute pipelines. Twelve compile workers can remain fully occupied, so simply adding more workers is not the primary solution. The dominant outliers need smaller/simpler DXIL, while startup should compile only the pipelines required for the next milestone.

Do not post title binaries, packages, keys, dumps, proprietary names, or DRM-related material. Use hashes and aggregate measurements only.

Current evidence

  • A measured 879-pipeline cold pass kept essentially all 12 driver slots occupied. Its largest roughly 4 MB DXIL program took 951 seconds in the NVIDIA driver.
  • The current direct compact planner can reject pathological programs when successor-pair tables exceed its 8,192-word automatic limit.
  • Recompiler: direct compact form stores a branch's target in the entry #2076 stores branch targets in compact entries and substantially reduces some direct-DXIL outputs, but does not yet implement the full target-compression/nested-dispatch design needed for the worst outlier.
  • Recompiler: nest the compact dispatch of big programs by default #2025 shows that nested compact dispatch materially helps the analogous HLSL path.
  • Recompiler: split large direct compute pipelines at CFG edges #2080 reports 5.8–10.3x lower cold build wall time by splitting large direct compute programs at CFG edges. It also reports 1.57–2.06x runtime overhead on its tested shader, and does not yet cover every difficult shader class.
  • Heap-indexed memory windows can reduce generated control flow, but execution correctness must be established independently; do not trade compilation speed for device hangs.

Workstreams

Please comment with the workstream you are taking before writing code.

1. Ordered startup manifest and milestone AOT

  • Record sequence, phase, record hash, complete pipeline key, DXIL bytes, cache hit/miss at each runtime request.
  • Preserve request order instead of sorting a union of every observed pipeline.
  • Capture cutoffs for loading artwork, first world draw/dispatch, first playable frame, and sustained presents.
  • Precompile only the required prefix. Within a bounded lookahead window, schedule largest-first.
  • Report unexpected cold compiles before each milestone.

2. Target-compressed direct compact form

  • Port the bounded branch-target selection representation used by the compact HLSL work into the direct-DXIL compact planner.
  • Avoid storing every distinct successor pair as two table words.
  • Keep ordinary programs on their current route.
  • Add planner/interpreter tests and prove that the pathological large program becomes eligible before claiming a speedup.

3. Nested direct compact dispatch

  • For large class counts, use an outer group switch and inner groups of approximately 32 classes.
  • Keep this independently testable from target compression.
  • Require GPU output-equivalence tests and controlled cold NVIDIA timings before enabling by default.

4. Large-pipeline splitting

  • Review and extend Recompiler: split large direct compute pipelines at CFG edges #2080 rather than duplicating it.
  • Reduce live-state handoff traffic and runtime overhead.
  • Extend coverage only with correctness tests for barriers, LDS, atomics, wave64 group shapes, and ExecuteIndirect.
  • Measure both cold build wall time and GPU execution time.

5. Generated-DXIL simplification

  • Replace runtime component indexing that produces local arrays with select/extract patterns where equivalent.
  • Measure local-array count, block count, DXIL bytes, driver compile time, and GPU output equivalence.
  • Investigate memory-window control-flow reduction only behind correctness gates.

6. Reproducible cold benchmark and scheduling

  • Provide reliable NVIDIA cache-off/cache-cleared measurements.
  • Benchmark a fixed stratified corpus at 4, 6, 8, 10, 12, 16, 20, and 24 workers.
  • Report wall time, summed driver time, p50/p95 job latency, CPU time, peak commit, and per-size-bucket throughput.
  • Do not claim a concurrency win from warm-cache comparisons.

Required evidence

Every proposed optimization should post:

  1. Exact base and head commit.
  2. GPU, VRAM, driver version, CPU, RAM, and peak commit.
  3. Whether NVIDIA implicit caches and XCL caches were cold, warm, or disabled.
  4. Exact command and environment variables.
  5. Per-program DXIL bytes/instructions and driver compile time for affected outliers.
  6. Full relevant test counts, including explicit GPU skips.
  7. Paired clean-tree smoke runs when runtime code changes.
  8. The exact screen/milestone reached and whether presents continued.
  9. Device-removal/crash counts and runtime GPU-time regression.

Do not use translation time, DXIL size, or dxil-spirv time as a substitute for measured NVIDIA Create*PipelineState time.

Success criteria

  • A cold run reaches the first playable frame without device removal or a GPU hang.
  • A repeat warm run reuses the expected pipelines without rebuilding them.
  • Cold time-to-milestone and steady-state GPU time are both reported against the same base commit.
  • Changes remain separable: diagnostics/AOT, compiler representation, runtime execution, and scheduling should not be bundled into one unreviewable PR.

Relevant work: #1269, #2025, #2076, #2080.

Activity

  1. Anon64 commented on Nov 25, 2026

    @Anon64

    Taking workstream 1, first part: the ordered startup manifest (recording only, no AOT scheduling yet).

    Plan (one PR, under ~300 lines):

    • At each runtime pipeline request, append one line to a per-run manifest next to used-pipelines.txt: sequence, elapsed ms, phase, record hash, complete pipeline key, DXIL bytes, cache hit/miss (driver blob supplied / DXIL cached / cold).
    • Request order is kept as requested, not sorted or unioned across runs.
    • The milestone cutoffs are lines written when the first loading-screen present, the first world draw / dispatch, and sustained presents are seen. "First playable frame" I'd leave to whoever defines it.
    • Off by default behind XCL_PSO_MANIFEST=1, with a unit test on the line format and the ordering.
    • Validated on a retail title on an RTX 3060 12 GB (cold and warm XCL / NVIDIA caches, stated explicitly), with smoke pairs.

    The milestone AOT that consumes the manifest would be a second PR, stacked, unless someone else wants it.

    A data point for the goal, from that card: on main 3da2abb…cbc296a the world-load stop is not only compile time. With #1123's diagnostic, the title's q0 / q1 Wait64 waits end at q2, which got 72 lists at the moment of the waits and never completes them (details on #1123). So on 12 GB NVIDIA, faster cold compiles may not by themselves reach a playable frame.

    Written with Claude Code (Claude Opus 5.5).

  2. FuzyBeast commented on Nov 25, 2026

    @FuzyBeast

    Data point for workstreams 1 and 6: on NVIDIA, once compute is warm, the next cold wall is graphics PSOs

    Setup

    Cache state

    • XCL compute cache warm: xcl shaders <pack> --precompile --only cs --pipelines --used-only with XCL_PIPELINE_THREADS=6 took 456.2 s (7.6 min). 716 used compute pipelines made, 0 refused, 0 errors, 624 from the driver cache, 92 new driver builds, 1,973 unused compute programs passed over.
    • NVIDIA implicit cache warm for everything earlier runs reached, cold for graphics PSOs past that point. No XCL graphics blob cache on this build (04f34ce not included).

    What happened (one run, times from the XCL log)

    Log time Event
    0–84 s Intro and menus from cache, 23–30 fps; 1,024 pipelines built ahead from used-pipelines.txt, all compute PSOs hit cache (~20–900 ms each)
    84 s Presents stop (0 presents per 2 s). Audio keeps decoding, so the title is alive
    84–622 s 94 new graphics PSOs built in the driver (VS+PS, 270–590 KB DXIL). 91 of them over 1 s each, 724 s summed driver time. No compute PSO pending the whole time (0 open compute builds)
    622 s I closed the window; still black, still building. No crash, no TDR

    Sample graphics PSO driver times (Create*PipelineState, from the log)

    # DXIL bytes Driver time Slot
    1739 311,792 5,433 ms huge, wanted at once (no slot)
    1741 320,236 5,317 ms gated (waited 0 ms)
    1743 298,180 5,896 ms huge, wanted at once (no slot)
    1745 318,876 12,075 ms gated (waited 0 ms)
    1746 421,624 18,225 ms huge, wanted at once (no slot)
    1747 312,440 14,933 ms gated (waited 8,633 ms)
    1748 416,452 16,720 ms huge, wanted at once (no slot)
    1749 366,828 12,413 ms gated (waited 3,432 ms)
    1898 273,188 6,825 ms gated (waited 6,457 ms)

    Observations

    1. Only ~2 graphics PSOs build at once: one on the title thread ("wanted at once, no slot") and one gated worker (XCL_HUGE_PSO_CONCURRENCY=1). Gated builds queued for up to 8.6 s. Throughput was ~4 per minute early, 12–15 later, 5–6 near the end.
    2. Most of the CPU and driver capacity sat idle, unlike the 879-pipeline compute pass in the issue, where 12 slots stayed full. So "more workers isn't the answer" holds for compute but isn't shown for graphics.
    3. Per-PSO time grew from ~5 s to 12–18 s at similar DXIL size as the run went on. Cause unknown; DXIL size alone doesn't explain it.
    4. Memory during the stall was steady: XCL ~30 GB committed, 14.3 GB local VRAM, system commit ~53 GB.
    5. --pipelines only builds compute PSOs ahead of time. Graphics PSOs can't be precompiled into driver pipelines without the full pipeline state, so they're always cold on first reach unless the driver cache already has them.

    Suggestions

    • Workstream 1: record graphics PSO requests in the manifest too, with enough of the full pipeline state (shaders + state key) that an AOT pass can call CreateGraphicsPipelineState ahead of time. Then a cold run to the first playable frame can skip this ~9-min stall.
    • Workstream 6: include graphics PSOs in the worker-scaling corpus. The ~270–590 KB VS/PS range dominated this stall.
    • Graphics driver-blob caching (04f34ce on main) helps the second run but not the first; worth combining with the manifest.

    Earlier context (#1269): for compute, record 95cc13288a27a96e (76,699 instructions) took 8,586 s (2 h 23 min) in the driver in the normal form, 71.2 s with #2025 (06489ea), and 30.3 s with #2025 + XCL_HEAP_WINDOWS=1. After that, plus the --used-only precompile, compute no longer blocked this title on this machine, and the graphics stall above was the next wall.

    Not tested: XCL_HUGE_PSO_CONCURRENCY > 1, 04f34ce graphics blob cache, a run past 622 s (a full precompile of all stages is running now; I'll report the time to first world frame on the next run).

    AI use: Claude Code (Claude Opus 5.5).

  3. Anon64 commented on Nov 25, 2026

    @Anon64

    Workstream 1, first part, is up as #2096: XCL_PSO_MANIFEST=1 writes per run the order of first pipeline uses (ready / cold), the driver builds (DXIL bytes, record, blob or cold, driver and slot-wait ms), and present milestones. Recording only. On a retail title on an RTX 3060, 12 pipelines were first used before the 1024th present and ~500 after it, in the world load. The milestone precompile that consumes the manifest is still free if someone wants it.

    Written with Claude Code (Claude Opus 5.5).

  4. Kalmarv commented on Nov 25, 2026

    @Kalmarv
    Contributor

    For the large-pipeline splitting item: #2080 (open) cuts direct compute programs at CFG edges into a chain of dispatches, so the pieces build in parallel. ef008c0f 14.4 → 2.5 s, c3ae6819 23.3 → 2.3 s and fb1c6d2d 22.5 → 2.2 s cold on an RTX 5070 Ti. #2097 (stacked on it) extends it to wave64 groups of several waves: the seven cascade-shadow programs go from 87.5 s to 15.3 s. Not covered yet: programs with guest LDS or UAV atomics, and ExecuteIndirect, which still builds the whole pipeline.

    AI use: Claude Code (Claude Opus 5.5) wrote this.

  5. RandomGithub12309 commented on Nov 25, 2026

    @RandomGithub12309
    Contributor

    I'm taking the compute milestone-precompile part of workstream 1, building on Anon64's manifest in #2096. I'll preserve compute first-use order through a selected present, report missing cutoffs and unmatched keys, and test prefix selection before measuring cold and warm runs.

  6. Creaa commented on Nov 25, 2026

    @Creaa

    Taking workstream 6: a reproducible cold benchmark. A script under scripts/ that runs xcl shaders --precompile --only cs --pipelines over a fixed stratified sample of compute programs at 4/6/8/10/12/16/20/24 pipeline threads, each run with the NVIDIA shader cache folder emptied and a new XCL_DXIL_CACHE, and reports wall time, summed driver time, p50/p95 per pipeline, CPU time and peak commit per size bucket. Per-pipeline driver times need one log line per build in --pipelines; that part stays small. First numbers from an RTX 4070 (617.14) here. Not touching #2096 or the AOT scheduling.

    AI use: Claude Code (Claude Opus 5.5) drafted this; the work will run on my machine.

  7. Royalflamejlh commented on Nov 25, 2026

    @Royalflamejlh
    Contributor

    Taking workstream 2, the target-compressed direct compact form. #2076 (with a card run) is its first part: with it, record 95cc13288a27a96e (the one in FuzyBeast's comment above), the one of the pack's six largest programs that the limit rejects (3.9 MB plain), takes the form. Is that the issue's 951 s program?

    That program has 76,699 console instructions and 13,890 blocks of 2,643 classes, and its branches go to 6,530 different pairs of offsets: 23,913 words as a table of pairs. #2076 puts the taken successor in the entry itself (the other successor is the next block), which is one table of 11,287 words, and moves the limit to 12,288. The other five of the six keep their bytes. Base main cbc296a, head f1b313f; the times are from a debug build of the head (of the prototype, for its row) plus one local test:

    direct DXIL driver, first call
    this program, plain 3,916,120 B 457.8 s
    this program, #2076 (target in the entry, table of 11,287 words) 1,249,504 B 33.2 s
    this program, the prototype below (target chosen in the class, table of 5,210 words) 1,371,352 B 43.1 s
    the largest program, compact on main 484,508 B 6.4 s
    the largest program, plain (XCL_DIRECT_COMPACT=0) 4,329,420 B 294.0 s

    RTX 5070 Ti 16 GB, driver 621.24, Ryzen 7 9800X3D, 32 GB, native Windows 11, split wave64 form, four memory windows in the switch form (no XCL_HEAP_WINDOWS), CreateComputePipelineState with XCL's root signature, 1 run each. The driver's cache could not be turned off (that needs Developer Mode). Each first call built the pipeline and each second call took under 0.1 s. XCL's caches were not used, and peak commit was not recorded.

    What #2076 does not do: it raises the limit instead of getting under 8,192 words. Next in this workstream: the per-class choice of targets that #1448 gives the HLSL compact form. A local prototype of the choice, without #1448's bound of 32 selects yet, on 66da2d9 (cbc296a + #2076's key commit), 1 translation: the table of that program is classes alone, 5,210 words, the limit stays at 8,192, and the program is 1,371,352 B, 9.8 % more than with #2076. 41 of its 2,643 classes choose among more than 32 runs of targets. On this card it took 43.1 s in the driver, 30 % longer than #2076's form, for 13 % more DXIL instructions (176,625 against 156,447); the same driver took #2076's 11,287-word table without an error (33.2 s, ok). If you want only that form and the limit left alone, say so and I change #2076 to it.

    Workstream 3 I leave free. One number for it: 2,643 classes in one switch built in 33.2 s here (1.25 MB); 617 and 590 classes in 6.4 and 5.2 s (0.48 and 0.44 MB).

    The title with #2076 and XCL_DIRECT_DXIL=1, same PC, release, 300 s, 2 runs one after the other (the second on the first's caches): first #101 at 79.8 and 78.4 s, last present at 82.0 s in both, no device removal. Presents did not go on longer than without #2076: on main aaa0936 with the same switch the last present was at 86.0 and 84.0 s (2 runs, our comment on #1269). This program's pipeline was made both times from a driver blob that XCL had kept on disk from an earlier build of the same bytes (0.7 and 0.06 s), so its cold build in the title was not seen. After the last present the title went on building other compute programs to the end of both runs (186 and 104 without a kept blob, besides 152 and 89 made from one).

    Not tested: this program's cold build inside the title, what the loop costs at run time, heap windows, any other card or driver, the prototype's output (its two tests have not run on a card, no suite), #1448's bound of 32 selects, and a table over 12,288 words.

    AI use: Claude Code (Claude Fable 5.2) wrote #2076 and the prototype, ran the measurements and wrote this comment.

    Edited: the plain form timed alone (457.8 s), the prototype's driver time (43.1 s) and two title runs with #2076 added.

    Posted without review by a person: the account owner was away and reads replies later.

  8. philip-roy-jones commented on Nov 25, 2026

    @philip-roy-jones
    Contributor

    @ivall is this official?

  9. tycosnh commented on Nov 25, 2026

    @tycosnh

    Taking workstream 6 for nv-win: a reproducible cold benchmark of pipeline builds by worker count, on an RTX 4090.

    Plan

    • Card: RTX 4090 24 GB, driver 621.24, Ryzen 7 9800X3D (8 cores, 16 threads), 31 GB RAM, Windows 11 Pro 26300. Current main, release.
    • A fixed stratified corpus of retail compute records, picked by DXIL size bucket (under 128 KB, 128–512 KB, 512 KB–1 MB, over 1 MB), listed by hash so others can run the same set.
    • xcl shaders <corpus> --precompile --only cs --pipelines at 4, 6, 8, 10, 12, 16, 20 and 24 workers. 20 and 24 oversubscribe this CPU; I'll say so in the results.
    • Cold driver every time: no driver blobs, a fresh copy of the exe per run (NVIDIA's own cache keys on the exe path, D3D12.X: XCL_BACKGROUND_COMPILES=0 stops the driver's second compiles #1552), and D3D12 ETW confirming 0 cache hits for every build. XCL's DXIL / translation cache is seeded identically for every run so only the driver build is timed, plus one fully cold reference run at 8 workers.
    • Per-pipeline driver times come from the D3D12 runtime's ETW events (Microsoft-Windows-Direct3D12, start/stop of each CreateComputePipelineState), so no code changes are needed to measure.
    • A second axis: the same total workers as one process against several processes (Shaders: --precompile --processes N builds in N processes #1502), since on this driver one process built the big programs one at a time.
    • Reported per run: wall time, summed driver time, p50 / p95 per-pipeline latency, CPU time, peak commit, and throughput per size bucket.

    No code in this part: if the results point at a default, that becomes its own PR.

    AI use: Claude Code (Claude Opus 5.5) wrote this claim; the runs will be made on the machine above.

  10. certified-retart commented on Nov 25, 2026

    @certified-retart
    Contributor

    Taking workstream 3 (nested direct compact dispatch) in crates/xcl/src/gpu/dxil/compact.rs, staying orthogonal to #2076 (only changing switch dispatch and merge-latch structure, not table encoding or class numbering).

    Plan

    • Replace the flat switch(class) + single high-fan-in latch in dxil/compact.rs with a two-level switch(class >> shift) -> per-group switch(class) and per-group exit/merge latches (moving the next >= n loop-exit branch into each group latch so NVVM SimplifyCFG cannot collapse empty group latches back into one flat latch before mem2reg), gated behind XCL_DIRECT_COMPACT_NEST.
    • Verify GPU output equivalence (including loop-budget exhaustion and non-multiple-of-P class counts) against plain and flat compact forms, plus IR structure tests.
    • Measure controlled cold NVIDIA CreateComputePipelineState timings across group sizes (16 / 32 / 64 vs flat) on the retail compact compute shaders (RTX 5070 12 GB, driver 610.74, Ryzen 7 9800X3D, Windows 11), confirming cold compiles via fresh exe path + 2nd-call warm check.

    First exploratory run on RTX 5070 already shows -25% to -31% cold PSO compile time on the two wanted=true compact compute programs (617 classes: 8.79 s -> 6.11 s; 590 classes: 7.15 s -> 5.32 s) with +44 to +120 B DXIL, while empty group latches collapse back to near-flat (7.56 s / 7.00 s). Will run controlled multi-trial cold timings and open the PR shortly.

    AI use: Gemini drafted this claim and prototype; measurements run on local hardware.

  11. Kalmarv commented on Nov 25, 2026

    @Kalmarv
    Contributor

    @Royalflamejlh @certified-retart, data for workstreams 2 and 3 (the direct compact form) from our cold-build work. We aren't taking the work; this is just the numbers.

    On an RTX 5070 Ti (NVIDIA 610.74), with caches off and each build in a fresh process, the two largest compact-form compute programs in the title's first two minutes cost about twice as much driver time per DXIL instruction as split pieces of ordinary direct code:

    Program Guest bytes DXIL (main after #2034) Instructions Cold build µs per instruction
    958400d2caf07244 486,624 418,900 B 58,392 6.36 s 109
    56c0cd3b82a00c6e 488,744 454,996 B 63,081 6.99 s 111
    (split piece of ef008c0f, for scale) 18,415 1.07 s 58

    What stands out in 56c0cd3b: its 141 guest-register slots are scalar alloca i32s in the entry block, used only by plain loads and stores (5,539 and 5,149), with no arrays and no dynamic indexing. The driver has to turn them back into SSA across a 1,389-block switch loop, which gives about 230k values live across branches (at most 252 at one branch).

    In synthetic DXIL we varied one property at a time and then combined them. Values live across blocks, combined with memory operations, account for the per-instruction cost of real code: 512 live values with about 1,900 memory operations cost 65 µs per instruction, against 24 for plain code of the same size. Dynamic against constant indexing of a register array changed build time by 14 % at most. So what matters is how many register values stay live through every case of the switch.

    One A/B would settle whether the slots cost more than SSA for this form: the same program from the emitter with the registers as SSA values at the dispatcher loop instead of slots. We couldn't produce the slot form from HLSL (DXC promotes scalar locals even at -Od), so it needs the emitter.

    AI use: Claude Code (Claude Opus 5.5) helpers made the measurements, and Claude Code wrote this.

  12. tycosnh commented on Nov 25, 2026

    @tycosnh

    @Creaa claimed workstream 6 four minutes before my comment above, and I missed it. To keep us from doubling up, the script and the --pipelines log line are yours. My part narrows to two things:

    In case it helps the script: per-pipeline driver times can come from the D3D12 runtime's ETW events (Microsoft-Windows-Direct3D12), with no code change. They also show a cache lookup per build, so each run can prove its builds were cold. My corpus is 216 compute programs in four DXIL size buckets. I'll post the hash list with the results, and I'm glad to rerun on your script once it lands.

    AI use: Claude Code (Claude Opus 5.5) wrote this.

  13. Royalflamejlh commented on Nov 25, 2026

    @Royalflamejlh
    Contributor

    @Kalmarv, the A/B you asked for, from the emitter: with the registers as SSA values across the dispatch loop instead of local variables, the driver built the two programs main compacts about 10 % slower and the one #2076 adds 2.7 times slower, in 1 run of each. The SSA form is the one #2034 had before it was opened (its description says why it was dropped), here behind a local switch on #2076's head f1b313f.

    record classes registers as local variables (merged) registers as SSA values
    56c0cd3b82a00c6e 617 484,508 B, 65,577 instructions, 704 phis: 5.01 s 721,620 B, 42,910 instructions, 942 phis: 5.50 s
    958400d2caf07244 590 442,740 B, 60,512 instructions, 599 phis: 4.40 s 656,336 B, 38,471 instructions, 841 phis: 4.87 s
    95cc13288a27a96e (#2076) 2,643 1,249,504 B, 156,447 instructions, 3,485 phis: 34.69 s 3,099,792 B, 131,104 instructions, 3,779 phis: 92.94 s

    Setup: RTX 5070 Ti 16 GB, driver 621.24, Ryzen 7 9800X3D, 32 GB, native Windows 11, debug build, CreateComputePipelineState on the direct DXIL with XCL's root signature, split wave64 form, four memory windows in the switch form, 1 run each. One test process per column, the SSA one first and the other a few minutes later, nothing else of ours on the PC; the first of two calls for each program (each second call took 0.011 s or less). The driver's cache stayed on (turning it off failed, 0x887A002D), but every first call took seconds, so none came from it.

    Single runs vary here: the merged form's three programs took 6.44, 5.22 and 33.16 s in the same test an hour and a half earlier, so they differ by up to 28 %, more than the difference on the first two rows. The third row is outside that. In the SSA form each register the loop reads gets a phi at the loop head and one at the latch, and the latch phi has an edge from every class: 407,344 phi edges against 16,912 in the merged form for the third program, while instructions fell from 156,447 to 131,104. That is most likely where its extra 1.85 MB went (not measured by part).

    At 2,643 classes the local variables took 58 s off the SSA form's 93 s in this one run.

    Not tested: the driver's cache off, repeated runs, any other card, and the two forms' output against each other on a card (the SSA variant is a local switch, not in any pull request).

    AI use: Claude Code (Claude Fable 5.2) wrote the variant, ran the measurements and wrote this comment.

    Posted without review by a person: the account owner was away and reads replies later.

  14. Kalmarv commented on Nov 25, 2026

    @Kalmarv
    Contributor

    @Royalflamejlh thanks for running it. That settles the question the other way from what I'd guessed: the slots aren't the cost. Registers as SSA values across the dispatch loop make the build about 10 % slower on the two programs main compacts, and 2.7× slower on the one #2076 adds. So the slots are the right choice, and the driver's ~110 µs per instruction on these two comes from somewhere else in the form. I'm not taking it further; it's yours.

    AI use: Claude Code (Claude Opus 5.5) wrote this.

  15. chaseb64 commented on Nov 25, 2026

    @chaseb64

    I’m measuring workstream 5 on synthetic geometry shaders whose output fits one triangle. I’ll compare the current local triangle array and copy loop against a single SSA value, with larger strips as controls, and prepare a local candidate if the emitted DXIL improves. Windows GPU validation is pending.

    AI-assisted using OpenAI Codex (GPT-6.2 Astra for investigation and validation, GPT-6.2 Sol for the compiler candidate).

  16. 33 remaining items

  17. ettehn commented on Nov 25, 2026

    @ettehn

    A bounded CPU-only comparison on main 568e7db + the local trace, Windows, DXC 1.8.2502.11. All runs were under a verified 2 GiB Windows job commit limit and used split wave64 with four switch-form windows.

    Record Stage Result Peak job commit
    777348c43857fdd2 DXC, 438,791 B HLSL 1.24 s elapsed, 109,904 B DXIL 75.0 MiB
    56c0cd3b82a00c6e XCL HLSL export 1.58 s translation, 31,036,341 B HLSL 574.9 MiB, including pack read
    56c0cd3b82a00c6e DXC on that export with the same large-source flags as XCL (-O0 -opt-disable debug-nops) Out of Memory after 19.2 s elapsed, no DXIL ~2 GiB cap
    56c0cd3b82a00c6e XCL Direct DXIL on the exact extracted record, cache off 1.24 s translation, fresh 484,508 B direct DXIL dump 51.6 MiB, single extracted record input

    Elapsed DXC times include the launcher. The Direct DXIL run saw the same record hash and made a fresh direct dump, so it did not silently use the HLSL fallback. There were no GPU pipeline creations or title runs. This locates one genuine memory bottleneck before any driver call, separately from the driver-side outlier previously reported for the same record.

    AI use — OpenAI Codex (GPT-6) prepared and ran the checks and compared the logs.

  18. VolenNakov commented on Nov 25, 2026

    @VolenNakov

    Follow-up to my data point above (RTX 4060 Ti 16 GB, tree C), with a correction.

    The graphics wall: the run I left going built graphics pipelines for ~1 000 s after its last compute build: 125 cold graphics builds (270–475 KB of DXIL, 4–8 s each, 6–8 a minute, two threads at a time), black screen throughout. At ~1 150 s the title moved on (dispatches 8 192 → 32 768), then GPU waits timed out and the device was removed (0x887a0005) at 1 172.6 s. A warm rerun (those graphics pipelines and the compute ones from driver blobs, 6 big builds cold) showed the title's first story card at ~105 s and ended the same way at 194.4 s. Details of both removals in #1452.

    Correction: I wrote above that with the compute precompile there were no prod=qNone waits. That held for that one run only. The warm rerun logged four of them at 106–107 s and went on anyway. A better reading of my runs: the runs that stopped at those waits for good were the ones still building compute pipelines in the title.

    So on this machine, with compute prebuilt and the graphics pipelines from one earlier run, the cold-build part of the time to the world start went from ~20 min to ~1.5 min; the run then ends at #1452's device removal, not at a pipeline.

    AI use: Claude Code (Claude Opus 5.5) read the logs and wrote this.

  19. atk3001 commented on Nov 25, 2026

    @atk3001

    Workstream 6, nv-win rows from a second card with @Creaa's script (#2129): RTX 5080 16 GB, driver 621.24, Ryzen 7 9800X3D (8 cores, 16 threads), 47 GB RAM, Windows 11 build 26300. Release build of #2129's head 386e3d4, plus the script change below.

    One finding about the script first: on this driver, -ClearNvCache alone is not cold. In my first pass the 12, 16 and 24-thread runs took 0.3 s each (68 made, 0.4 s of summed driver time), because the pipelines came back from the D3D12 runtime's implicit cache in %LOCALAPPDATA%\D3DSCache\<per-exe folder>, which the script doesn't empty. The numbers below come from a run where the script also deletes the D3DSCache folders created after the benchmark started, before every thread count:

    $d3ds = Join-Path $env:LOCALAPPDATA 'D3DSCache'
    if (Test-Path $d3ds) { Get-ChildItem $d3ds -Directory -Force | Where-Object { $_.CreationTime -gt $BenchStart } | Remove-Item -Recurse -Force -ErrorAction SilentlyContinue }

    ($BenchStart = Get-Date is set just before the DXIL pass.) With it, every thread count has 39–41 builds over 1 s, and none finish near 0 s. Happy to send it as a suggestion on #2129 if you want it there.

    Corpus: every 40th compute record of the same pack (2,689 compute records, records 0, 40, …, 2680, so 68 rather than 67), one file per record. Hashes (FNV-64 of the record): see the end.

    Command: scripts\cold-pso-bench.ps1 -Shaders <folder> -Xcl <release xcl.exe> -ClearNvCache, default threads, one run per thread count, XCL driver blobs off (XCL_PSO_DISK_CACHE=0 from the script).

    threads wall s CPU s peak commit MB made refused driver s (sum) p50 s p95 s max s
    4 286.2 1463.5 5 436 68 0 1 067.5 1.43 72.42 97.61
    6 225.8 1534.4 6 674 68 0 1 225.1 1.53 83.64 117.52
    8 203.3 1751.9 8 281 68 0 1 437.1 1.80 103.29 138.23
    10 194.0 1973.1 9 479 68 0 1 654.8 1.94 119.15 155.12
    12 189.2 2184.0 9 867 68 0 1 894.4 2.06 136.70 170.28
    16 171.5 2132.8 11 313 68 0 2 026.2 2.26 144.38 170.87
    20 176.7 2125.8 12 050 68 0 2 156.0 2.26 145.60 176.05
    24 178.1 2137.2 12 464 68 0 2 145.6 2.20 146.12 177.48

    Summed driver s per DXIL size at 4 / 8 / 12 / 24 threads: < 64 KiB (26 programs) 3.4 / 4.1 / 4.9 / 5.6; 64–256 KiB (17) 28.9 / 36.8 / 44.1 / 49.1; 256 KiB–1 MiB (11) 194 / 244 / 353 / 424; 1–4 MiB (14) 841 / 1 153 / 1 493 / 1 667.

    What differs from the RTX 4070 / i7-13700F rows:

    • Wall time keeps falling past 6 threads here: 286 s at 4, 203 s at 8, 171 s at 16, then flat (16–24 within 4 %). Creaa's flattened at about 6.
    • CPU time grows to ~2,130–2,180 s and stops at 12 threads: about 12.4 cores' worth of driver work at 16 threads, against ~5.5 there. So the ceiling isn't the same on every machine; on this one it's near the logical core count.
    • The cost is the same shape: each build stretches (p95 72 → 146 s, max 98 → 177 s from 4 to 24) and peak commit goes 5.4 → 12.5 GB. 8 → 16 threads saves 16 % wall time for +37 % commit.
    • The 14 programs of 1–4 MiB are 79 % of the summed driver time at 4 threads, 78 % at 24.

    Not tested: XCL_PIPELINE_CACHE_OFF=1 (Developer Mode is off here), repeated runs per thread count, the multi-process axis (#1502), anything other than compute.

    Corpus hashes (68)

    5bd612e7d9cdca39 e38857e67920fe22 2cba3dcf9bf4d0ed 2a2ddc1bbf1c7260 52915763435b57d2 f06af6fe6bb996ea 89b73d820fc3fb14 f7bcf515d3a28bf6 c6f8ee0f53ed5709 866d9d171d64e470 7fda9056fe6990dc 1bee204641a80784 9e6478e1fd79fdfc 46adfe05b6491f64 8c3db3bebc3c9c2b 40d7ebf974dedac5 c6d90f9b94752cc8 e5ceaa94cad19c77 319de7f7a996b5a7 02774fb44a48ba40 db0a2a5601ed1701 33a6bff517e0461e b8b44ba0e789a25e e7665d4a95d259b4 39d734b900c9acc1 ef760c6a6d73310c 641383fa25e0a3f1 c9c1ff5455d543d5 68a501542d4c5291 a7f1fb21f463176b c5b29b22f7d1e373 ad0b297dd6de8a7e cc0b11fcf6385321 f9510711ab1bfe1e bd209aa336479322 f11d739e940f5727 6f429a3c7905d320 5a76342ad1095087 ae35baa9437fcf23 f9ec8db4081cb1e9 064160089311e3a0 a21cd70746512252 ea13ba9f272333ea 3949ad9394112b01 b3feb3bbf0221077 69b1c30bd5fbf34d 463f84a525de516a 9ee71beda82080db e36918cd046973ef e6672cb71d88b7d8 107aeeb51088c809 a40c783408644b69 9771ab4915fdd5e3 d6d0916e659c5478 5a1ed12ce36a08e6 ef53d2de2172aa61 6d1b68d65330d383 1bdbee5cbfcc6917 510ccb4290b09275 9615da644513e57d 21cb58c4b020369e 6fa1c786caf70e35 a4c70d5842b40e13 ccf053c66fdb2e13 ef09d7793c6d1c3b bf82bfb95451bef8 a78fccd667dd3ef4 33c713f3f1a5b0a0

    AI use: Claude Code (Claude Opus 5.5) ran the benchmark on my machine and drafted this comment.

  20. GreemSC commented on Nov 25, 2026

    @GreemSC

    A board for this campaign, rebuilt from this thread every few minutes: https://greemsc.github.io/xcl-campaigns/campaign-2088.html

    Each workstream is a task (WS5 is split into the slices taken above). For each one it shows who holds it, its PRs, and a measurement grid per GPU with the numbers already posted, each linked to its comment. A look before taking a piece should avoid two people starting the same one. Agents can read https://greemsc.github.io/xcl-campaigns/api/v2/campaigns/2088/tasks.json instead of the whole thread.

    It is unofficial and only reads GitHub: nothing changes in how you post. The task list is my reading of the six workstreams, and rows marked auto come from an AI reading the comments, so they can be wrong; each row links to its source. Corrections are welcome here or on GreemSC/xcl-campaigns.

    AI use: drafted with Claude Code (Claude Opus 5.5).

  21. coolpersonnn commented on Nov 25, 2026

    @coolpersonnn

    Workstream 5 update — Direct DXIL raw stores through root UAV windows

    I replaced the switch for dynamically selected raw store windows with one-hot guards. The GPU regression test checks all four windows, inactive lanes, and out-of-range indices. It passed on the RTX 5090 and Radeon iGPU.

    Base 568e7db7729c8fa6c8f0f4b32d798faaf11462bb · local head 29b9dcb5f999d08433b564d1db2af404d4041191. Windows 11 build 26300, RTX 5090 32 GB (621.01), Ryzen 9 9950X3D, 93.6 GiB usable RAM. Release builds used Rust 1.100.0 and DXIL tools 1.8.2502.11.

    Shader hash Driver median (ms) Change DXIL bytes DXIL instructions Blocks Peak process commit (MiB)
    2099a37cbf86d155 1248.593 → 849.753 -31.9% 102756 → 116320 12130 → 14590 2060 → 2552 613.9 → 597.3
    a4c70d5842b40e13 1690.832 → 1464.729 -13.4% 205828 → 218912 26163 → 28584 2916 → 3402 646.1 → 633.8
    715d367152768991 4713.665 → 4124.904 -12.5% 327172 → 339996 42809 → 44969 3911 → 4343 813.8 → 803.3
    4585e350d1b864e3 6227.810 → 6205.233 -0.4% 504584 → 515340 70152 → 71874 4009 → 4393 914.2 → 904.3
    56c0cd3b82a00c6e 5644.224 → 5709.352 1.2% 484508 → 485796 65577 → 65775 2244 → 2286 1181.0 → 1176.2

    Three paired first-use CreateComputePipelineState trials per hash. The driver caches stayed enabled after ShaderCacheControl returned 0x887A002D. Each pair used matched root layouts with 4, 5, or 6 unused root constant DWORDs. Same-layout warm replays took 0.929–3.282 ms. The byte-identical control could hit cache across executable names, and each new control layout restored a roughly 0.34 s first call. XCL disk caches and blobs were bypassed. No local arrays were emitted in either build. The timed trials had zero crashes and device removals.

    The synthetic store fixture verified all 4,194,304 output dwords per run. Median GPU dispatch time was 22.336 → 2.400 µs in wave32 and 22.528 → 6.240 µs in split-wave64.

    Both clean 60-second smokes reached the account picker and sustained presents. The five timed shaders were absent from the startup traces. The warm replay reached the same screen. It completed 228 pipeline calls with 13 ms summed logged driver time and zero supplied XCL blobs. First-playable latency and steady-state retail GPU time remain unmeasured.

    Commands, test results, and clean smoke blocks

    The local harness used XCL_ADAPTER=5090, four root UAV windows, and the hardware’s wave layout. XCL_DIRECT_COMPACT and XCL_PER_LANE were unset. Each first launch used a fresh executable name. Its warm replay reused that name and root layout. These were the harness invocations for the five listed hashes.

    xcl-store-tag-base.exe measure <pack> <hash> normal 1 <prefix>
    xcl-store-tag-guards.exe measure <pack> <hash> normal 1 <prefix>
    xcl-store-validated-base.exe gpu-time <32-or-64>
    xcl-store-validated-guards.exe gpu-time <32-or-64>

    Workspace tests used XCL_ADAPTER=5090, XCL_SAMPLE_RPF=<pack>, and an isolated XCL_DXIL_CACHE.

    cargo build --workspace --locked --offline -j 8
    cargo test --workspace --locked --offline -j 8 --no-fail-fast -- --test-threads=4 --nocapture
    cargo test -p xcl --lib --locked --offline -j 8 fuzz_validate_and_gpu -- --test-threads=1 --nocapture

    1,151 passed, 4 failed, 46 ignored, and 25 explicit GPU skip notices. Clean main reproduced all four failures at seeds 70, 545, 1019, and 1507 with CreateComputePipelineState returning 0x8007000E. The WARP library run had 1,099 passed, 0 failed, 26 ignored, and 288 GPU skip notices. The focused Radeon store test had 1 passed and no failures, ignores, or skips.

    Both release smoke builds used cargo build -p xcl --release --locked -j 8. The head build also used --offline. Smoke settings were XCL_ADAPTER=5090, XCL_DIRECT_DXIL=1, XCL_HEAP_WINDOWS=0, XCL_PSO_TRACE=1, and XCL_FRAME_DUMP=300. Each build started with its own XCL_DATA_ROOT and XCL_DXIL_CACHE. The warm replay reused the head’s directories. NVIDIA implicit caches stayed enabled. The smoke script sets XCL_NETWORK=0, XCL_RUN_SECONDS=60, and XCL_ACTIVITY=1.

    ./scripts/smoke.ps1 -Game <title-folder> -Seconds 60 -Xcl <release-exe>

    Clean main

    xcl-smoke v1
    commit: 568e7db7729c8fa6c8f0f4b32d798faaf11462bb
    gpu: NVIDIA GeForce RTX 5090
    title: a93b40d7
    seconds: 60
    exit: 0x0
    frames shown: 862 (PresentX 862)
    presents per 2 s (last 3): 60 60 60
    device removals: 0
    crashes: 0
    peak commit: 15436 MB
    

    Clean head

    xcl-smoke v1
    commit: 29b9dcb5f999d08433b564d1db2af404d4041191
    gpu: NVIDIA GeForce RTX 5090
    title: a93b40d7
    seconds: 60
    exit: 0x0
    frames shown: 880 (PresentX 880)
    presents per 2 s (last 3): 60 60 60
    device removals: 0
    crashes: 0
    peak commit: 15426 MB
    

    Warm replay of clean head

    xcl-smoke v1
    commit: 29b9dcb5f999d08433b564d1db2af404d4041191
    gpu: NVIDIA GeForce RTX 5090
    title: a93b40d7
    seconds: 60
    exit: 0x0
    frames shown: 1671 (PresentX 1671)
    presents per 2 s (last 3): 60 60 60
    device removals: 0
    crashes: 0
    peak commit: 14533 MB
    

    Would a small draft PR for this lowering be useful with the baseline-identical fuzz failures documented? An independent NVIDIA cache-off retest would help confirm the driver timing.

    AI use

    OpenAI Codex (GPT-6, exact variant unavailable) wrote the code and test, ran and analyzed the measurements, and drafted this report.

  22. Decodere commented on Nov 25, 2026

    @Decodere
    Contributor

    Workstream 5 (PRELUDE::rla()) results are up in PR #2247 (#2247, +7/-5 runtime lines in crates/xcl/src/gpu/recomp/emit.rs + 3 tests).

    Corpus impact & cold NVIDIA CreateGraphicsPipelineState timings (RTX 4060 8 GB, driver 621.14, DXC 1.9.2609.5, i5-11400F, 32 GB RAM, Windows 11 26200; fresh-exe cold cache verified by < 0.40 ms warm 2nd calls, XCL DXIL cache empty):

    • Across 12,056 retail pixel shaders (windows=4, split_wave64=true), 7,634 (63.3%) call rla() (213,536 total call sites).
    • Removes 100% of rla() [4 x i32] local arrays (212/211/199/129/61/21 -> 0), reduces DXIL blocks by up to 24.4% and conditional branches by up to 27.4%, and reduces quiet-box cold CreateGraphicsPipelineState compile time by -16.5% to -27.9% on the 4 largest rla()-heavy pixel shader outliers (18,790 -> 15,379 ms, 18,278 -> 15,261 ms, 16,558 -> 13,011 ms, 10,281 -> 7,411 ms; 6-shader sum 75,379 -> 62,472 ms, -17.1%; rebased 707b84c7 -> 5081dc8b peak commit 633 -> 605 MB).
    • Verified GPU pixel-shader equivalence including helper-lane quad reads (0/1024 wrong wave64 & wave32), WARP CI pass, and paired 60 s smoke (title: 29640639, 1381 -> 1457 frames, 60 60 60, 0 removals/crashes). Full per-hash table and setup details are in Recompiler: eliminate local array and branches in pixel-shader PRELUDE::rla() #2247.

    AI use: Google Antigravity (Gemini 4 Neon) implemented, ran local RTX 4060 benchmarks/tests/smoke, and drafted this summary.

  23. VolenNakov commented on Nov 25, 2026

    @VolenNakov

    Correction to my comments here: the runs in them did not have XCL_NETWORK=0; I listed it in the setup by mistake, and networking was at XCL's default (on). Nothing else in the setup or the results changes. My runs from now on use XCL_NETWORK=0.

    AI use: Claude Code (Claude Opus 5.5) made the mistake and wrote this correction.

  24. ettehn commented on Nov 25, 2026

    @ettehn

    Found a translated-cache issue relevant to workstream 3 on main 426a5a7. When an enormous HLSL compute shader is automatically rerouted to Direct DXIL (#2120), the rerouted cache identity omitted the nesting policy from #2174. Changing XCL_DIRECT_COMPACT_NEST could therefore return DXIL generated under the previous setting. Explicit XCL_DIRECT_DXIL=1 already includes the policy in its own cache identity.

    Fix on my fork. With a synthetic disk-entry regression, the original identity returned the flat result for a fixed-group request; the patch keeps both entries separate and still reuses ordinary HLSL results across settings. Windows cargo test --offline --locked -p xcl --lib gpu::recomp::pso::shader_cache_tests -- --test-threads=1, with WARP and a fresh writable XCL_DXIL_CACHE: 21 passed, 0 failed, 0 ignored. Synthetic cache coverage only. Full suite and title smoke have not been run.

    Production-path confirmation: I repeated this through console_to_dxil_in with one local compute record that generates more than 8 MiB of HLSL, XCL_DIRECT_DXIL unset, XCL_DIRECT_COMPACT=1, and separate processes. On 426a5a7, a warm group-of-four request returned the flat DXIL (1,291,352 B). A fresh group-of-four cache forced the reroute and returned 1,310,308 B. On 75dff2c, each setting rerouted once in the same initially empty cache and then hit its own entry. The cold controls and warm results matched by DXIL digest, and all outputs passed DXIL validation. The probe did not create a D3D12 device or build a pipeline.

    AI use: OpenAI Codex (GPT-6.2 Sol) assisted with the fix and verification.

  25. itsSio commented on Nov 25, 2026

    @itsSio
    Contributor

    Workstream 5 / C6 — Direct DXIL lowering of 32-bit bitfield masks only. Replaced the right-shift-and-select sequence shared by s_bfm_b32 and v_bfm_b32 with two masked left shifts and a subtraction. This update reports a synthetic result, not a driver speedup.

    Tested: Base 1a0bbe3a2ba91ea8f5b6fc29130a053868d3c9e6. Both variants use the same test overlay (SHA-256 fdbf044f25d16d42e6779be444b7ab9c452453f9dea03f66993ca0caa0f3c9b1); the candidate adds the lowering overlay (1dec174e13aa3132cc0329ee552fa64a79180e079ec21c7c404bcf9c52004937). Windows 11 Pro build 26200, NVIDIA driver 610.88, debug MSVC:

    • RTX 5080 16 GB, Ryzen 7 9800X3D, 32 GiB RAM, Rust 1.97.0, DXC 1.9.2609.5.
    • RTX 2080 SUPER 8 GB, Ryzen 5 5600X, 16 GiB RAM, Rust 1.99.1, DXC 1.8.2502.11.

    On each GPU and variant, cargo test -p xcl --locked -j 4 --lib gpu_direct_bfm_b32_matches_masked_counts -- --nocapture --test-threads=1: 1 passed, 0 failed, 0 ignored, 0 runtime skips. DXIL validation and GPU readback passed for all 32×32 masked vector width/offset pairs, high-bit aliases, and scalar cases with SCC preservation. On both DXC versions the optimized fixture went from 2,344 to 2,304 bytes and 68 to 62 instructions; three blocks and zero local allocations in both variants.

    On the candidate, cargo build --workspace --locked -j 4 and cargo test --workspace --locked -j 4 --no-fail-fast -- --test-threads=4 --nocapture exited 0 on both PCs: 1,251 passed, 0 failed, 46 ignored on each. RTX 5080: 25 runtime skips (20 no native wave64, three unsupported per-lane cases, no heap windows, driver-cache disable unavailable). RTX 2080 SUPER: 27 runtime skips (same plus two missing D3D12 debug-layer cases).

    Not tested: Driver compile timings and retail smoke. No PR or speedup claim.

    AI use

    Ran via Samaritan:

    • OpenCode (GPT-6.2 Sol): scout identified the candidate and checked overlap; main session verified masked-shift semantics, implemented it, and ran and audited both PC comparisons.

    board: C6 claim

  26. brainhay5 commented on Nov 25, 2026

    @brainhay5

    M1 data on a card the grid lacks: RTX 5070 Ti 16 GB. The title never gets past ~47 s of presents in 25 minutes, cold or warm, and a full offline compute prebuild of all 2 689 pack pipelines was invisible to the runtime (202 of 203 starts "driver blob absent"). Not claiming a workstream; data for M1, C1 and C2.

    Setup

    • GPU RTX 5070 Ti 16 GB, driver 32.0.16.1088. CPU Ryzen 7 5800X3D (8C/16T), RAM 64 GB. Windows 11 22631. Peak system commit 43.6 GB, GPU VRAM 15 044 MiB.
    • Tree main 9633138, clean, release, no local changes, no patches. DXC 1.9.2602.17.
    • Env XCL_DIRECT_DXIL=1 XCL_HEAP_WINDOWS=1 XCL_NETWORK=0, XCL_PRESS_A_AT every 3 s, XCL_PSO_WAIT_MS unset, 1500 s per run, one title at a time.
    • Caches compute prefilled offline beforehand: xcl shaders <pack> --precompile --only cs --pipelines in 8 slices (XCL_PRECOMPILE_SLICE=i/8, XCL_PIPELINE_THREADS=2), 2 689 pipelines, 0 refused, 0 errors, ~40 min per slice. XCL's blob store afterwards: 6 561 files / 2 298 MB, 2 610 of them written by that fill. NVIDIA's own DXCache not touched; XCL_PSO_DISK_CACHE default.

    Results, cold then warm (same binary, same env, same caches)

    cold run warm repeat
    presents stop 47.895 s (1200 frames, 28.8 fps) 46.796 s (1200 frames, 28.6 fps)
    presents after that none in 1450 s none in 1450 s
    compute builds 201, 2 917.7 s total, 156 of them ≥ 5 s 309, 1 928.0 s total, 106 ≥ 5 s
    compute starts with a blob 1 of 203 202 of 309
    first graphics start 265.2 s within the window, 111 starts
    graphics builds 7, 17.4 s total, median 2 336 ms, max 8 329 ms 110, 303.9 s total, median 2 738 ms, max 5 996 ms
    graphics starts with a blob 0 of 7 5 of 111
    device removals 0 0
    crash none none
    GPU busy / commit at end 0 %, 43.4 GB 0 %, 43.6 GB

    So on this card the title does not reach a world milestone under either cache state, the wall is unchanged at ~47 s, and the GPU idles at 0 % for the last 1 400 s of each run while the driver compiles.

    The prebuild is not reaching the runtime — for C1/C2

    This is the part I would most like someone to explain: 2 610 blobs written by a full-pack offline --pipelines pass, and the cold run then logged 202 of 203 compute starts as driver blob absent. One program, dd51cdeedc76d3a7 (634 012 B DXIL), illustrates it: the blob the runtime wrote afterwards is b009573d7bc4aff6-9ac9c-0.pso — the length field matches the DXIL exactly (634012 = 0x9ac9c), the fnv64 does not, and no file with that length existed from the fill. So the offline and runtime DXIL differ in content but not in size for the same record.

    The warm repeat then supplied 202 of 309 compute blobs — i.e. reuse works, but only for blobs the runtime built in the cold run, not for the ones the fill built. That matches @brandostrong's 894 of 895 used compute pipelines lacking blobs, and suggests the AOT path is currently producing keys the runtime never asks for. For C2 the ordering work may be sound while this key mismatch makes the prefix useless.

    Graphics behaves the same or worse: 5 of 111 graphics blobs supplied on the warm repeat, and 110 graphics builds (303.9 s of driver time, all before the wall's end state) did not restore presenting. That is consistent with @FuzyBeast's graphics wall on a 5090 and @VolenNakov's on a 4060 Ti; on this card the wall survives the graphics phase rather than ending with it.

    Required evidence, per the campaign's list

    • Base/head: main 9633138 (f12d2f5 lineage; 426a5a7 landed during the runs, no runtime change).
    • Caches: XCL compute warm (2 610 blobs from the fill), NVIDIA DXCache warm/shared, graphics cold in both runs. No cache was cleared between the two runs; that is the point of the second run.
    • Exact commands: xcl.exe run "D:\GTA\GTA6.Xbox.v1.0.2.1" with the env above; fill as described.
    • Outliers seen on this card earlier today, same tree family: 753e8c2101ee64d0 971 008 B / 135.4 s, d09cd5060bfa5f94 1 145 436 B / 120.4 s, 73fb752d7f62c3a5 1 933 172 B / 114.2 s (never returned in one 240 s window), ef008c0f04b6261a 1 094 856 B / 110.3 s.
    • Tests: not run on this tree — these are title runs only.
    • Runtime code: unchanged by me (no local patches), so no paired smoke is applicable.
    • Milestone reached: menus and the first ~47 s of the opening; no world draw, no HUD.
    • Device removals / crashes: 0 / 0. GPU-time regression: not measured here.

    Not tested: the HLSL path (this is XCL_DIRECT_DXIL=1), a cold NVIDIA-dir wipe, the same runs on #2080/#2097, AMD or Intel, and a second sample per cache state.

    AI use: OpenCode, DeepSeek V4.1 Flash 1017 — ran the two 25-minute title runs, the 8-slice fill, and wrote this from XCL's logs. No game data attached.

  27. coolpersonnn commented on Nov 25, 2026

    @coolpersonnn

    Workstream 5 retest on 426a5a7

    I reran the one-hot guards for direct DXIL raw stores through root UAV windows. On the RTX 5090, median first-use CreateComputePipelineState time fell 5.0–33.6% on four of five compute records. The fifth rose 0.47%. The reduction for 4585e350d1b864e3 was 5.04%, compared with 0.4% in the earlier run. Earlier workstream 5 results

    Both clean 60-second retail runs reached the account picker and logged 30 presents per second over their final six seconds, with zero crashes or device removals. The startup pipeline trace showed zero builds for the five timed hashes. First-playable latency and in-game GPU time remain unmeasured.

    Per-shader results, benchmark setup, tests, and smoke output

    Setup

    Base 426a5a745db4d5e4b037449ede0b70cb342f5192, local head 5e502c50805e27fa1df1e833e413841f7f122503. Windows 11 Pro build 26300, Ryzen 9 9950X3D, 93.6 GiB usable RAM, NVIDIA GeForce RTX 5090 32 GB with driver 621.01, and AMD Radeon iGPU with driver 32.0.21045.29003 for the focused test. Rust 1.100.0 (0ef1bc386) and Windows SDK DXC/DXIL tools 1.8.2502.11. Benchmarks and smoke used release builds. Cargo tests used the test profile.

    Shader record hash Median driver build (ms) Change DXIL bytes DXIL instructions DXIL blocks Switches Peak process commit (MiB)
    2099a37cbf86d155 1235.111 → 820.162 -33.60% 102736 → 116300 12126 → 14586 2056 → 2548 330 → 166 605.45 → 597.20
    a4c70d5842b40e13 1787.287 → 1522.719 -14.80% 205528 → 218616 26094 → 28515 2847 → 3333 252 → 90 645.75 → 633.90
    715d367152768991 4587.626 → 3773.888 -17.74% 320216 → 333064 41939 → 44099 3659 → 4091 539 → 395 802.51 → 792.16
    4585e350d1b864e3 6204.557 → 5891.798 -5.04% 504524 → 515268 70141 → 71863 3998 → 4382 707 → 579 913.52 → 902.83
    56c0cd3b82a00c6e 5384.513 → 5409.724 +0.47% 484744 → 486028 65625 → 65823 2252 → 2294 306 → 292 1177.62 → 1161.53

    Each row is base → head on the RTX 5090. Local arrays were zero for all ten variants and the raw store count was unchanged within each pair. Peak process commit is the largest first-launch sample per variant and record. All 30 timed launches and 30 warm replays completed with zero crashes and device removals.

    ShaderCacheControl returned 0x887A002D, so NVIDIA's implicit caches remained enabled. XCL disk caches and cached pipeline blobs were bypassed by the harness. The harness timed NVIDIA CreateComputePipelineState in three paired first launches per hash with unused root layouts (7, 8, and 9 extra root constant DWORDs) and alternated base/head order. Each pair matched layout and used fresh executable copies. Same-layout warm replays took 0.892–3.341 ms. A byte-identical no-store control (777348c43857fdd2) took 346.192–359.047 ms on three new layouts and 0.851–0.968 ms on their warm replays.

    For GPU timing, the store fixture ran three paired trials per wave mode, each with 128 timed dispatches after eight warmups, and verified all 4,194,304 output dwords per trial. The median of the three run medians was 22.336 → 2.400 µs for wave32 and 22.592 → 6.880 µs for split-wave64. All runs reported zero device removals.

    Benchmark and test commands

    The local harness used four root UAV windows and the adapter's wave layout. Set XCL_ADAPTER=5090 and unset XCL_DIRECT_COMPACT and XCL_PER_LANE. The two harness executables were built from the same source against their respective XCL trees using separate target directories.

    cargo build --manifest-path $BenchManifest --release --locked --offline -j 8
    xcl-store-refresh-base.exe cache
    xcl-store-refresh-base.exe measure $Pack 777348c43857fdd2 normal 1 $ControlPrefix
    xcl-store-refresh-base.exe measure $Pack $Hash normal 1 $Prefix
    xcl-store-refresh-guards.exe measure $Pack $Hash normal 1 $Prefix
    xcl-store-refresh-base.exe gpu-time $Wave
    xcl-store-refresh-guards.exe gpu-time $Wave

    $Hash iterated over the table, $Prefix over 7–9, $ControlPrefix over 17–19, and $Wave over 32 and 64. The measure command was repeated in a separate process with the same executable and layout for the warm replay.

    The workspace build and tests used XCL_ADAPTER=5090, XCL_SAMPLE_RPF=$Pack, and an isolated XCL_DXIL_CACHE.

    cargo build --workspace --locked --offline -j 8
    cargo test --workspace --locked --offline -j 8 --no-fail-fast -- --test-threads=4 --nocapture

    The workspace build passed. Tests reported 1,240 passed, 4 failed, 46 ignored, 25 explicit GPU skip notices. All four failures were fuzz_validate_and_gpu seeds 70, 545, 1019, and 1507 at CreateComputePipelineState (0x8007000E). The command below on clean base with XCL_ADAPTER=5090 reproduced the same failures (0 passed, 4 failed, 0 ignored, 0 explicit GPU skip notices).

    cargo test -p xcl --lib --locked --offline -j 8 fuzz_validate_and_gpu -- --test-threads=1 --nocapture

    With XCL_ADAPTER=warp, the same retail pack, and a separate XCL cache, the head library suite reported 1,175 passed, 0 failed, 26 ignored, 311 explicit GPU skip notices.

    cargo test -p xcl --lib --locked --offline -j 8 -- --test-threads=4 --nocapture

    The focused store test reported 1 passed, 0 failed, 0 ignored, and 0 GPU skips on each of XCL_ADAPTER=5090 and XCL_ADAPTER=radeon.

    cargo test -p xcl --lib --locked --offline -j 8 raw_stores_in_root_windows_respect_exec_and_bounds -- --nocapture

    Regression run

    Both runs used XCL_ADAPTER=5090, XCL_DIRECT_DXIL=1, XCL_HEAP_WINDOWS=0, XCL_PSO_TRACE=1, and XCL_FRAME_DUMP=300 with separate empty XCL_DATA_ROOT and XCL_DXIL_CACHE directories. The NVIDIA implicit caches remained enabled and could reuse entries from earlier runs. The script sets XCL_NETWORK=0, XCL_RUN_SECONDS=60, and XCL_ACTIVITY=1. XCL_PRESS_AT was unset.

    cargo build -p xcl --release --locked --offline -j 8
    ./scripts/smoke.ps1 -Game $RetailTitleFolder -Seconds 60 -Xcl $ReleaseExe -OutDir $SmokeArtifacts

    Clean main

    xcl-smoke v1
    commit: 426a5a745db4d5e4b037449ede0b70cb342f5192
    gpu: NVIDIA GeForce RTX 5090
    title: a93b40d7
    seconds: 60
    exit: 0x0
    frames shown: 880 (PresentX 880)
    presents per 2 s (last 3): 60 60 60
    device removals: 0
    crashes: 0
    peak commit: 15404 MB
    

    Clean head

    xcl-smoke v1
    commit: 5e502c50805e27fa1df1e833e413841f7f122503
    gpu: NVIDIA GeForce RTX 5090
    title: a93b40d7
    seconds: 60
    exit: 0x0
    frames shown: 881 (PresentX 881)
    presents per 2 s (last 3): 60 60 60
    device removals: 0
    crashes: 0
    peak commit: 15236 MB
    

    The captures at frame 620 were byte-identical. The shader inventory logged all five timed hashes.

    AI use

    OpenAI Codex (GPT-6, exact variant unavailable) wrote the lowering and regression test, ran these measurements and checks, and drafted this report.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions