Shaders: trace offline precompile phases #2220
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
goal:world-load
good first issue
help wanted
invalid
keep-open
off-goal
question
stale
test-only
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/xcl-dev--xcl!2220
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-2220"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@ettehn on GitHub · 2026-11-25 10:15 UTC · original
ettehn:codex/offline-precompile-trace→main· +94 −20 · 2 files · 1 commits · openPart of #2088.
XCL_PSO_TRACE=1traces offline shader precompile, including split compute PSOs.What is in it
--export-hlslalso traces translation.Tested
cargo build --workspace --offline --locked -j 2passed.cargo test --workspace --offline --locked -j 2 --no-fail-fast -- --test-threads=1 --nocapture: 1,431 passed, 4 failed, 47 ignored, with 25 explicit GPU skips. Four DXIL fuzz seeds (70, 545, 1019, 1507) also returned0x8007000EatCreateComputePipelineStateon cleanmainb49be183.17090008revision: NVIDIA, AMD.Regression run
Same retail title, 20 seconds each, separate initially empty XCL data and DXIL caches, networking off and no scripted input. The main result is the same clean baseline used for #2409.
Main:
PR:
Not tested
AI use
@luckyteagirl on GitHub · 2026-11-25 11:06 UTC · original
Independent AMD verification on exact, clean PR head
170900080083670abdf688c35cbe9c3f49898aa6against currentmain568e7db7729c8fa6c8f0f4b32d798faaf11462bb.Environment: Windows 11 build 26200, Ryzen 9 5980HX, Radeon RX 6800M driver
30.0.13002.13003, Rust 1.99.0 MSVC, DXC/DXIL 1.9.2609.5.XCL_ADAPTER=6800M.Tests: On the PR head,
cargo test --locked -p xcl --lib -j 2 shaders:: -- --test-threads=1 --show-outputgave 9 passed, 0 failed, 0 ignored; one passing test printedSKIPPEDbecause Windows Developer Mode is required to disable the driver cache.cargo build --locked --workspace -j 2andcargo build --release --locked -p xcl -j 2passed. After the workspace build,cargo test --locked --workspace --no-fail-fast -- --test-threads=4reached all 21 targets: 993 passed, 161 failed, 46 ignored, six explicit SKIPPED lines. The broad RX 6800M failure cluster includes D3D12 device suspension (0x887A0005); this is not a green full suite. My first attempt had one additional e2e failure solely because I had not built the test-title binaries; the build plus the final full rerun removed it.Offline trace: I used the locally owned retail shader pack and set
XCL_PSO_TRACE=1,XCL_DXC_THREADS=1, freshXCL_DATA_ROOT/XCL_DXIL_CACHE, and--precompile --only cs --split 1 --windows 4 --pipelines --limit 22158. The limit is the first compute record's position in this stage-ordered pack, so this processed earlier non-compute records and compiled one compute shader. Result: 1 compiled, 1 GPU pipeline made, 0 errors, 0 refusals. The log has eight start/end pairs with matching span IDs:input-read,pack-scan,precompile-init,precompile-translate,precompile-pipeline,pipeline-cache-read,pipeline-slot, andpipeline-create-without-blob. The largest private-commit sample on those phase lines was 443 MiB. A separateXCL_PSO_TRACE=0short control emitted no phase lines; that short control contained no compute record, so it does not compare pipeline creation time. No pack content or shader blob is attached.Paired guarded retail smoke: Release binaries, same locally owned title (
title: 2ef5fd64), 12 seconds each, default HLSL path, tracing off, networking off, separate fresh data and DXIL caches; neither run hit the external memory guard. The title reached menu frames; this does not test offline precompile in the runtime.Main:
PR head:
AI assistance: OpenAI Codex (GPT-6; exact variant not exposed) ran the isolated checks, verified the logs and revisions, and drafted this comment.
@itsSio on GitHub · 2026-11-25 11:07 UTC · original
Tested
Independent Windows hardware verification on clean head
170900080083670abdf688c35cbe9c3f49898aa6. Both: Windows 11 Pro build 26200, NVIDIA driver 610.88, debug MSVC.cargo build --workspace --locked -j 4exited 0 on both.cargo test --workspace --locked -j 4 --no-fail-fast -- --test-threads=4 --nocapture:On each PC:
xcl shaders <one-record directory> --precompile --only cs --split 1 --windows 4 --pipelines, one DXC worker and one pipeline worker, separate fresh XCL DXIL caches,XCL_PSO_DISK_CACHE=0,XCL_PIPELINE_CACHE_OFF=0, andXCL_PSO_TRACE=0then1. Same synthetic compute record66310f0085ef8698; 10,056 bytes DXIL on RTX 5080 and 10,060 on RTX 2080 SUPER. Each launch exited 0 and made one PSO, zero refusals. Tracing off yielded zero phase lines; tracing on yielded six matched start/end pairs on each GPU: initialization, translation, precompile pipeline, cache read, slot acquisition, andpipeline-create-without-blob. This controls for the pipeline creation taking place in both modes.Not tested: Retail smoke in our runs, AMD, packed-input read/scan, driver-blob hit/fallback, or cold performance. The driver's implicit cache was not disabled; the trace durations are not cold-build measurements.
AI use
Ran via Samaritan:
dc673d702eto419431cf03View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.