Shaders: --explain reports the HLSL path: HLSL, DXC per pass, DXIL #1957
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!1957
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-1957"
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?
@sombraSoft on GitHub · 2026-11-24 23:51 UTC · original
sombraSoft:shaders/explain-hlsl→main· +2152 −21 · 12 files · 6 commits · draftStacked on #1955 and #1956; the top two commits belong here. Part of #1269.
--explainreports the HLSL path too: the HLSL by the console instruction that wrote it, DXC's time per pass and peak commit, and the DXIL's structure, next to the direct path.--path both|hlsl|direct,--opt,--top.Pass times need a process per compile: XCL's in-process DXC prints
-ftime-reportonly at exit, summed over every compile. So each program is compiled by the SDK'sdxc.exenext to thedxcompiler.dllXCL loads, withdxc::arguments(#1956), in a job object with a commit limit (--mem-gb, default 8) and stopped after--dxc-timeout(default 600 s). Without a limit, on main atc160d86the pack's largest compute program (then 147 MB of HLSL,-O0) ran DXC for over 40 minutes up to 13 GB and grew the page file by about 88 GB. A compile past a limit is now stopped and reported as unfinished.What is in it
Shaders: --size-by-op splits translated HLSL bytes by instruction– by @DTsordas (DTsordas/xcl@5529418, posted in #1269 and never opened as a PR), kept as their commit;shaders.rsShaders: --explain reports the HLSL path: HLSL, DXC per pass, DXIL–crates/xcl/src/shaders/explain/hlsl.rs, hooks inexplain.rs,limits.rs; help and READMETested
cargo test --workspace --no-fail-fast -- --test-threads=4onb73a434: 987 passed, 0 failed, 45 ignoredSKIPPED(all from existing tests): 18 × no wave64, 1 × no heap windows, 1 × cannot disable the driver cache (Developer Mode off), 3 × per-lane form refused (f16 / VOP3 modifiers)dxc.exepast its time limit or under a 1 MB commit limit is stopped withtimeout:/memory:; the determinism test now covers both pathsfb2eeec(the top of this stack): 20 sampled programs (--sample 20 --seed 1) take 56 s, 54 s of it in DXC; two runs give the same portable digest. The largest compute program: 15 MB of HLSL, DXC-O0120 s at 2.7 GB of commit (Loop-Closed SSA 24 %, DXIL Remove Dead Blocks 16 % of the pass time), 80 295 DXIL blocks; the direct path gives 36 818Regression run
main:
this PR (
b73a434):Not tested
dxc.exemissing next todxcompiler.dll(e.g.XCL_DXC_DIRwith the DLLs only): the in-process fallback without pass times was run, but not on the packAI use
@DavidM1911 on GitHub · 2026-11-25 02:59 UTC · original
Verification on RTX 3060 Ti (Windows 11): merge conflict with current
main(README.md+crates/xcl/src/shaders.rs) — needs a rebase before it can be tested.View command line instructions
Manual merge helper
Use this merge commit message when completing the merge manually.
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.