Skip to content

Recompiler: large compute programs call shared helpers instead of inlining them - #1901

Draft
SamG-Coder wants to merge 1 commit into
xcl-dev:mainfrom
SamG-Coder:recomp/shared-helpers
Draft

SamG-Coder wants to merge 1 commit into
xcl-dev:mainfrom
SamG-Coder:recomp/shared-helpers

Conversation

@SamG-Coder

Copy link
Copy Markdown

Part of #1269. Replaces draft #1867, which combined this with other changes. Large compute programs call one shared copy of the memory-window accessors, the split-wave64 exchange and the typed-format conversions instead of having DXC inline them at every use. On six retail compute programs of 1.3 – 6.7 MB HLSL, pipeline creation is 2.1 – 5.9× faster with the default memory windows and 1.13 – 3.7× faster with XCL_HEAP_WINDOWS=1, and the DXIL 4 – 28 % smaller (tables below).

What is in it

  • Em::finish takes the program's instruction count. From 1 024 instructions (compute and kernel mode), the memory-window accessors and the split-wave64 exchange functions are [noinline], with scalar parameters and out results, which SM 6.6 DXIL keeps as calls. Vector loads and stores go through one scalar _shared function per width.
  • From 256 instructions the typed-format helpers (fmt_value, fmt_pack_shared, st_bytes_shared) are [noinline] in the same way. fmt_comp is split so the conversion takes scalars; fmt_pack and st_bytes keep their signatures as wrappers. The store logic is unchanged.
  • Heap windows (XCL_HEAP_WINDOWS=1) keep their single access: only the switch form's accessors are outlined.
  • The EXEC bit test (lanebit) stays inline. As a [noinline] call it made the driver slower on every program measured (with heap windows, the 3.40 MB program: 5.83 s inline, 7.27 s as a call).
  • Test: gpu_large_compute_shares_wave_and_window_helpers checks that a small program stays inline, that a large one calls the shared accessors, that the outlined DXIL is smaller than the same source inlined, and that both memory windows and a vector load return the right values on the GPU.

Measurements (xcl shaders <pack> --measure-pso <record> --repeat 3: DXC, then CreateComputePipelineState with the driver cache off; main c4d37be against this PR on the same machine, one program at a time; a second pass agrees within 3 %)

Default memory windows (switch form):

HLSL DXIL main → PR DXC main → PR PSO median main → PR speed-up
1.30 MB 369 → 273 KB 2.49 → 1.56 s 4.11 → 1.45 s 2.8×
1.92 MB 460 → 338 KB 8.99 → 5.55 s 8.94 → 2.26 s 4.0×
2.73 MB 747 → 539 KB 6.09 → 4.27 s 11.84 → 3.48 s 3.4×
3.40 MB 850 → 690 KB 5.89 → 5.53 s 29.34 → 5.01 s 5.9×
4.21 MB 1 050 → 878 KB 8.07 → 8.28 s 42.41 → 8.66 s 4.9×
6.72 MB 1 642 → 1 457 KB 25.28 → 18.95 s 39.53 → 18.71 s 2.1×

XCL_HEAP_WINDOWS=1:

HLSL DXIL main → PR DXC main → PR PSO median main → PR speed-up
1.30 MB 319 → 250 KB 2.30 → 1.59 s 4.43 → 1.59 s 2.8×
1.92 MB 353 → 330 KB 7.47 → 5.82 s 3.48 → 2.37 s 1.5×
2.73 MB 640 → 498 KB 5.91 → 4.41 s 14.56 → 3.90 s 3.7×
3.40 MB 663 → 617 KB 5.62 → 4.31 s 6.64 → 5.87 s 1.13×
4.21 MB 832 → 796 KB 6.74 → 6.11 s 9.29 → 7.00 s 1.3×
6.72 MB 1 362 → 1 093 KB 20.33 → 18.28 s 42.76 → 13.47 s 3.2×

DXC is slower on one of the twelve (4.21 MB, default windows: +3 %).

Tested

  • hardware (GPU + driver, CPU), Rust version, debug / release: NVIDIA GeForce RTX 5080, driver 616.64 (32.0.16.1664), AMD Ryzen 7 9800X3D, Windows 11 (10.0.26300), Rust 1.95.0, release
  • cargo test --workspace -- --test-threads=4: 960 passed, 0 failed, 43 ignored (SKIPPED GPU tests: 12 tests, 22 cases: the wave64 cases of gpu::recomp::lower / lower_dxil and gpu_wave32_program_in_wave64_hardware, gpu_geometry_wave32_prefix_count_over_a_mask for no wave64 on this GPU; heap_window_out_of_memory_falls_back_to_the_switch_form for no heap windows). Release build, after cargo build --workspace --release.

Regression run

main:

PR:

Not tested

  • No scripts/smoke.ps1 regression run yet (main or PR); required before this leaves draft.
  • Only an NVIDIA GPU with 32-lane waves (split wave64). No AMD or native wave64 runs, and no Linux / vkd3d-proton runs.
  • Pipeline times are for six programs from one pack, measured one at a time; no title run with the change.

AI use

  • Claude Code (Claude Opus 5.5): split this change out of the author's work, ported it onto current main, found and removed the lanebit slowdown by measuring each part on its own, ran the tests and measurements, and wrote this description.

…ining them

DXC inlines every helper before it optimises, so a large compute program
gets a copy of the memory-window switch, the split-wave64 exchange and
the typed-format conversions at every use, and the driver compiles all
of them. From 1 024 instructions (256 for the format helpers) these stay
[noinline] with scalar parameters, which SM 6.6 DXIL keeps as calls.
Heap windows keep their single access. The EXEC bit test stays inline:
as a call it made the driver slower.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@HKEY-Funk-Machine

Copy link
Copy Markdown

@SamG-Coder the device suspension I reported on #1867 (#1867 (comment)) is still there on #1901 at 5064119, on an RX 9070 (RDNA4). It looks tied to the outlined switch-form window accessors: with XCL_HEAP_WINDOWS=1, where this PR leaves the accessors inline, the same program builds, and its DXIL is identical to the base's.

62b584e061c05fc5 c4d37be (base) 5064119 (this PR)
switch windows (default, 4) 197 280 B DXIL, built in 6.2 s Unknown pointer operation encountered during ParseAddress, then 0x887A0005 (device suspended)
XCL_HEAP_WINDOWS=1 158 700 B, built in 3.8 s 158 700 B, built in 3.8 s

Tested

  • 5064119 and its base c4d37be, release. One local-only change in measure_pso: no Windows Developer Mode here, so ShaderCacheControl(DISABLE) fails (0x887A002D). I made that a warning and ran each measurement under an xcl.exe copied to a new name, which gives the AMD driver a cold cache.
  • xcl shaders <pack>/shaders.rpf --measure-pso 62b584e061c05fc5 --repeat 1, one process each.
  • AMD Radeon RX 9070 (RDNA4, native wave64, so no split-wave64 exchange), driver 32.0.32015.7029, Ryzen 9 7945HX3D, 32 GB, Windows 11 Pro 26300, DXC 1.9.2602.17.

Not tested

AI use: Claude Code (Claude Opus 5.5) ran the measurements and wrote this comment.

@WebIdentity1

Copy link
Copy Markdown
Contributor

Synthetic isolation for the outlined switch-window accessors on an RTX 3090, exact #1901 head 5064119216a6443dead457f6a3e16cdf58bd29a8 and parent c4d37bec1bb4286eb373aea963404a23f13401fa.

I padded the existing gpu_memory_windows_above_4_gib program with 1,024 S_NOPs so this PR takes its large-compute outline path. The test already checks window-1 scalar/buffer/global reads, window-0/1 writes, and a window-1 global atomic. The overlay also accepts either switch syntax and asserts that the PR's switch form emits [noinline] void xcl_mInterlockedAdd(...); its heap form must not. This is a small public fixture an AMD tester can run to see whether a simple outlined atomic/accessor program triggers the reported ParseAddress failure or whether that needs the larger program's structure.

Tested — native Windows 10 19045, RTX 3090 driver 591.74, Ryzen 7 7800X3D, Rust 1.98.1 MSVC, DXC 1.8.2502.11; XCL_ADAPTER=3090, HLSL path, default split-wave64 selection. Each snapshot was 303 source files and matched its SHA-256 manifest before/after. Cargo logs show a fresh Compiling xcl for each snapshot.

  • cargo test --locked -p xcl --lib gpu_memory_windows_above_4_gib -- --test-threads=1 --show-output: parent 1/0/0; PR 1/0/0. On the corrected PR overlay, outlined atomic: true, GPU result 1/0/0.
  • cargo test --locked -p xcl --lib gpu_memory_windows_from_the_heap -- --test-threads=1 --show-output: parent 1/0/0; PR 1/0/0. On the corrected PR overlay, outlined atomic: false, GPU result 1/0/0.
  • The PR's gpu_large_compute_shares_wave_and_window_helpers: 1/0/0 on the RTX 3090.

The added test lines on #1901's tests.rs are:

-    let p = prog(&refs);
+    let mut p = encode("S_NOP", "ENC_SOPP", &[], None).unwrap().repeat(1024);
+    p.extend(prog(&refs));
     let one = translate(&p, &Options::default()).unwrap();
@@
-    assert_eq!(t.hlsl.contains("switch (xcl_w)"), !heap, "heap windows: no switch over windows");
+    assert_eq!(t.hlsl.contains("switch (xcl_w)") || t.hlsl.contains("switch (window)"), !heap, "heap windows: no switch over windows");
+    let outlined_atomic = t.hlsl.contains("[noinline] void xcl_mInterlockedAdd(");
+    assert_eq!(outlined_atomic, !heap, "large switch-form program should outline the atomic accessor");
+    println!("outlined atomic: {outlined_atomic}");

Not tested: AMD, the failing retail shader, full suite, retail smoke, cold compilation time or memory. These passes show this small outlined program works on the 3090; they do not explain or dismiss the RX 9070 device suspension. I corrected and reran an initial diagnostic that looked for the wrong (uint) helper return type; only the void assertion above proves the outlined path.

AI use: Codex desktop (GPT-6) prepared the synthetic test overlay, ran the paired Windows checks and drafted this report from retained logs.

@Melow-code Melow-code left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The 2-6x PSO creation speedup is significant. The RDNA4 device suspend on outlined switch-form accessors is the blocker — the driver may not handle cross-function LDS access correctly with noinline. Worth checking if the suspend reproduces with only the LDS helpers outlined, leaving the typed-format ones inlined.

@CharlyRien

Copy link
Copy Markdown

Run time on an RTX 3090 (32-lane waves, split wave64): the programs build faster but run 1.7 – 2.7× slower, because the split-wave64 exchange helpers are now calls. With those inline again the run time is back to the base's.

The description measures DXC and pipeline creation. This adds the GPU time of the dispatches themselves, same trees.

Setup

  • Trees: main c4d37be (base) and c4d37be + this PR's commit 5064119. Each carries only a local test harness (not for upstream): it builds the memory windows as the runtime does (VirtualAlloc, OpenExistingHeapFromAddress, placed buffers; views from the descriptor heap with XCL_HEAP_WINDOWS=1, root UAVs otherwise), runs one translated program with given inputs and times each Dispatch with timestamp queries.
  • Because c4d37be declares every compute memory window globallycoherent, and that alone costs seconds per dispatch on the imported host heap (see Recompiler: emit globallycoherent on compute memory windows only when needed #1850 and GPU heaps in host memory: residency, CPU readback and wait-release data from a PS5 relinker #1640), the harness removes the qualifier from the HLSL of both trees. Otherwise the code shape cannot be seen in the timings.
  • Program A: 1 333 instructions, one captured world-load dispatch of a retail title replayed with its real inputs (32x32x2 groups of 4x4x4, loops, 50 ballot and 75 read-lane exchange sites). Program B: 4 110 instructions, synthetic inputs (constant buffer filled, textures zero, 1 024 groups), so its timings are synthetic.
  • GPU time: median of 7 dispatches, two separate runs, nothing else on the GPU. Pipeline time: one CreateComputePipelineState of a copy that differs by a never-taken store, so the driver cache misses (ShaderCacheControl(DISABLE) is refused without Developer Mode).
  • RTX 3090 24 GB, driver 616.56, Ryzen 9 5950X, Windows 11 22631, DXC 1.9.2602.17, release.

Results

program windows GPU ms, base (run 1 / run 2) GPU ms, PR same output pipeline s, base → PR DXIL KB, base → PR
A (real inputs) heap 11.10 / 11.13 25.59 / 23.39 yes 1.66 → 0.86 108 → 71
A (real inputs) switch 12.01 / 11.30 32.31 / 28.33 yes 2.76 → 1.07 138 → 86
B (synthetic) heap 0.732 / 0.731 1.270 / 1.269 yes (weak: one word written) 6.1 → 3.4 309 → 175
B (synthetic) switch 0.735 / 0.734 1.393 / 1.396 yes (weak) 11.3 → 2.6 403 → 194

Which helper costs the time (program A, [noinline] removed from one group at a time in the PR's HLSL)

heap windows switch windows
PR as it is 25.6 / 23.4 32.3 / 28.3
split-wave64 exchange helpers inline again 11.7 / 10.6 26.3 / 22.4
window accessors inline again (already inline) 26.9 / 25.1
both inline 12.4 / 12.0
  • Heap form: the description says heap windows keep their single access, which is true of the accessors, but the exchange helpers (xcl_x_ballot_shared, xcl_x_meet, …) go out of line from 1 024 instructions in both forms, and that is the whole slowdown there.
  • Switch form: both groups cost about the same, and only putting both back inline restores the base time.
  • Within the exchange group on the heap form: only xcl_x_ballot_shared inline gives 13.9 / 13.5 ms; only xcl_x_meet left out of line 15.6 / 13.6 ms.

So on 32-lane GPUs the trade here is about half the pipeline-creation time once, against about twice the GPU time of every dispatch of a program that loops. A threshold on the number of exchange sites inside loops, or keeping the exchange inline and outlining only the accessors and the format helpers, would keep most of the build gain; I have not measured those variants.

One more thing for the cache: the typed-format code at the top of every program is rewritten for all sizes, so the HLSL of every compute program of the pack changes, including the quarter of them under 256 instructions. A translated-shader cache is rebuilt entirely.

Not tested

  • AMD or any native wave64 GPU (no split form there, so the exchange helpers do not exist).
  • Real inputs for any program other than A; the typed-format helpers' run-time effect (neither program uses them).
  • Run time with globallycoherent kept: not measured for the PR (program A takes about 7.4 s per dispatch on the base that way, which hides everything else).
  • Pipeline time with the driver cache really off.
  • Recompiler: large compute programs share repeated code with DXC and the driver #1867's DXIL for program A is byte-identical to this PR's in both forms, and it timed the same.

AI use: Claude Code (Claude Fable 5.2 coordinating, Claude Opus 5.5 for the port of the harness and the measurements) ran this and drafted the report.

@oni-swr

oni-swr commented Nov 24, 2026

Copy link
Copy Markdown
Contributor

RDNA3 data point for #1901 at 5064119216a6443dead457f6a3e16cdf58bd29a8 vs parent c4d37bec1bb4286eb373aea963404a23f13401fa on an RX 7800 XT: the same device suspension (0x887A0005) reproduces on RDNA3 — including on this PR's own GPU unit test and under XCL_HEAP_WINDOWS=1 whenever any [noinline] internal DXIL function remains.

Unlike RDNA4's Unknown pointer operation encountered during ParseAddress, the RDNA3 driver prints unsupported to stdout/stderr right before CreateComputePipelineState returns 0x887A0005.

Results

PR unit test (gpu_large_compute_shares_wave_and_window_helpers, added in 5064119, not present on c4d37be):

  • cargo test --release -p xcl --lib gpu_large_compute_shares_wave_and_window_helpers -- --test-threads=1 --nocapture (XCL_ADAPTER="7800 XT"): FAILED — prints unsupported, then panics at CreateComputePipelineState: The GPU device instance has been suspended... (0x887A0005).

Three retail compute records (xcl shaders <record>.bin --measure-pso <hash> --split 0 --windows 4 --repeat 3, one process per measurement, 5 s wait after each device suspension):

record windows c4d37be (base) 5064119 (this PR) PR internal DXIL funcs (dxc -dumpbin)
9136eb6afa6d8a2e (postfx_aces:CS_BakeACES...) switch (4) 169 052 B DXIL, 1.56 s DXC, 1.424 s median (1.373–1.477 s) 135 408 B DXIL, unsupported → 0x887A0005 3 (xcl_mLoad, xcl_mLoad4_shared, xcl_loadx4_shared)
9136eb6afa6d8a2e XCL_HEAP_WINDOWS=1 134 988 B DXIL, 1.30 s DXC, 0.983 s median (0.980–0.992 s) 134 988 B DXIL, 1.83 s DXC, 1.043 s median (0.937–1.203 s) 0 (@main only)
d10c0a5491f60cad (indirect_light_probes:CS_IrradianceCache...) switch (4) 396 216 B DXIL, 5.74 s DXC, 6.576 s median (6.356–6.770 s) 278 284 B DXIL, unsupported → 0x887A0005 11 (xcl_m*, xcl_loadx4_shared, fmt_value, st_bytes_shared, fmt_pack_shared)
d10c0a5491f60cad XCL_HEAP_WINDOWS=1 325 268 B DXIL, 5.08 s DXC, 5.190 s median (5.036–5.249 s) 284 652 B DXIL, unsupported → 0x887A0005 3 (fmt_value, st_bytes_shared, fmt_pack_shared)
de83041b451429d1 (sr_tracing:CS_ResolveGBuffer_Opaque) switch (4) 526 584 B DXIL, 6.55 s DXC, 18.548 s median (17.323–21.435 s) 418 216 B DXIL, unsupported → 0x887A0005 4 (xcl_mLoad, xcl_mLoad4_shared, xcl_loadx4_shared, fmt_value)
de83041b451429d1 XCL_HEAP_WINDOWS=1 424 892 B DXIL, 6.28 s DXC, 10.588 s median (10.136–10.712 s) 385 092 B DXIL, unsupported → 0x887A0005 1 (fmt_value)

DXIL validation & isolation finding

  • All six PR DXIL containers pass IDxcValidator (dxil.dll 1.8.2502.11, hr=0x0) and disassemble cleanly with dxc -dumpbin.
  • de83041b451429d1 with XCL_HEAP_WINDOWS=1 isolates the failure beyond switch-form memory windows and out pointer parameters: dxc -dumpbin shows its only non-entry function is define internal fastcc i32 @"\01?fmt_value@@YAIIII@Z"(i32 %v, i32 %w, i32 %ty) — a pure scalar arithmetic helper with no i32* out parameters and no resource accesses, invoked via call fastcc i32 — and it still triggers unsupported → 0x887A0005.
  • The only PR variant that built (9136eb6afa6d8a2e with XCL_HEAP_WINDOWS=1) had zero internal functions in DXIL (same size as c4d37be). On the switch-window variants, the outlined vector/atomic accessors (xcl_mLoad4_shared, xcl_loadx4_shared, xcl_mLoad3_shared, xcl_mInterlockedAdd) also emit i32* noalias nocapture dereferenceable(4) out parameters.

Tested

  • Commits: c4d37bec1bb4286eb373aea963404a23f13401fa (base) and 5064119216a6443dead457f6a3e16cdf58bd29a8 (PR Recompiler: large compute programs call shared helpers instead of inlining them #1901 head), release builds (cargo build --release --bin xcl -j 4 and cargo test --release -p xcl --lib).
  • Local-only cache workaround: patched ShaderCacheControl(DISABLE) failure in measure_pso to a warning on both trees and ran each measurement from a freshly copied and renamed xcl.exe to ensure a cold AMD driver cache (ShaderCacheControl(DISABLE) actually succeeded without warning on this machine, and all 3 repeats per run measured cold).
  • Hardware & software: AMD Radeon RX 7800 XT (RDNA3, native wave64, --split 0), driver 32.0.31035.1003 (2026-07-24), AMD Ryzen 7 5700X3D, 64 GB RAM, Windows 11 Pro 26200 (10.0.26200), Rust 1.100.0 (0ef1bc386), DXC dxcompiler.dll 1.8.2502.11 / dxil.dll 1.8.2502.11 (Windows SDK 10.0.26100.0).

Not tested

  • Full cargo test --workspace, scripts/smoke.ps1 / retail title runs, --split 1 (split-wave64), other AMD driver versions, or NVIDIA / Intel / Linux.

AI use: Antigravity (Gemini 4 Neon) built both trees, ran the measurements and wrote this comment.

@Rednaxeh

Copy link
Copy Markdown
Contributor

RDNA3 run of this PR, since the numbers in the description are NVIDIA's: on an RX 7800 XT the device is removed within the first 2–3 s, twice, with this commit; main alone runs 300 s.

Setup: AMD Radeon RX 7800 XT 16 GB (driver 32.0.32029.2010), Ryzen 7 7800X3D, 32 GB, Windows 11 Pro 26300, Rust 1.100.0, DXC 1.9.2602.17, release, retail title, XCL_NETWORK=0 XCL_ACTIVITY=1 XCL_PSO_TRACE=1, warm DXIL cache for main, empty for this PR's translations (its DXIL is new).

tree result
main 689f2db, same command, 300 s runs to its end: 1 364 frames, 0 device removals, 0 PSOs refused
this PR's head 5064119 on its base c4d37be black window from the start; the first CreateGraphicsPipelineState answers 0x887a0005 at 3.4 s (the device already gone), D3D12 device removed: 0x887a0020 logged at 30.7 s
5064119 cherry-picked on main 20cf130 (2daacb6 locally), XCL_DRED=1 D3D12 device removed: 0x887a0020 at 2.045 s, DRED page fault at GPU VA 0x0; allocations there: []; recently freed: [], then the title's own C++ exception (0xe06d7363) and exit. 30 driver compiles before it, the largest a 582 060 B compute program "finished" in 44 ms.

So the driver takes the outlined DXIL (no PSO is refused) and the GPU faults at address 0 on the first work that runs it; I cannot tell from here which program. 0x887a0020 is DXGI_ERROR_DRIVER_INTERNAL_ERROR. The maintainer's merge run is on RDNA4 with a near driver, so this is worth a look before that. Logs of both runs kept; I can post them, and rerun with a change.

Not tested: the suite on this tree; XCL_HEAP_WINDOWS=1; other AMD drivers.

AI use: Claude Code (Claude Fable 5.1) built the trees, read the logs and wrote this; the runs were mine.

gustavsi added a commit to gustavsi/xcl that referenced this pull request Nov 25, 2026
…ders)

Integrates upstream PR xcl-dev#1901 (5064119) so large compute shaders call shared [noinline] helpers instead of inlining them, reducing DXIL size and compile time while preserving xcl-dev#1414's zero-for-missing-channel rule in fmt_comp.
@DavidM1911

Copy link
Copy Markdown
Contributor

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

Thanks!

@milesah3ad

Copy link
Copy Markdown

Run time on Blackwell (RTX 5080, 32-lane waves, split wave64): on these synthetic programs the GPU time stays within 5 % of the base or drops, even with exchanges inside a loop. Driver builds are 6–28× faster in the switch form, and every output matches the base bit for bit. This adds a second NVIDIA generation next to @CharlyRien's RTX 3090 numbers. It doesn't reproduce his slowdown, so the cost may depend on the GPU generation or on his program's shape (50 ballots and 75 lane reads in loops, real inputs), which these programs don't have.

Setup: RTX 5080 16 GB, driver 621.24, Ryzen 7 9800X3D, Windows 11 Pro 26300, rustc 1.100.0, DXC 1.9.2609.5, release. Trees: this head 5064119 and its parent c4d37be, each with the same local example (not for upstream). The example generates split-wave64 compute programs (128 threads, 4 memory windows) from @QemmHD's #156 generator, with every memory access at the thread's own address so one group's output is deterministic. Shapes:

  • base: a divergent if every 4th round, which is an EXEC ballot
  • wave: a v_readlane every round
  • atomic: a returning atomic every round
  • loop: a uniform 4-trip loop around a load
  • loopx: the same loop with a v_readlane and a ballot (v_cmp + s_and_saveexec_b64 + restore) inside it, every trip

For each program, in this order:

  • DXC
  • a cold CreateComputePipelineState in a fresh process (ABI root signature, new seed; the two trees' DXIL differs, so no driver-cache hits)
  • one 1-group dispatch, whose output words are hashed and compared between trees
  • the median of 30 timed 64-group dispatches (runner::dispatch_timed, in video memory, so globallycoherent costs nothing here)

Trees interleaved per program. All programs pass the 1,024-instruction threshold: the PR's HLSL has 42 [noinline] functions in the switch form and 7 in the heap form; the parent's has none.

program (instr.) windows DXIL KB base → PR driver s base → PR GPU ms base → PR same output
base, 250 (3,129) switch 141 → 48 4.37 → 0.45 0.293 → 0.290 yes
loop, 250 (3,346) switch 150 → 57 4.74 → 0.57 0.322 → 0.323 yes
loopx, 250 (3,594) switch 178 → 79 4.43 → 0.70 0.343 → 0.349 yes
wave, 250 (3,879) switch 229 → 53 5.80 → 0.50 0.265 → 0.197 yes
atomic, 250 (3,879) switch 196 → 82 7.55 → 0.77 0.189 → 0.191 yes
base, 1000 (12,509) switch 564 → 182 47.4 → 4.0 1.161 → 1.168 yes
loop, 1000 (13,384) switch 610 → 204 65.6 → 6.2 1.250 → 1.311 yes
loopx, 1000 (14,384) switch 736 → 226 163.3 → 5.9 1.358 → 1.375 yes
wave, 1000 (15,509) switch 954 → 200 90.7 → 5.5 1.061 → 0.781 yes
atomic, 1000 (15,509) switch 809 → 317 120.6 → 13.4 0.748 → 0.757 yes
base, 250 heap 83 → 68 0.45 → 0.28 0.446 → 0.380 yes
loop, 250 heap 98 → 84 0.51 → 0.36 0.449 → 0.401 yes
loopx, 250 heap 117 → 81 1.83 → 0.80 0.480 → 0.424 yes
wave, 250 heap 174 → 74 1.85 → 0.36 0.262 → 0.198 yes
atomic, 250 heap 114 → 99 0.59 → 0.40 0.183 → 0.185 yes
base, 1000 heap 328 → 267 2.96 → 1.80 1.785 → 1.509 yes
loop, 1000 heap 354 → 293 3.91 → 2.80 1.787 → 1.608 yes
loopx, 1000 heap 473 → 316 10.2 → 5.1 1.933 → 1.674 yes
wave, 1000 heap 716 → 289 17.6 → 2.7 1.050 → 0.755 yes
atomic, 1000 heap 462 → 392 4.49 → 3.14 0.727 → 0.732 yes
  • GPU time: within ±5 % everywhere, except where the PR is faster: −10 to −28 % on wave and on base / loop / loopx with heap windows. The largest base-to-PR increase is loop 1000 switch at +4.9 %.
  • Driver time: 6–28× faster with switch windows (163 s → 5.9 s for loopx 1000) and 1.4–6.4× with heap windows.
  • PR head, cargo test -p xcl --lib -- gpu::recomp --test-threads=4: 262 passed, 0 failed, 18 ignored (SKIPPED: wave64-only cases, and the direct path's refused f16/cvt forms, as on main). gpu_large_compute_shares_wave_and_window_helpers passes on its own.

So on this GPU the trade that @CharlyRien measured on Ampere, half the build time against double the run time, isn't visible for these shapes. Whether his program A behaves the same on Blackwell is the open question. A run of that captured dispatch on an RTX 40 or 50 would settle whether a threshold on exchange sites in loops is needed per generation or everywhere.

Not tested: retail programs, real inputs (these use zero-filled memory and own-slot accesses, so their memory traffic is lighter than a real program's), the coherent window or globallycoherent on host memory, AMD (where #1901 has device-removal reports), the title, release-to-release repeats beyond one interleaved run per program.

AI use: Claude Code (Claude Opus 5.5) wrote the probe, ran it on the machine above and wrote this report. I checked the numbers against the logs.

@zohaiblazuli

Copy link
Copy Markdown
Contributor

RTX 3060 12 GB, a larger program than the six in the description (7.05 MB HLSL, 25,107 instructions): pipeline creation 1.26× faster with the default windows, 1.04× with heap windows.

Head 5064119 against its parent c4d37be, each built clean in its own worktree, release. Same machine, one program, run one after the other.

Setup: NVIDIA GeForce RTX 3060 12 GB (driver 617.42, 32-lane waves, split wave64), Intel i5-14600K, Windows 11 build 26300, rustc 1.94.0, DXC 1.8.2502.11 from the Windows SDK (10.0.26100.0).
Command: xcl shaders shaders.rpf --measure-pso 062468c09af883b9 --repeat 2 (driver cache off).

windows DXIL base → PR DXC base → PR PSO median base → PR
default (switch) 1,681,276 → 1,491,648 B 31.2 → 20.8 s 34.12 → 27.05 s
XCL_HEAP_WINDOWS=1 1,394,628 → 1,119,692 B 23.4 → 21.1 s 23.18 → 22.26 s

The two runs of each PSO measurement agreed within 1 %.

Not tested: run time of the dispatches (see @CharlyRien's 3090 numbers), AMD, a title run with this change, DXC 1.9.

Written with Claude Code (Claude Opus 5.5) from runs on this machine.

@brandostrong

brandostrong commented Nov 25, 2026 •

Copy link
Copy Markdown
Contributor

Ada (RTX 4090) data point: the build win is bigger on the title's own programs than the description shows, and the run-time cost @CharlyRien measured on Ampere reproduces here — but only in the split-wave64 exchange helpers. A knob that keeps those inline keeps both, and I measured it. The PR does not merge into current main (5064119 on 689f2db4, mergeable: false); the rebase onto 568e7db touches only crates/xcl/src/gpu/recomp/tests.rs, where the added test appends after another test's successor, and every number below is from that rebase (afbc413).

Cold driver compile, the title's own compute outliers, HLSL path (XCL_DIRECT_DXIL unset, ShaderCacheControl(IMPLICIT_DRIVER_MANAGED | IMPLICIT_D3D_CACHE_FOR_DRIVER, DISABLE), fresh XCL_DXIL_CACHE per tree, one CreateComputePipelineState each, --test-threads=1):

record tree DXIL instructions phis dx.op calls DXC driver
ef008c0f04b6261a 568e7db 1 121 012 B 141 958 10 388 16 866 21.4 s 75.525 s
ef008c0f04b6261a afbc413 (this PR rebased) 917 068 B 125 949 6 626 7 021 20.0 s 19.647 s
2d2bbb32f64e4801 568e7db 1 410 776 B 175 125 12 208 22 026 40.2 s 132.446 s
2d2bbb32f64e4801 afbc413 1 131 876 B 155 927 7 312 7 927 28.5 s 40.135 s
e7784c44a8db17d7 568e7db 362 168 B 48 808 3 636 5 070 6.3 s 8.020 s
e7784c44a8db17d7 afbc413 270 684 B 39 085 2 473 2 071 3.5 s 3.182 s
e1453fc963ba30e7 568e7db 272 432 B 37 421 2 816 3 820 5.9 s 4.932 s
e1453fc963ba30e7 afbc413 196 096 B 28 278 1 836 1 329 3.3 s 3.027 s

Driver time 1.63 – 3.84× faster across the four, with the biggest factor on the two largest. The asymmetry is the point: on ef008c0f, −11 % instructions and −18 % bytes bought −74 % driver time, because what the driver is handed stops containing a copy of the window switch and the typed-format chain at every use site (dx.op calls −58 %, phis −36 %). The 568e7db leg of the three smaller records ran alongside a build, so it is being rerun with nothing else on the machine; the afbc413 legs were alone.

These are not harness-only numbers: a 180 s run of the title on this rig with the implicit caches cold logs its own cold compute compiles at the same sizes and the same order of magnitude — console CS (1 121 012 B DXIL, 89 977 ms, console CS (362 168 B DXIL, 12 282 ms, console CS (272 432 B DXIL, 8 478 ms, which are ef008c0f, e7784c44 and e1453fc9 by DXIL size. The 90 s is a stall the player waits through.

The same four records measured with XCL's own tool, xcl shaders <pack> --measure-pso <hash> --repeat 1, one process per record, XCL_DXIL_CACHE wiped per tree, %LOCALAPPDATA%\NVIDIA\DXCache emptied before each record, the tool's own ShaderCacheControl disable, XCL_DIRECT_DXIL unset:

record 568e7db DXIL / DXC / driver afbc413 DXIL / DXC / driver ratio
ef008c0f04b6261a 1 121 012 B / 19.337 s / 95.823 s 917 068 B / 14.960 s / 13.899 s 6.90×
2d2bbb32f64e4801 1 410 776 B / 34.601 s / 117.757 s 1 131 876 B / 21.451 s / 19.650 s 5.99×
e7784c44a8db17d7 362 168 B / 8.987 s / 9.926 s 270 684 B / 3.225 s / 2.876 s 3.45×
e1453fc963ba30e7 272 432 B / 5.968 s / 7.936 s 196 096 B / 3.423 s / 1.919 s 4.14×

Same DXIL bytes as the harness table above, bigger ratios — this is the pairing I would keep if only one were quoted, and it is a command a reviewer can run. The same tool with XCL_OUTLINE_EXCHANGE=0 returns byte-identical DXIL for all four (917 068 / 1 131 876 / 270 684 / 196 096 B) at 13.484 / 20.239 / 5.929 / 2.119 s, straddling the outlined legs; the 2× spread on e7784c44 for identical bytes is the noise floor on the smaller records.

What the class looks like. Exporting the HLSL of the ten largest compute programs of this title that have no driver blob (15 011 KB down to 4 461 KB of HLSL) and counting helper call sites: eight of the ten have no split-wave64 exchange sites at all (xcl_x_ballot, xcl_x_meet, xcl_x_rla_* all zero) and 318 – 467 xcl_mLoad sites plus ~205 – 237 fmt_comp sites; the two exceptions are both of the shadow-cascade family (73fb752d7f62c3a5 1 030 ballot + 109 lane-read sites, 062468c09af883b9 982 + 55). The largest, 95cc13288a27a96e, is its own case: 7 561 fmt_comp sites, which is why its DXIL is 10.9 MB on main. @zohaiblazuli's RTX 3060 report above is one of those two (062468c09af883b9, 1.68 → 1.49 MB, PSO 34.1 → 27.1 s), so the program with the exchange sites is also the one where the build win is smallest — 1.26× there against 1.63 – 3.84× on the four above.

Why this class matters right now: #2120 reroutes compute programs whose HLSL exceeds 8 MiB, which is two records of this title's set (56c0cd3b82a00c6e, 95cc13288a27a96e). The reports there name what is left as the blocker — 590cef5cfe51c7ac (1.2 MB, 89 s), b8755fc12d3163fc (1.0 MB, 53 s), b7a408ccdd229979 (1.1 MB, unfinished) — and those are this class: HLSL under 8 MiB, so they stay on this path and this PR is what changes them.

GPU time of the same program, both trees (a 32 768-iteration loop, 2^18 threads, timestamps, median of 9, 1 024 S_NOPs so both trees' threshold state is the same and the only difference is inline vs [noinline]):

form base this PR ratio
wave32, one mask per iteration 7.323 ms 6.816 ms 0.93×
wave32, mask + readfirstlane 8.188 ms 7.569 ms 0.92×
split wave64, one mask per iteration 7.954 ms 8.091 ms 1.02×
split wave64, mask + readfirstlane per iteration 24.522 ms 42.510 ms 1.73×

So on Ada the window-accessor and format outlining is free to slightly positive, and the cost is in xcl_x_meet / xcl_x_ballot / xcl_x_rla_* going out of line — the same helper group @CharlyRien isolated on Ampere, at 1.73× instead of 1.7–2.7×. Blackwell (@milesah3ad) does not show it, so this looks like a per-generation cost on the halves' rendezvous, not a shape artifact.

The cost this PR pays on a title that is already warm. The typed-format prelude is rewritten for every compute program (the XCL_FORMAT_FN marker is substituted with nothing for small programs, but fmt_comp is split into fmt_offset / fmt_value / fmt_one either way), so the HLSL of every compute program changes, including the ones below both thresholds. Everything downstream of the HLSL is keyed by content, so on this machine the whole stack for the title goes cold with it: 3.6 GB of translated DXIL (XCL_DXIL_CACHE), 2 204 driver blobs / 883 MB (driver_cache, named fnv64(dxil)-len-flags.pso), and 453 files / 12 GB in %LOCALAPPDATA%\NVIDIA\DXCache. A first run after taking this PR pays all of that, and #2096's manifest / milestone-AOT work has to regenerate its blob set after it. That is a one-off, and the 1.6 – 3.8× above is what it buys per pipeline afterwards, but it is the cost and it should be in the record.

The variant @CharlyRien suggested and nobody has measured: keep the split-wave64 exchange helpers inline and outline only the window accessors and the format conversions. One line in Em::finish — self.x64_prelude(&mut h, outline && outline_exchange()), with XCL_OUTLINE_EXCHANGE=0 selecting it, so one build measures both forms. Same tree, same binary, only the environment differs; the same loop as above:

form exchange outlined (this PR) exchange inline (=0) 568e7db
wave32, one mask per iteration 7.058 ms 7.235 ms 7.323 ms
wave32, mask + readfirstlane 7.781 ms 7.940 ms 8.188 ms
split wave64, one mask per iteration 8.480 ms 7.632 ms 7.954 ms
split wave64, mask + readfirstlane per iteration 42.909 ms 24.894 ms 24.522 ms

So the inline form gives back the whole run-time cost — 1.015× main instead of 1.75× on the case that regressed, and it is at or below main on the other three — while keeping the outlining that buys the compile win. For these four records it costs nothing at all on the build side either: with the exchange inline the DXIL is byte-identical to this PR's (917 068 / 1 131 876 / 270 684 / 196 096 B, same instruction, phi and dx.op counts), because none of them contains an exchange site — the only thing the switch changes is the HLSL of programs that read lanes. Cold driver compiles of the same four with the exchange inline: 20.668 / 36.926 / 5.391 / 3.178 s, against 28.608 / 26.553 / 3.066 / 3.474 s for the same bytes in the previous leg of the same binary — the spread between two runs of identical DXIL on this machine, which is the variance any single number here carries.

On the one program of the ten that does read lanes the switch is not free, and it goes the other way. 73fb752d7f62c3a5 (1 030 ballot + 109 lane-read sites), same tree, only the environment differing, cold driver each leg:

form DXIL instructions phis switches dx.op DXC driver
568e7db 1 933 172 B 236 547 16 902 1 826 30 602 cache hit 63.400 s
exchange outlined (this PR) 1 706 500 B 219 360 6 787 6 12 198 55.8 s 55.401 s, 60.075 s
exchange inline (XCL_OUTLINE_EXCHANGE=0) 2 075 296 B 260 182 12 066 6 18 951 138.8 s 68.295 s

So on the program that has the exchange sites, keeping the exchange inline gives the outlining back and then some: 21 % more DXIL and 14 – 24 % more driver time than the outlined form, 7 % more DXIL and 8 % more driver time than 568e7db, and 2.5× the DXC time of the outlined form. Outlining the accessors and the format conversions still removes the 1 826 duplicated window switches either way (6 left); what the inline rendezvous adds back is bigger than what the outlining takes off at 1 030 sites. The knob is a per-class decision, not a free setting: byte-identical and free on the eight programs with no exchange sites, and on the two with them it trades about 1.1× of build time for the 1.73× of dispatch time. (568e7db's DXC time for this record is a cache hit from an earlier run and is being redone with xcl shaders --measure-pso on all three trees; the two cold legs above are the same tree and are comparable.)

Measurement conditions worth stating: each pair was measured under the same process layout (the ef008c0f pair had that program alone in the process, the other three were the first program of their process), and the same DXIL has been timed at 75.5 s, 78.5 s and 98.3 s on this machine, so treat single runs as ±30 % and the paired columns as the comparison. Nothing else was running during the afbc413 legs.

Regression run — scripts/smoke.ps1 -Seconds 180 on the same title build (title: 3c290c16), same rig, each tree built clean at the commit named, each on a data root copied from the same snapshot, each with XCL_DXIL_CACHE wiped for that tree and %LOCALAPPDATA%\NVIDIA\DXCache emptied first:

xcl-smoke v1
commit: 568e7db7729c8fa6c8f0f4b32d798faaf11462bb
gpu: NVIDIA GeForce RTX 4090
title: 3c290c16
seconds: 180
exit: 0x0
frames shown: 1539 (PresentX 1539)
presents per 2 s (last 3): 0 0 0
device removals: 0
crashes: 0
peak commit: 29491 MB
xcl-smoke v1
commit: afbc4134e47969bebdd41c29a34d028d033ff7b7
gpu: NVIDIA GeForce RTX 4090
title: 3c290c16
seconds: 180
exit: 0x0
frames shown: 1488 (PresentX 1489)
presents per 2 s (last 3): 0 0 0
device removals: 0
crashes: 0
peak commit: 30008 MB

A second pair of the same two trees, run before that one with the shared cache each tree had already warmed (1530 frames / 35 647 MB on main, 1558 / 31 310 MB here), and a third tree with the exchange helpers kept inline reached 1719 frames in the cold set. All six runs end the same way: the title stops presenting between 90 and 102 s and stays that way to the timeout, with 0 device removals and 0 crashes, so the frame counts compare the same screen and none of them is a speed result.

What the logs do separate is the per-pipeline cost. In the warm pair, main built 117 compute pipelines totalling 76.6 MB of DXIL in 111.2 s of driver time with its worst single one at 76 358 ms (an earlier run of it logged 89 977 ms for the same program); this PR's tree, whose blobs are all invalidated by the HLSL change, built 23 totalling 10.6 MB in 181.9 s with its worst at 16 897 ms. Same total, opposite shape: 17 s of driver time per MB of DXIL against main's 1.4 s/MB with blobs from earlier runs, and nothing in the PR's run longer than 17 s against a 76 s stall on main. In the cold pair, where both trees re-translate everything, the driver is no longer the bottleneck and the two are within 4 % of each other's frames.

Tested

  • RTX 4090 24 GB (32-lane waves, so split wave64), driver 32.0.16.1664, i9-13900K (32 logical), 64 GB, Windows 11 Pro 26200, rustc 1.100.0, DXC 1.9.2602.17 (SDK 10.0.26100.0), release, Developer Mode on (the cache switch succeeds, so every driver compile here is cold).
  • Cache states: XCL_DXIL_CACHE fresh per tree (so DXC compiled cold in the paired legs), XCL's own driver blobs not used by this harness (it calls CreateComputePipelineState itself), the implicit D3D/driver caches disabled through ID3D12Device9::ShaderCacheControl. The rerun leg also empties %LOCALAPPDATA%\NVIDIA\DXCache before each measurement, because ShaderCacheControl does not cover it and this machine holds 12 GB in it — the first legs did not clear it, which is the likeliest source of the spread noted above. @itsSio's cache-control check on [OFFICIAL] Swarm: cold PSO compilation to first playable frame #2088 finds the NVIDIA driver cache follows the executable's basename rather than its directory, so a new cache directory is not by itself a cold control; the per-compile clearing is.
  • Trees: 568e7db (current main) and 568e7db + this PR's commit rebased (afbc413; the rebase touches only crates/xcl/src/gpu/recomp/tests.rs, where the added test is appended after gpu_scalar_sext_mulhi_and_vector_i64_shifts_co_ci_u32's successor).
  • cargo build --release --offline --workspace then cargo test --release --offline --workspace -- --test-threads=4 on afbc413: 1155 passed, 0 failed, 46 ignored, exit 0 (lib target 1099 / 0 / 26, plus the integration and e2e targets). 23 SKIPPED lines, all no wave64 or the direct path's refused f16 / f32-conversion forms, the same set main produces on this adapter. gpu_large_compute_shares_wave_and_window_helpers passes.
  • Local-only diagnostic (not for upstream): a #[cfg(test)] module in crates/xcl/src/shaders.rs that translates named records through recomp::pso::console_to_dxil_for, disassembles the DXIL, counts instructions / phis / switches / dx.op calls, and calls CreateComputePipelineState once; and a second test that builds the exchange loop with gpu::rdna2::encode, translates it through recomp::translate and times dispatches with runner::dispatch_timed. No game launch in these numbers.
  • Upstream tool, no local code: xcl shaders <pack> --measure-pso <hash> --repeat 1 on each tree's release build for the four records, plus afbc413 with XCL_OUTLINE_EXCHANGE=0. Its DXIL byte counts match the harness numbers for every record, which is what makes the two tables one measurement and not two.

Not tested

  • AMD: I did not reproduce or rule out the RDNA3 unsupported → 0x887A0005 and the RDNA4 ParseAddress failures reported above; every number here is NVIDIA and none of my runs had a device removal. Worth noting for whoever does: @HKEY-Funk-Machine's XCL_HEAP_WINDOWS=1 result puts the RDNA4 failure in the outlined switch-form accessors, which is the group that also carries the build win here — the two cannot be separated by the exchange switch alone. @oni-swr's RX 7800 XT run adds that the RDNA3 suspension follows any remaining [noinline] internal function, under XCL_HEAP_WINDOWS=1 too and including this PR's own GPU unit test, so the exchange switch below does not address the AMD failures: with the exchange inline the accessors and the typed-format helpers are still [noinline].
  • GPU time of the title's own programs (the loop above is synthetic; the retail programs' exchange counts per iteration are not measured).
  • The two >8 MiB-HLSL records, and in-game milestone timing beyond the two 180 s runs above (neither reaches the in-world HUD, so the frame counts compare the same screen, not speed in the world).
  • Heap windows (XCL_HEAP_WINDOWS=1), where this PR leaves the accessors inline.

AI use: Claude Code (Claude Opus 5.5) built both trees, ran the measurements and wrote this; the runs are ours.

@throny throny added the goal:world-load Bears on the retail title getting past world loading label Nov 25, 2026
@ettehn

ettehn commented Nov 25, 2026

Copy link
Copy Markdown

I tested the >8 MiB outlier 95cc13288a27a96e on Windows, CPU-side only, on exact head 5064119 and parent c4d37be. Each used an empty cache, DXC 1.8.2502.11, one record and xcl shaders <record-dir> --precompile --only cs --split 1 --windows 4. A Windows job limited each run to 3 GiB of commit and 50 s.

Windows Exported HLSL, parent → PR [noinline] attributes, parent → PR Peak job commit before timeout, parent → PR
Switch 15,360,321 → 15,363,504 B 0 → 38 2,738.5 → 1,628.0 MiB
Heap (XCL_HEAP_WINDOWS=1) 15,355,149 → 15,355,726 B 0 → 3 2,416.6 → 2,092.2 MiB

All four runs reached the time limit without writing DXIL. In a separate control on #2120 8dcc56d, the same switch-form record took the automatic direct route and emitted 3,824 KiB DXIL in 18.2 s, with 316.0 MiB peak job commit. The outlining lowers memory use within this observation window. The shader still exceeds the direct-route size threshold, so the two changes address different parts of the problem here. No driver PSO or title execution.

AI use — OpenAI Codex (GPT-6.2 Sol) ran the tests and wrote this report.

@gefydev

gefydev commented Nov 25, 2026

Copy link
Copy Markdown
Contributor

Test report: cold driver build time on a GTX 1650 (Turing, 4 GB), four of the title's largest compute programs. The PR's head against its own base, same machine, one program at a time.

Tested

  • PR head 5064119 (Recompiler: large compute programs call shared helpers instead of inlining them) against its base 689f2db; both built from a clean worktree, cargo build --release -p xcl --bin xcl. The branch conflicts with current main in gpu/recomp/tests.rs, so I did not test a merge.
  • NVIDIA GeForce GTX 1650 (32-lane waves only, so the split wave64 form), driver 621.24 (32.0.16.2124), AMD Ryzen 5 1600, 16 GB RAM, Windows 11 Pro 10.0.26300, DXC 1.9.2602.17 (Windows SDK 10.0.26100.0).
  • xcl shaders <the title's shaders pack> --measure-pso <record> --repeat 3, with no other environment variable set (default memory windows, HLSL path, no XCL_DIRECT_DXIL). The tool turns the driver's shader cache off itself. Per program, base first and then the PR, one process each.
record DXIL base → PR DXC base → PR driver build, median of 3 (min – max), base → PR speed-up
e1453fc963ba30e7 261 148 → 193 480 B 10.4 → 4.4 s 10.634 s (10.095 – 10.720) → 5.415 s (5.015 – 5.419) 1.96×
e7784c44a8db17d7 349 612 → 267 020 B 10.7 → 6.5 s 14.878 s (14.212 – 15.031) → 7.856 s (7.431 – 7.956) 1.89×
ef008c0f04b6261a 1 094 856 → 896 688 B 27.4 → 24.5 s 118.210 s (117.805 – 122.558) → 27.686 s (25.870 – 27.695) 4.27×
2d2bbb32f64e4801 1 384 024 → 1 111 148 B 42.7 → 36.1 s 177.118 s (176.269 – 184.169) → 38.109 s (35.849 – 38.196) 4.65×

The DXIL is 18 – 26 % smaller on all four, DXC is faster on all four, and the driver builds the two largest in about a quarter of the time. That is the same direction as the PR's own tables and @brandostrong's numbers on an RTX 4090, on a card and driver neither has used.

Not tested

  • Run-time cost: only CreateComputePipelineState was timed, not GPU time of the dispatches. The outlined exchange and accessors are the part others report as slower at run time, so this report says nothing about it.
  • XCL_HEAP_WINDOWS=1, the direct DXIL path, any of the six programs of the PR's own tables, and the title in game (scripts/smoke.ps1 was not run for this report).
  • One run of three builds per program and per tree; no second pass.

AI use

  • Claude Code ran the measurements (Claude Opus 5.5) and wrote this report (Claude Sonnet 5.5). Every number above is from the tool's own output, not edited by hand.

gustavsi added a commit to gustavsi/xcl that referenced this pull request Nov 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

goal:world-load Bears on the retail title getting past world loading

Projects

None yet

Development

Successfully merging this pull request may close these issues.