Shaders: include direct sweep settings and exclusions in JSON #1799

Open
github-bot wants to merge 1 commit from github-bot/gh-1799 into main AGit
Owner

@⁠Daydream3r on GitHub · 2026-11-24 20:53 UTC · original
Daydream3r:fix-direct-report-metadata → main · +67 −1 · 3 files · 1 commits · open

Direct shader sweeps could evaluate fewer programs than requested without explaining size exclusions in JSON, and omitted the seed/options needed to reproduce the selection. Add a run object alongside the existing coverage fields; their names and location remain unchanged.

Rebased onto main 082944135cd2b96288470a595861fa608eee08dc. The conflict was adjacent README additions: both main's dispatch-splitting documentation and this JSON metadata documentation are retained. The implementation and regression test applied without changes.

What is in it

  • crates/xcl/src/shaders.rs: report sampling seed/limits, selected records, oversized-program skips and the recorded translation/validation options, including effective --hash overrides.
  • crates/xcl/tests/shaders_e2e.rs: synthetic CLI regression for size exclusion, unlimited sampling and exact-hash overrides, requiring no GPU/DXC/game data.
  • README.md: document the metadata fields and serial sampling for repeatable selection.

Tested

  • RTX 5070 Ti 16 GB, NVIDIA 621.01; Ryzen 7 9800X3D, 64 GB RAM; Windows 11 Pro 25H2 26200.6584; Rust 1.100.0 MSVC, DXC/DXIL 1.9.2609.5. Release builds/CLI/smoke, debug tests.
  • cargo build --release --workspace --locked: passed on clean main and clean head 1e7541986cbf31b9cda0367a0b06fc073c05718e.
  • cargo test --workspace --locked --no-fail-fast -- --test-threads=4: head 1269 passed, 4 failed, 46 ignored; clean main 1268 passed, 4 failed, 46 ignored, both exit 101. The metadata regression executed and passed. Optional XCL_SAMPLE_* inputs unset.
  • The four failures on both revisions are gpu::dxil::fuzz_tests::fuzz_validate_and_gpu_{0,1,2,3}, CreateComputePipelineState 0x8007000E; they remain unresolved.
  • Identical 27 explicit SKIPPED lines: 21 no native wave64, 3 refused per-lane cases (V_MUL_F16, V_PK_MUL_F16, V_CVT_F16_F32), 2 missing D3D12 debug-layer checks, 1 no heap windows. Passing-return skips are not coverage.
  • Release CLI on a local shader pack: xcl shaders <pack> --direct --sample 32 --seed 20261124 --validate --compare --max-bytes 16384 --timeout 10 --threads 1 --json: exit 0. run reports seed 20261124, 32 selected records and 1 size exclusion; coverage reports 31 evaluated/translated, 0 unsupported, 0 validator failures/panics/timeouts. Effective metadata assertions also passed. This does not claim GPU execution/output parity.
  • git diff --check: passed.

Regression run
Official scripts/smoke.ps1, same retail package 1.0.2.1, 60 s, no input, networking off, isolated copies of the same saved data/cache seed. Head run performed after pushing the rebased commit. Startup/menu coverage only; these runs do not exercise the JSON command or confirm world rendering.

main:

xcl-smoke v1
commit: 082944135cd2b96288470a595861fa608eee08dc
gpu: NVIDIA GeForce RTX 5070 Ti
title: retail-title
seconds: 60
exit: 0x0
frames shown: 1638 (PresentX 1638)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 16370 MB

head:

xcl-smoke v1
commit: 1e7541986cbf31b9cda0367a0b06fc073c05718e
gpu: NVIDIA GeForce RTX 5070 Ti
title: retail-title
seconds: 60
exit: 0x0
frames shown: 1604 (PresentX 1604)
presents per 2 s (last 3): 60 60 60
device removals: 0
crashes: 0
peak commit: 15793 MB

Not tested
AMD/Intel/native wave64, Linux/Wine, game-data sample coverage in the full suite, rendered gameplay or GPU output parity. This CLI metadata change does not claim to fix loading or the four baseline GPU-fuzz failures.

AI use
Codex desktop, GPT-6 (exact variant not exposed): original implementation/regression/docs, conflict resolution, actual local builds/tests/CLI/smoke runs and this description. No game data or derived shader binaries in the diff.

**@⁠Daydream3r** on GitHub · 2026-11-24 20:53 UTC · [original](https://github.com/xcl-dev/xcl/pull/1799) `Daydream3r:fix-direct-report-metadata` → `main` · +67 −1 · 3 files · 1 commits · open Direct shader sweeps could evaluate fewer programs than requested without explaining size exclusions in JSON, and omitted the seed/options needed to reproduce the selection. Add a `run` object alongside the existing coverage fields; their names and location remain unchanged. Rebased onto `main 082944135cd2b96288470a595861fa608eee08dc`. The conflict was adjacent README additions: both main's dispatch-splitting documentation and this JSON metadata documentation are retained. The implementation and regression test applied without changes. **What is in it** - `crates/xcl/src/shaders.rs`: report sampling seed/limits, selected records, oversized-program skips and the recorded translation/validation options, including effective `--hash` overrides. - `crates/xcl/tests/shaders_e2e.rs`: synthetic CLI regression for size exclusion, unlimited sampling and exact-hash overrides, requiring no GPU/DXC/game data. - `README.md`: document the metadata fields and serial sampling for repeatable selection. **Tested** - RTX 5070 Ti 16 GB, NVIDIA 621.01; Ryzen 7 9800X3D, 64 GB RAM; Windows 11 Pro 25H2 26200.6584; Rust 1.100.0 MSVC, DXC/DXIL 1.9.2609.5. Release builds/CLI/smoke, debug tests. - `cargo build --release --workspace --locked`: passed on clean main and clean head `1e7541986cbf31b9cda0367a0b06fc073c05718e`. - `cargo test --workspace --locked --no-fail-fast -- --test-threads=4`: head **1269 passed, 4 failed, 46 ignored**; clean main **1268 passed, 4 failed, 46 ignored**, both exit 101. The metadata regression executed and passed. Optional `XCL_SAMPLE_*` inputs unset. - The four failures on both revisions are `gpu::dxil::fuzz_tests::fuzz_validate_and_gpu_{0,1,2,3}`, `CreateComputePipelineState 0x8007000E`; they remain unresolved. - Identical 27 explicit SKIPPED lines: 21 no native wave64, 3 refused per-lane cases (V_MUL_F16, V_PK_MUL_F16, V_CVT_F16_F32), 2 missing D3D12 debug-layer checks, 1 no heap windows. Passing-return skips are not coverage. - Release CLI on a local shader pack: `xcl shaders <pack> --direct --sample 32 --seed 20261124 --validate --compare --max-bytes 16384 --timeout 10 --threads 1 --json`: exit 0. `run` reports seed 20261124, 32 selected records and 1 size exclusion; coverage reports 31 evaluated/translated, 0 unsupported, 0 validator failures/panics/timeouts. Effective metadata assertions also passed. This does not claim GPU execution/output parity. - `git diff --check`: passed. **Regression run** Official `scripts/smoke.ps1`, same retail package 1.0.2.1, 60 s, no input, networking off, isolated copies of the same saved data/cache seed. Head run performed after pushing the rebased commit. Startup/menu coverage only; these runs do not exercise the JSON command or confirm world rendering. main: ``` xcl-smoke v1 commit: 082944135cd2b96288470a595861fa608eee08dc gpu: NVIDIA GeForce RTX 5070 Ti title: retail-title seconds: 60 exit: 0x0 frames shown: 1638 (PresentX 1638) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 16370 MB ``` head: ``` xcl-smoke v1 commit: 1e7541986cbf31b9cda0367a0b06fc073c05718e gpu: NVIDIA GeForce RTX 5070 Ti title: retail-title seconds: 60 exit: 0x0 frames shown: 1604 (PresentX 1604) presents per 2 s (last 3): 60 60 60 device removals: 0 crashes: 0 peak commit: 15793 MB ``` **Not tested** AMD/Intel/native wave64, Linux/Wine, game-data sample coverage in the full suite, rendered gameplay or GPU output parity. This CLI metadata change does not claim to fix loading or the four baseline GPU-fuzz failures. **AI use** Codex desktop, GPT-6 (exact variant not exposed): original implementation/regression/docs, conflict resolution, actual local builds/tests/CLI/smoke runs and this description. No game data or derived shader binaries in the diff.
Record the effective sampling options and oversized exclusions alongside the existing coverage fields. Exercise capped samples, unlimited samples and exact-hash overrides through the CLI.

Assisted-by: Codex desktop (GPT-6)
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 05:05:38 +00:00
Author
Owner

@⁠DavidM1911 on GitHub · 2026-11-25 00:05 UTC · original

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

  • cargo test -p xcl --lib: all passed, 0 failed, ~23 ignored.

Thanks!

**@⁠DavidM1911** on GitHub · 2026-11-25 00:05 UTC · [original](https://github.com/xcl-dev/xcl/pull/1799#issuecomment-7148118971) Verification on RTX 3060 Ti (Windows 11), branch merged with current `main`: - `cargo test -p xcl --lib`: all passed, 0 failed, ~23 ignored. Thanks!
Author
Owner

@⁠DavidM1911 on GitHub · 2026-11-26 06:19 UTC · original

Re-verification on RTX 3060 Ti (Windows 11): still a merge conflict with current main on the new head — needs another rebase before it can be tested.

**@⁠DavidM1911** on GitHub · 2026-11-26 06:19 UTC · [original](https://github.com/xcl-dev/xcl/pull/1799#issuecomment-7184323187) Re-verification on RTX 3060 Ti (Windows 11): still a **merge conflict with current `main`** on the new head — needs another rebase before it can be tested.
Author
Owner

@⁠luckyteagirl on GitHub · 2026-11-26 10:52 UTC · original · reviewed

On 1e7541986cbf31b9cda0367a0b06fc073c05718e, could the JSON run.selected_records field count records that pass --hash, or be named/documented as the pre-filter candidate count? The hash branch replaces order with all input indices, and the new field uses order.len(); the actual hash comparison happens later in the worker. Thus a pack with 26,503 records and one matching hash reports 26,503 selected records, and an unmatched hash in a one-record pack reports 1 selected record despite no match. This makes the machine-readable run metadata misleading for the targeted hash workflow. I verified the control flow from exact-head source; I did not run a pack.

AI use: OpenAI Codex (GPT-6.2 Sol) found and checked the path; OpenAI Codex (GPT-6.2 Astra) independently checked the source and wrote this review.

**@⁠luckyteagirl** on GitHub · 2026-11-26 10:52 UTC · [original](https://github.com/xcl-dev/xcl/pull/1799#pullrequestreview-6072837075) · **reviewed** On `1e7541986cbf31b9cda0367a0b06fc073c05718e`, could the JSON `run.selected_records` field count records that pass `--hash`, or be named/documented as the pre-filter candidate count? The hash branch replaces `order` with all input indices, and the new field uses `order.len()`; the actual hash comparison happens later in the worker. Thus a pack with 26,503 records and one matching hash reports 26,503 selected records, and an unmatched hash in a one-record pack reports 1 selected record despite no match. This makes the machine-readable run metadata misleading for the targeted hash workflow. I verified the control flow from exact-head source; I did not run a pack. AI use: OpenAI Codex (GPT-6.2 Sol) found and checked the path; OpenAI Codex (GPT-6.2 Astra) independently checked the source and wrote this review.
This pull request has changes conflicting with the target branch.
  • crates/xcl/tests/shaders_e2e.rs
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.
git fetch -u origin '+refs/pull/1799/head:github-bot/gh-1799'
git switch 'github-bot/gh-1799'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-1799'
git switch 'github-bot/gh-1799'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-1799'
git switch 'github-bot/gh-1799'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-1799'
git switch 'main'
git merge --squash 'github-bot/gh-1799'
git switch 'main'
git merge --ff-only 'github-bot/gh-1799'
git switch 'main'
git merge 'github-bot/gh-1799'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.