Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
404 commits
Select commit Hold shift + click to select a range
0aa1535
Recompiler: make heap-window load and store guards branchless
Nov 26, 2026
376a4e1
Merge branchless heap-window load and store guards
Nov 26, 2026
972f66e
D3D12.X: publish submitted texture-write provenance
Nov 26, 2026
f210584
Merge submitted texture-write provenance
Nov 26, 2026
3fd55df
DirectStorage: wake waiters from ordered completion events
Nov 25, 2026
1f6b310
Merge ordered DirectStorage completion events
Nov 26, 2026
4ca5c6f
D3D12.X: persist slow driver blobs past the RAM cap
Nov 26, 2026
77aaae0
Merge slow driver-blob persistence past RAM cap
Nov 26, 2026
0540a23
D3D12.X: retire released command queues after their final marker
Nov 26, 2026
2d4778f
Merge bounded command queue retirement
Nov 26, 2026
4b68ede
Merge bounded command queue retirement
Nov 26, 2026
24ffb0e
D3D12.X: retain metadata for GPU-owned textures
Nov 26, 2026
a35d6cc
Merge GPU-owned texture metadata
Nov 26, 2026
b271eba
DXC: keep LINK_GATE open on OOM and forward opt/extra args to IDxcLin…
Nov 26, 2026
36c3294
Merge retryable DXC linker OOM handling
Nov 26, 2026
2d8b829
D3D12.X: forget a command list before the runtime frees it
Nov 26, 2026
12b1b78
D3D12.X: retire sparse queue fences without owning queues
Nov 26, 2026
0c07b16
Merge sparse queue fence retirement
Nov 26, 2026
b7af009
D3D12.X: add bounded reverse texture layout conversion
Nov 26, 2026
cd427bf
Merge bounded reverse texture layout conversion
Nov 26, 2026
2bfc36e
D3D12.X: preserve compute stream pipeline flags
Nov 26, 2026
9d42c36
Merge compute stream pipeline flags
Nov 26, 2026
911ad65
Recompiler: bound far-jump analysis initial allocation
Nov 26, 2026
75c4a24
Frame clock: remove paced wait allocations and validate writes
Nov 26, 2026
1dd94d8
Merge allocation-free paced frame waits
Nov 26, 2026
3364f18
D3D12.X: reject put-off segments that fail Close
Nov 26, 2026
4aa68a8
Merge fail-closed deferred command segments
Nov 26, 2026
32ecdb2
D3D12.X: make projected stream caching conservative
Nov 26, 2026
9915414
Merge conservative projected graphics stream caching
Nov 26, 2026
e041684
Recompiler: remap wave-local split-wave64 groups
Nov 26, 2026
66be2c9
Merge wave-local split-wave64 dispatch remapping
Nov 26, 2026
e564cbb
D3D12.X: prepare asynchronous texture downloads
Nov 26, 2026
f877eac
Merge immutable asynchronous texture download plans
Nov 26, 2026
fafeee3
D3D12.X: match texture downloads to writer queues
Nov 26, 2026
c93f42d
Merge writer-queue texture download plans
Nov 26, 2026
e3a52f4
D3D12.X: preserve extended rasterizer stream state
Nov 26, 2026
a38538f
Merge native extended graphics stream translation
Nov 26, 2026
5dd2ef7
D3D12.X: report memory by tracked owner
Nov 26, 2026
36f77be
Merge tracked memory ownership diagnostics
Nov 26, 2026
ba65996
D3D12.X: launch DispatchX thread dimensions safely
Nov 26, 2026
f29519b
Merge safe DispatchX thread-dimension execution
Nov 26, 2026
87b55ac
D3D12.X: serialize each queue submission turn
Nov 26, 2026
7eeaf2e
Merge per-queue submission turns
Nov 26, 2026
9e82e2a
D3D12.X: cache native extended graphics streams
Nov 26, 2026
54e729e
Merge native graphics stream cache lifecycle
Nov 26, 2026
f34a5ea
D3D12.X: measure contended queue submission turns
Nov 26, 2026
be60e97
Merge queue submission contention measurement
Nov 26, 2026
8934364
D3D12.X: call native queue slots for internal work
Nov 26, 2026
570969d
Merge native queue operation helpers
Nov 26, 2026
b0442a2
D3D12.X: capture texture transitions in submission plans
Nov 26, 2026
229e823
Merge immutable texture transition effects
Nov 26, 2026
e0038f6
XAudio2: remove locks and copies from source submission
Nov 26, 2026
0227fc3
Merge XAudio2 source submission hot paths
Nov 26, 2026
9fdfe6c
DirectStorage: precompute BCPack bit packing
Nov 26, 2026
43a645e
Merge BCPack bit-packing fast paths
Nov 26, 2026
5a5b650
XAudio2: reuse validated Opus multistream scratch
Nov 26, 2026
7198d03
Merge validated Opus multistream scratch reuse
Nov 26, 2026
fb81098
D3D12.X: detach heap state before final Release
Nov 26, 2026
01892c7
Merge safe heap release ordering
Nov 26, 2026
9061f0a
D3D12.X: count driver pipeline builds in the window title
Nov 25, 2026
13e7ca4
Merge driver pipeline build telemetry
Nov 26, 2026
7068325
D3D12.X: poll allocator fences outside global state
Nov 26, 2026
ee7b835
Merge allocator fence polling lock reduction
Nov 26, 2026
0ea9a95
D3D12.X: retain submitted texture staging after wait failure
Nov 26, 2026
82aea7a
Merge submitted texture staging lifetime hardening
Nov 26, 2026
e10df30
D3D12.X: bypass title hooks for internal queue execution
Nov 26, 2026
2344752
Merge internal queue execution bypass
Nov 26, 2026
fee5d1b
Recompiler: fold unobserved EXEC selects in direct DXIL
Nov 26, 2026
9eb8f83
Merge guarded direct DXIL EXEC-select folding
Nov 26, 2026
0d4d445
D3D12.X: signal allocator retirement fences outside global state
Nov 26, 2026
e96039c
Merge allocator retirement signaling lock reduction
Nov 26, 2026
4cc28d4
D3D12.X: publish GPU texture writes at title fence completion
Nov 26, 2026
03e5a54
Merge title-fence texture download activation
Nov 26, 2026
2e76ec5
D3D12.X: publish single descriptors outside shared heap locks
Nov 26, 2026
f7eda73
Merge lock-free single descriptor publication
Nov 26, 2026
dc7280f
D3D12.X: include texture refresh in submit stall timing
Nov 26, 2026
f9d24c3
Merge submit preparation stall coverage
Nov 26, 2026
6457c18
D3D12.X: fall back when extended cache deletion is unavailable
Nov 26, 2026
db8fb04
Merge exact driver-cache deletion fallback
Nov 26, 2026
cc64d20
D3D12.X: publish descriptor ranges outside heap locks
Nov 26, 2026
d09fb45
Merge lock-free descriptor range publication
Nov 26, 2026
88b8200
D3D12.X: poll allocator backing fences outside global state
Nov 26, 2026
0ef2c0b
Merge allocator backing fence lock reduction
Nov 26, 2026
3a984e3
D3D12.X: promote deferred compute before list preparation
Nov 26, 2026
c44b7a4
Merge early deferred compute demand
Nov 26, 2026
23d7f4e
D3D12.X: serialize title texture uploads per queue
Nov 26, 2026
0942cbc
Merge per-queue texture upload retirement
Nov 26, 2026
3951031
D3D12.X: poll VRAM retirement fences outside registry locks
Nov 26, 2026
c16a884
Merge unlocked VRAM retirement polling
Nov 26, 2026
547f321
D3D12.X: publish texture downloads outside the fence registry
Nov 26, 2026
07f0546
Merge unlocked texture fence completion
Nov 26, 2026
bd36a0b
D3D12.X: isolate VRAM retirement work per device
Nov 26, 2026
4d236d9
Merge per-device VRAM retirement state
Nov 26, 2026
6dd9d53
D3D12.X: reuse bounded workers for texture detiling
Nov 26, 2026
34e5435
Merge persistent texture detile workers
Nov 26, 2026
d451e40
D3D12.X: reset allocator backings outside global state
Nov 26, 2026
410e5d6
Merge unlocked allocator reset operations
Nov 26, 2026
6f2a73b
D3D12.X: poll sparse retirement fences outside global state
Nov 26, 2026
f2953e7
Merge unlocked sparse retirement polling
Nov 26, 2026
bdce892
D3D12.X: enqueue sparse title waits outside global state
Nov 26, 2026
b1dd2d8
Merge unlocked sparse title waits
Nov 26, 2026
78828d4
Recompiler: prune unused split-piece resource bindings
Nov 26, 2026
ff6a4a7
Merge split-piece binding pruning
Nov 26, 2026
5d1a657
D3D12.X: retire spare recordings and reclaim idle allocators
Nov 26, 2026
3c6b0bb
Merge retired allocator recording reclamation
Nov 26, 2026
77eb9e7
D3D12.X: preserve used pipelines when the writer stops
Nov 26, 2026
22c6455
Merge used-pipeline journal shutdown recovery
Nov 26, 2026
67f4261
D3D12.X: count queued pipeline builds without a frame scan
Nov 26, 2026
6e21dec
Merge constant-time queued pipeline accounting
Nov 26, 2026
2b87805
D3D12.X: reuse pending pipeline entries on bind
Nov 26, 2026
e760183
Merge single-lookup pipeline binds
Nov 26, 2026
d5aa0a6
D3D12.X: reserve split continuations without allocators
Nov 26, 2026
c4379c2
Merge allocator-free split continuations
Nov 26, 2026
be772de
D3D12.X: key compute driver blobs by static samplers
Nov 26, 2026
bd623ff
Merge root-aware driver cache identity
Nov 26, 2026
7619ff8
D3D12.X: create sparse placed buffers outside global state
Nov 26, 2026
84ba4b7
Merge unlocked sparse buffer creation
Nov 26, 2026
7346c6f
D3D12.X: cache invariant slots in hot hooks
Nov 26, 2026
74dfc88
Merge cached hot-hook COM slots
Nov 26, 2026
29aa585
D3D12.X: shard pending pipeline lookups by stand-in
Nov 26, 2026
f6abdcc
Merge sharded pending pipeline registry
Nov 26, 2026
faea307
D3D12.X: stop stalled sparse ring reclaim cleanly
Nov 26, 2026
b4bddc5
Merge bounded sparse ring reclaim
Nov 26, 2026
b81ac2e
D3D12.X: process 2D texture tiling in contiguous block runs
Nov 26, 2026
8d32f90
Merge block-slab texture tiling
Nov 26, 2026
0eaef7e
D3D12.X: complete failed pipeline worker jobs
Nov 26, 2026
8540311
Memory: avoid VirtualQuery walks in sparse windows
Nov 26, 2026
7856f26
Merge terminal pipeline worker failures
Nov 26, 2026
28d55c4
Merge sparse writable fast path
Nov 26, 2026
37271a3
D3D12.X: abort sparse allocator reuse after wait failure
Nov 26, 2026
24ab495
Merge fail-closed sparse slot reuse
Nov 26, 2026
651ec16
D3D12.X: enqueue texture page waits outside global state
Nov 26, 2026
a844ac7
Merge unlocked texture page waits
Nov 26, 2026
e5d2e5e
D3D12.X: separate compute blobs by node mask
Nov 26, 2026
5dc2833
D3D12.X: isolate ABI roots by device
Nov 26, 2026
10072ce
D3D12.X: share split compute root signatures
Nov 26, 2026
d8d0dc6
Recompiler: flatten direct-DXIL compute heap reads
Nov 26, 2026
e59178a
D3D12.X: defer superseded texture unmaps
Nov 26, 2026
4cd1b77
D3D12.X: separate persisted compute blobs by node
Nov 26, 2026
87c5c52
XAudio2: bulk-copy decoded PCM output
Nov 26, 2026
bbd1222
D3D12.X: signal deferred unmaps outside page state
Nov 26, 2026
d2f1651
Recompiler: keep graphics cache identity under heap-flat
Nov 26, 2026
4893eb6
Shaders: claim driver-cache builds across processes
Nov 26, 2026
5afb11a
D3D12.X: keep two-pass compute on the pipeline node
Nov 26, 2026
acafdbd
Shaders: release pipeline permits during unwind
Nov 26, 2026
bf157ec
PE loader: rewrite console wait instructions after first fault
Nov 26, 2026
2a577d7
XAudio2: preallocate decoded Opus output
Nov 26, 2026
d4f03aa
D3D12.X: share idle command allocator spares
Nov 26, 2026
e526619
Shaders: serialize identical in-process pipeline builds
Nov 26, 2026
202c962
D3D12.X: separate indirect dispatch-chain root ABI
Nov 26, 2026
1452463
D3D12.X: complete graphics driver cache identity
Nov 26, 2026
277c0f9
Recompiler: charge split pieces to the shader cache
Nov 26, 2026
16e5856
D3D12.X: gate medium AMD compute driver compiles
Nov 26, 2026
bd7d1f9
D3D12.X: retain accepted disk pipeline blobs
Nov 26, 2026
acb7ced
D3D12.X: cache positive mirror range lookups
Nov 26, 2026
2a6a8ba
D3D12.X: run ready split pipelines through ExecuteIndirect
Nov 26, 2026
9ec2b4a
D3D12.X: retain UMA until its native allocator resets
Nov 26, 2026
ae55d10
D3D12.X: measure sampled texture residency on activity runs
Nov 26, 2026
05bab78
D3D12.X: attribute submitting-thread recording costs
Nov 26, 2026
ce989d2
README: document activity texture residency totals
Nov 26, 2026
ffac321
D3D12.X: build indirect split pipelines on the CBV ABI
Nov 26, 2026
8191c1b
Shaders: report driver-cache write failures
Nov 26, 2026
c162ffb
Shaders: prewarm observed indirect split pipelines
Nov 26, 2026
aa446c2
D3D12.X: reuse indirect commands within one recording list
Nov 26, 2026
cf4c3eb
D3D12.X: separate tile pool allocation classes
Nov 26, 2026
70a58f4
D3D12.X: retain tile ownership by mip group
Nov 26, 2026
6495067
Shaders: prewarm the first indirect split dispatch
Nov 26, 2026
27f8efe
Shaders: report durable pipeline preparation outcomes
Nov 26, 2026
f574f0c
D3D12.X: attribute CPU-write looks only during activity runs
Nov 26, 2026
3d0d055
D3D12.X: create lists on the active allocator backing
Nov 26, 2026
4465628
D3D12.X: attribute submitting-thread descriptor costs
Nov 26, 2026
a608310
D3D12.X: make activity look intervals coherent
Nov 26, 2026
36d9ebb
D3D12.X: preserve tile allocation class invariants
Nov 26, 2026
3a42a19
D3D12.X: report retained pipeline age
Nov 26, 2026
054270c
D3D12.X: preserve CPU writes during sparse copy-back
Nov 26, 2026
cf1d7f8
xcl run: XCL_THREAD_DUMP_AT also logs the fences and queue waits behind
Nov 25, 2026
db2dee0
xcl run: XCL_THREAD_DUMP_AT also logs the Wait64 cells behind
Nov 25, 2026
862cf61
xcl run: the sync-state dump names the list behind a Wait64 cell
Nov 26, 2026
4f55fd8
xcl run: a Reset or Release ends the recording the Write64 trace follows
Nov 26, 2026
05d0747
xcl run: trace immutable submission generations
Nov 26, 2026
0866249
D3D12.X: retain opt-in pipeline rebuild recipes
Nov 26, 2026
0ce5f0e
D3D12.X: count sampled array slices in residency metrics
Nov 26, 2026
f882575
D3D12.X: expose exact submission retirement receipts
Nov 26, 2026
bf0db1a
D3D12.X: track live texture SRV metadata
Nov 26, 2026
41a369e
D3D12.X: publish sparse upload hashes after queue receipt
Nov 26, 2026
729dac6
D3D12.X: own immutable native pipeline generations
Nov 26, 2026
3cd053e
D3D12.X: fail title submits closed on sparse upload loss
Nov 26, 2026
d7e6438
D3D12.X: capture shared descriptor heap use
Nov 26, 2026
025dc2f
D3D12.X: retire shared descriptor heap epochs
Nov 26, 2026
8461700
D3D12.X: capture native PSO generations in recordings
Nov 26, 2026
c57709e
D3D12.X: release sparse state during upload waits
Nov 26, 2026
c77b484
D3D12.X: serialize native PSO generation rebuilds
Nov 26, 2026
ae303f6
D3D12.X: retire native PSO generation pins
Nov 26, 2026
54815e0
D3D12.X: pin tracked SRV resources across release
Nov 26, 2026
ea55fb1
D3D12.X: queue native pipeline rebuild requests
Nov 26, 2026
95d3844
D3D12.X: choose a ready sparse upload slot
Nov 26, 2026
870e6fa
D3D12.X: deduplicate native generation pins linearly
Nov 26, 2026
10ab225
D3D12.X: lease exact descriptor heap slots
Nov 26, 2026
dd17d62
D3D12.X: revalidate tracked SRVs before mutation
Nov 26, 2026
ff23e65
D3D12.X: release sparse upload gate during fence waits
Nov 26, 2026
c58bf39
D3D12.X: detach evicted native pipeline generations
Nov 26, 2026
ab6b395
D3D12.X: split sparse upload gate timing
Nov 26, 2026
0bd24ca
D3D12.X: batch exact descriptor mutation leases
Nov 26, 2026
96950cb
D3D12.X: queue evicted pipeline rehydration
Nov 26, 2026
c8889e8
D3D12.X: model exact sparse upload work claims
Nov 26, 2026
96f2be4
Scripts: compare sparse upload gate timing
Nov 26, 2026
fd5d142
D3D12.X: journal bounded pipeline eviction candidates
Nov 26, 2026
b5f7fc0
D3D12.X: model immutable sparse upload plans
Nov 26, 2026
ba798d8
D3D12.X: rank bounded pipeline eviction candidates
Nov 26, 2026
3116f06
D3D12.X: model sparse upload ring reservations
Nov 26, 2026
ab32314
Tests: compare flat and guarded heap-window reads
Nov 26, 2026
fa2167b
D3D12.X: model pipeline pressure admission
Nov 26, 2026
4e0b355
D3D12.X: model serialized sparse upload commits
Nov 26, 2026
7d0487c
D3D12.X: model sparse claim receipt frontier
Nov 26, 2026
b628cfb
D3D12.X: extract exact synchronous dirty upload batches
Nov 26, 2026
5403944
D3D12.X: couple sparse batch ownership
Nov 26, 2026
a4f0399
D3D12.X: track bounded evicted pipeline identities
Nov 26, 2026
d98343d
D3D12.X: observe bounded pipeline pressure candidates
Nov 26, 2026
99c45c4
D3D12.X: compose sparse batch submission receipts
Nov 26, 2026
f910a40
D3D12.X: time native title queue submissions
Nov 26, 2026
eac1a94
D3D12.X: model exact pipeline rehydration receipts
Nov 26, 2026
10da931
Tests: add a dependency-free benchmark harness
Nov 26, 2026
895b6e3
Tests: add synthetic benchmark foundation
Nov 26, 2026
f657737
Tests: benchmark runtime and shader hot paths
Nov 26, 2026
aedde19
D3D12.X: coordinate exact pipeline restoration state
Nov 26, 2026
2c5c33d
D3D12.X: model exact foreground sparse waits
Nov 26, 2026
bd64a1d
D3D12.X: remove superseded sparse commit model
Nov 26, 2026
0ab510a
D3D12.X: remove superseded sparse upload plan
Nov 26, 2026
2116d10
D3D12.X: remove superseded sparse claim wrappers
Nov 26, 2026
c9a26c5
D3D12.X: retain exact foreground restoration attempts
Nov 26, 2026
ff6be93
Tests: cover exact pipeline restoration attempts
Nov 26, 2026
bf20fed
D3D12.X: install exact eviction tokens before detach
Nov 26, 2026
e2646db
Tests: cover exact eviction token installation
Nov 26, 2026
a8efddd
Scripts: compare native submission timing
Nov 26, 2026
2579f3a
D3D12.X: classify exact pipeline restoration without waiting
Nov 26, 2026
67a59b0
Tests: cover structured pipeline restoration classification
Nov 26, 2026
0a2c5da
D3D12.X: aggregate native submission timing
Nov 26, 2026
56120a2
Scripts: compare submission timing distributions
Nov 26, 2026
b534e4f
D3D12.X: retain pipeline decisions in bind state
Nov 26, 2026
1f21f99
Tests: cover retained pipeline decisions in bind state
Nov 26, 2026
7fa80e8
D3D12.X: own one dormant restoration coordinator
Nov 26, 2026
cdb0cd9
Tests: cover the dormant restoration coordinator
Nov 26, 2026
e444225
Scripts: record Cargo feature performance variants
Nov 26, 2026
dad2398
Tests: benchmark allocator contention across workers
Nov 26, 2026
e76454b
Tests: seed resubmit lifetime identity
Nov 26, 2026
a134a5f
Recompiler: use larger compact tables on every GPU
Nov 25, 2026
f3566e0
Tests: bound concurrent direct-DXIL translations
Nov 26, 2026
cd435a9
Scripts: show Windows test failures before abort
Nov 26, 2026
7cd41d2
Recompiler: leave unsafe group barriers to HLSL
Nov 25, 2026
e9211ff
Recompiler: keep backedge values behind loop phis
Nov 26, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,4 +51,4 @@ jobs:

- name: Build and test
shell: pwsh
run: ./scripts/test.ps1 --skip test_title_runs_and_game_folder_is_untouched
run: ./scripts/test.ps1 --nocapture --skip test_title_runs_and_game_folder_is_untouched
97 changes: 92 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ A gamepad is recommended ([Controls](#controls)). The game folder is never modif
| **kernelx** | ✅ | title memory (budget from MicrosoftGame.Config, physical pages), threads on the PC's processors, modules, OS / console info | unit + end-to-end tests |
| **Memory** | ✅ | title graphics memory shared by CPU and GPU without copies, up to 16 GB (4 GiB windows) | GPU tests: loads, stores and atomics across windows |
| **File system** | ✅ | console paths (`GAME:`, `G:`, `D:` …) → the game folder; writes go to an overlay, the game folder is never modified; the console's drives: `S:\` (persistent local storage) and `T:\` (temp) in the title's data folder; free disk space answered for console paths | end-to-end: the test title's folder stays byte-identical; PLS and free space through the real call path |
| **DirectStorage** | ✅ | the console's DirectStorage queues: file and memory sources, zlib, and BCPack – the console's texture compression – for BC1, BC3, BC4, BC5, BC6H and BC7 (BC2 and the hardware swizzle are refused) | unit tests on synthetic streams; retail BCPack chunks of all six modes byte-identical with a reference decoder (`XCL_SAMPLE_BCPACK`) |
| **DirectStorage** | ✅ | the console's DirectStorage queues: file and memory sources, queued event notifications, zlib, and BCPack – the console's texture compression – for BC1, BC3, BC4, BC5, BC6H and BC7 (BC2 and the hardware swizzle are refused) | unit tests on synthetic streams; retail BCPack chunks of all six modes byte-identical with a reference decoder (`XCL_SAMPLE_BCPACK`) |

</details>

Expand All @@ -151,7 +151,7 @@ A gamepad is recommended ([Controls](#controls)). The game folder is never modif
| **Pipelines** | ✅ | PSOs from console shaders: VS+PS, CS, MS+PS, VS+GS+PS; root signature with the shaders' static samplers; non-blocking creation – a pipeline whose shaders are not compiled yet gets a stand-in at once and is built in the background | GPU tests drawing the game's own VS / PS pairs, also built in the background |
| **D3D12.X compute** | ✅ | console device slots, console descriptor heaps (T# / V# / S#), buffers at their console addresses, compute command lists recorded in the console format and replayed (tables, barriers, clears, copies) | the game's BVH builder and FSR 4 record and run through XCL |
| **D3D12.X graphics** | ✅ | device, resources and heaps (also placed in title memory), pipelines; the title's graphics command lists – draws, indirect draws, graphics root arguments, barriers, copies, clears – and command lists recorded by console code, replayed; `PresentX` and frame pacing into an XCL window | Minecraft Preview plays its worlds (millions of draws, none skipped); Fortnite and XDefiant draw their screens |
| **Textures** | ✅ | GFX10 tiling (all 14 2D swizzle modes, the 6 3D thick modes, linear), mip chains with mip tail, arrays, cubes and 3D textures → PC textures | 909 / 912 retail textures exact (the 3 volume LUTs decode smooth); GPU upload bit exact |
| **Textures** | ✅ | GFX10 tiling (all 14 2D swizzle modes, the 6 3D thick modes, linear), mip chains with mip tail, arrays, cubes and 3D textures → PC textures; supported GPU-written title subresources copy back before their writer queue's title fence becomes visible | 909 / 912 retail textures exact (the 3 volume LUTs decode smooth); GPU upload bit exact |
| **Ray tracing** | ✅ | BLAS / TLAS built on the GPU by the game's own XboxBvhBuilder; RDNA2 BVH node format; BVH intersection instructions emulated in shaders | GPU traversal = brute force reference; the game's builder output checked on the GPU |
| **Upscaling** | ✅ | the game's AMD FSR 4 console DLL (`amd_fidelityfx_upscaler_xbox.dll`): context, the 29 pipelines in the console driver's own container (FSPX) translated, a frame's 20 passes recorded and run on the GPU | end-to-end with the real DLL: a 1280×720 → 1920×1080 frame on an RX 9070, the input's gradient in the output |

Expand Down Expand Up @@ -222,7 +222,7 @@ xcl inspect D:\Game\game.exe # the game's imports and what XCL has
xcl run D:\Game [-- game arguments] # run
xcl disasm <shader.bin> [--hex] # RDNA2 disassembler (console containers too)
xcl shaders D:\data\shaders.rpf --top 50 # pack statistics; --recomp / --compile N
xcl shaders D:\data\shaders.rpf --precompile --only cs --pipelines # build compute pipelines and save driver blobs for the next run
xcl shaders D:\data\shaders.rpf --precompile --only cs --pipelines # build compute pipelines and save driver blobs for the next run (except by default on AMD)
xcl shaders D:\data\shaders.rpf --precompile --only cs --pipelines --used-only # only the compute pipelines an earlier run of the title used
xcl shaders D:\data\shaders.rpf --export-hlsl out --record-hash HEX # exact compute HLSL for investigation
xcl shaders D:\data\shaders.rpf --measure-pso HEX --repeat 3 # cold driver PSO timing (cache disabled)
Expand All @@ -235,6 +235,11 @@ xcl rpf D:\data\shaders.rpf --extract NAME --out folder
- For compute shaders that XCL can split, the runtime first tries the saved driver blob for
the whole shader. A usable blob lets the GPU run it in one dispatch. If the blob is missing
or the driver rejects it, XCL builds the split pieces.
- A split program first seen through `ExecuteIndirect` is also kept in
`used-indirect-split.txt` beside the DXIL cache. A later `--pipelines --used-only` pass still
builds its direct-dispatch pieces and whole fallback, and additionally saves both its pieces and
whole fallback under the indirect root; other split programs do not pay for those potentially
long driver compiles.
- **`--pipelines` size cap**: a compute program whose DXIL is over 8 MiB and that has no saved
blob is left to the runtime instead of being compiled in the pass — those compiles take tens
of minutes and gigabytes and stopped the pass on the biggest programs. `XCL_PIPELINE_MAX_KB`
Expand Down Expand Up @@ -263,6 +268,12 @@ xcl rpf D:\data\shaders.rpf --extract NAME --out folder
default.
- Translated shaders are reused across XCL rebuilds when the translator sources and DXC
toolchain are unchanged; `XCL_TRANSLATED_CACHE=0` disables that disk cache.
Loading a cached shader without split pieces reuses the file buffer, avoiding a second
payload-sized allocation.
- XCL saves an eligible driver blob when its pipeline takes at least 250 ms to build, even
after the bounded in-memory blob cache fills. This is off by default on AMD;
`XCL_PSO_DISK_CACHE=1` forces it on, and `XCL_PSO_DISK_CACHE=0` disables it elsewhere.
Compute blobs with different ordered static-sampler root signatures use separate entries.
- Direct compute dispatches can split large programs into pipelines built in parallel.
`XCL_DIRECT_SPLIT_INSTRUCTIONS` sets the target instructions per piece (default 12500,
zero disables splitting). Loops stay in one piece. A strongly connected component over the
Expand All @@ -280,11 +291,16 @@ xcl rpf D:\data\shaders.rpf --extract NAME --out folder
`XCL_PSO_TRACE=1` logs every driver compile. A huge compute program the driver refuses is
logged with the driver's verdict (`the driver refused the compute PSO of record HASH … with
0x…`): its dispatches are skipped.
On AMD, cold 128–256 KiB compute pipelines use a separate lane (three background / four
wanted at once on hosts with at least 32 GiB RAM, two / three below that), configurable with
`XCL_MEDIUM_PSO_CONCURRENCY` and `XCL_MEDIUM_PSO_WANTED_CONCURRENCY`.
- With `XCL_DRED=1`, a D3D12 device removal logs GPU breadcrumbs in `xcl.log`.
XCL examines up to 4,096 command lists and reports up to 64 unfinished lists, starting with
those on which the GPU completed at least one operation. For each, it names the translated
pipeline bound at the last operation DRED saw complete and those bound after it, by their
console shaders' hashes (`cs`, `vs` / `ps`, `ms` / `ps`, `vs` / `gs` / `ps`).
- `XCL_TEXTURE_LEVEL_PAGES=1` gives sampled title textures backing as their mip levels stream in.
Zero-filled mip uploads in a batch share one staging span and still clear any mapped tiles.
- `XCL_DSTORAGE_PARALLEL_DECOMPRESS=1` enables parallel CPU decompression for file-backed zlib
requests with virtual destinations. Defaults: four workers and a shared 32 MiB staging budget
(`XCL_DSTORAGE_WORKERS`, `XCL_DSTORAGE_MEMORY_BUDGET_MIB`). Requests retire in queue order.
Expand All @@ -297,14 +313,32 @@ xcl rpf D:\data\shaders.rpf --extract NAME --out folder
`null` if its format cannot be decoded. Intermediate render-target dumps do not update it.
Sampling uses every fourth pixel in each direction (`XCL_FRAME_DUMP_FULL=1`: every pixel).
A coarse sample can miss detail; a non-dark sample does not establish correct rendering or gameplay.
With `XCL_STALL_TRACE=1`, `report.json` also contains versioned aggregate counts, total/max time and
log2-nanosecond histograms for coarse runtime stalls, plus a bounded list of the newest spans of at
least 50 ms. The tracing is off by default.
`XCL_STALL_TRACE_DETAIL=1` includes high-frequency draw, dispatch, binding, descriptor/view,
barrier, copy and command-list lifecycle recording costs on the title's first observed submitting
thread; it also enables the coarse trace. Use it only for a diagnostic run because every recorded
call reads the clock and updates counters.
`XCL_GPU_TIMING=1` times each native title `ExecuteCommandLists` chunk on the CPU. The count and
slowest duration/list count are written to `report.json`; chunks taking at least 50 ms are logged
(`XCL_GPU_TIMING_MS` changes that threshold). It does not measure when the GPU finishes.
- **Diagnostics for a bug report** (all off by default; set them in the environment of `xcl run`):
- `XCL_RUN_SECONDS=n`: the title ends itself after `n` seconds, with the GPU drained and
`xcl.log` and `report.json` written, so a run of a fixed length can be attached. A value that
is not a whole number is ignored.
- `XCL_ACTIVITY=1` (any value turns it on): every 2 seconds `xcl.log` gets an `activity (2 s)`
line with what the title did in that time (presents, submits, draws, dispatches, frame-event
waits, DirectStorage requests), and a `memory:` line with the process's commit and the video
memory in use. Where the lines stop changing is where the title stopped.
waits, DirectStorage requests), a `memory:` line with the process's commit and video memory in
use, a `memory by owner` line splitting the known XCL allocations from `other`, and sampled
texture resident / SRV-addressable / virtual texel totals. It also reports completed background
pipelines retained behind stand-ins and how many frames ago they were last used, and the
active foreground time plus
serialization wait spent looking for CPU writes before submits (write-watch bytes/ranges/pages,
sparse queue/fence-state/copy phases and zero/dirty volume, upload-gate wait/hold time split
between submit preparation and synchronous readback, and other refresh work). A negative
`other` exposes an overlapping or stale sample; unavailable
adapter segments say `unknown`. Where the lines stop changing is where the title stopped.
- `XCL_THREAD_DUMP_AT=s1,s2,…`: at each of those seconds after the start, the state of every
thread of the title goes into `xcl.log`, for a title that stalls.
- `XCL_TRACE_FAULTS=1` (any value): the first 32 access violations are logged as they are raised
Expand All @@ -328,12 +362,65 @@ xcl rpf D:\data\shaders.rpf --extract NAME --out folder

</details>

## Reproducible cold and warm runs

On a clean commit, build and run the same title once with fresh XCL caches and once with those
exact caches warm:

```powershell
.\scripts\perf-run.ps1 -Game 'D:\Games\SomeTitle' -OutDir 'D:\xcl-perf\run-1' -Seconds 120
```

The script builds `xcl` in release mode and refuses a dirty worktree or a non-empty output
folder. Both runs use a new temporary `XCL_DATA_ROOT` and `XCL_DXIL_CACHE`; the warm run reuses
the cold run's directories. They are deleted afterwards, and existing user caches are never read,
changed, or deleted. The output folder contains only each run's `xcl.log` and `report.json`, plus
a versioned `manifest.json` with the commit, run order, hardware/toolchain, selected XCL
environment, cache identity, durations, and exit status. It contains no game files or cache data.

The manifest identifies the workload with a SHA-256 metadata fingerprint over its sorted relative
file paths, lengths, and UTC modification-time ticks. Only the fingerprint and its algorithm/version
are recorded; the inventory's file names and absolute paths are not persisted. This is a metadata
fingerprint, not a content hash: a content change that preserves the path, length, and modification
time is not detected.

The manifest calls these states **XCL-cold** and **XCL-warm**. GPU driver caches are
driver-controlled and are explicitly recorded as `uncontrolled`; this is not a fully cold-driver
benchmark.

Compare two completed artifact folders without modifying them:

```powershell
.\scripts\perf-compare.ps1 -Baseline 'D:\xcl-perf\main' -Candidate 'D:\xcl-perf\change' > comparison.json
```

The console shows raw cold/warm duration, exit/timeout state, stall totals/counts/maxima, the five
compute-build coalescing counters, and ranked-preload submissions, starts and promotions. The
allocator section also reports execute/chunk topology, retirement-signal outcomes, mark writes and
allocator-state lock timing. Sparse upload-gate submit/readback wait and hold times are summed from
the activity log; artifacts from older builds label those counters missing rather than zero. The
redirected JSON keeps those values, raw deltas, and stall log2
histograms. Missing reports or preparation summaries and unsupported preparation versions remain
explicit states; they are not treated as zero. The tool
refuses different workload fingerprints or identity algorithm/versions, run order, requested
duration, runtime environment, system, GPU, or GPU driver. Missing reports and stall summaries are
labelled as missing; it does not infer significance or percentages.

## Tests

```powershell
.\scripts\test.ps1 # cargo build --workspace + cargo test --workspace
.\scripts\perf-run.tests.ps1 # cold/warm runner fixture (no game is run)
.\scripts\perf-compare.tests.ps1 # comparison fixture (synthetic artifacts)
cargo bench -p xcl # synthetic performance benchmarks
cargo bench -p xcl --bench core # run one benchmark target
```

Benchmarks use generated inputs and public XCL APIs; they do not require game files or a title
executable. The dependency-free harness prints median, mean and minimum time plus throughput; a
positional substring selects benchmarks, and `cargo bench -p xcl -- --test` runs every closure once
as a fast smoke check.

Unit tests, an end-to-end test with our own "console title" (`tests/testtitle`) and GPU tests
(D3D12, SM 6.6; skipped without a GPU / DXC; `XCL_ADAPTER=1` or `XCL_ADAPTER=radeon` picks
another adapter than the first high-performance one, for titles too). A GPU test that cannot run on
Expand Down
16 changes: 16 additions & 0 deletions crates/xcl/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -68,3 +68,19 @@ features = [
"Win32_UI_Controls_Dialogs",
"Win32_UI_WindowsAndMessaging",
]

[[bench]]
name = "core"
harness = false

[[bench]]
name = "formats"
harness = false

[[bench]]
name = "gpu_cpu"
harness = false

[[bench]]
name = "runtime"
harness = false
36 changes: 36 additions & 0 deletions crates/xcl/benches/core.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
mod support;

use std::hint::black_box;
use support::Criterion;

fn core_benches(c: &mut Criterion) {
let encoded = xcl::gpu::rdna2::encode(
"V_ADD_F32",
"ENC_VOP2",
&[("VDST", 1), ("SRC0", 258), ("VSRC1", 3)],
None,
)
.expect("the built-in instruction table must encode V_ADD_F32");

c.bench_function("rdna2/decode_vop2", |b| {
b.iter(|| {
black_box(
xcl::gpu::rdna2::decode(black_box(&encoded), 0)
.expect("benchmark instruction must decode"),
);
});
});

c.bench_function("descriptor/component_mapping", |b| {
b.iter(|| {
black_box(xcl::gpu::desc::component_mapping(
black_box([4, 5, 6, 7]),
black_box([0, 1, 2, 3]),
));
});
});
}

fn main() {
support::run(&[core_benches]);
}
Loading
Loading