Scripts: show register spaces in BVH shader bindings #1759

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

@⁠NemesisDawn on GitHub · 2026-11-24 20:18 UTC · original
NemesisDawn:fix/bvhb-register-spaces → main · +43 −14 · 2 files · 1 commits · open

Show nonzero register spaces in the BVHB shader binding report so bindings that share a register number can be distinguished.

What is in it

  • scripts/re/bvhb_shaders.py reports spaces for root constants, root descriptors, and descriptor table ranges. scripts/test_bvhb_shaders.py covers zero and nonzero spaces.

Tested

  • At 2eede34, python -B scripts/test_bvhb_shaders.py passed both tests on Windows with synthetic root-signature inputs.

Not tested

  • Retail BVHB shader data and the full Cargo workspace suite on a GPU.

AI use

  • OpenAI Codex (GPT-6, exact variant unavailable) wrote the patch and regression tests, ran the focused checks, and drafted this description.
**@⁠NemesisDawn** on GitHub · 2026-11-24 20:18 UTC · [original](https://github.com/xcl-dev/xcl/pull/1759) `NemesisDawn:fix/bvhb-register-spaces` → `main` · +43 −14 · 2 files · 1 commits · open Show nonzero register spaces in the BVHB shader binding report so bindings that share a register number can be distinguished. **What is in it** - `scripts/re/bvhb_shaders.py` reports spaces for root constants, root descriptors, and descriptor table ranges. `scripts/test_bvhb_shaders.py` covers zero and nonzero spaces. **Tested** - At `2eede34`, `python -B scripts/test_bvhb_shaders.py` passed both tests on Windows with synthetic root-signature inputs. **Not tested** - Retail BVHB shader data and the full Cargo workspace suite on a GPU. **AI use** - OpenAI Codex (GPT-6, exact variant unavailable) wrote the patch and regression tests, ran the focused checks, and drafted this description.
Include nonzero spaces for constants, root descriptors, and table
ranges so bindings at the same shader register can be distinguished.

Assisted-by: OpenAI Codex (GPT-6, exact variant unavailable)
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 05:04:05 +00:00
Author
Owner

@⁠futurepro62 on GitHub · 2026-11-24 21:14 UTC · original

Tested exact head 2eede34, script tests only, since this PR has no test report yet.

Tested

  • Windows 11 Home 26300, Python 3.14.3 with pytest 9.0.3, Windows PowerShell 5.1.26100.9818 (no PowerShell 7 here).
  • python -m pytest scripts/test_bvhb_shaders.py at the head: 2 passed, 4 subtests passed.
  • The PR's test file against current main's script (266b845): 2 failed, 2 passed. So the new test catches the problem the PR fixes.

Not tested

  • PowerShell 7, the CI workflow itself, a game (no runtime code changed).

AI use

  • Claude Code (Claude Opus 5.5) ran the tests and wrote this report. I checked it before posting.
**@⁠futurepro62** on GitHub · 2026-11-24 21:14 UTC · [original](https://github.com/xcl-dev/xcl/pull/1759#issuecomment-7144669775) Tested exact head `2eede34`, script tests only, since this PR has no test report yet. **Tested** - Windows 11 Home 26300, Python 3.14.3 with pytest 9.0.3, Windows PowerShell 5.1.26100.9818 (no PowerShell 7 here). - `python -m pytest scripts/test_bvhb_shaders.py` at the head: 2 passed, 4 subtests passed. - The PR's test file against current main's script (`266b845`): 2 failed, 2 passed. So the new test catches the problem the PR fixes. **Not tested** - PowerShell 7, the CI workflow itself, a game (no runtime code changed). **AI use** - Claude Code (Claude Opus 5.5) ran the tests and wrote this report. I checked it before posting.
Author
Owner

@⁠DavidM1911 on GitHub · 2026-11-24 23:04 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. (Intermittent single-test flake under parallel scheduling; clean on single-threaded rerun — same flake seen on unmodified main.)

Thanks!

**@⁠DavidM1911** on GitHub · 2026-11-24 23:04 UTC · [original](https://github.com/xcl-dev/xcl/pull/1759#issuecomment-7146987480) Verification on RTX 3060 Ti (Windows 11), branch merged with current `main`: - `cargo test -p xcl --lib`: all passed, 0 failed, ~23 ignored. (Intermittent single-test flake under parallel scheduling; clean on single-threaded rerun — same flake seen on unmodified `main`.) Thanks!
Author
Owner

@⁠JJAutoCompare on GitHub · 2026-11-25 01:18 UTC · original

Tested

  • Exact PR head 2eede34dbb94ad3c95f5aa5e128b21ef0bf798e1, with a clean detached worktree before and after both runs. Windows 11 Enterprise Evaluation x64 (26200.9974), AMD Ryzen 7 3800X, portable CPython 3.13.7 x64 (NuGet).
  • python -B scripts/test_bvhb_shaders.py -v — 2 passed, 0 failed, 0 ignored, 0 skipped.
  • python -B L:/XclTooling/pr1759-2eede34/check_mixed_spaces.py -v — 2 passed, 0 failed, 0 ignored, 0 skipped. This local harness ran scripts/re/bvhb_shaders.py on one synthetic fixture per root-signature version (1.0 and 1.1). It checked the complete stdout line, empty stderr, and byte-for-byte extraction of each embedded DXBC container. Both versions printed these bindings:
consts b17 space42 x6 | consts b17 x2 | CBV b17 space9 | SRV t17 | UAV u17 space31 | table[SRVx3@12,SRVx2@12 space18,UAVx4@6 space27]

Not tested

Retail DLLs or game assets, GPU execution, Cargo workspace tests, and GitHub Actions.

AI use

Codex (gpt-6.2-sol) created the temporary harness, ran both suites, and wrote this report.

**@⁠JJAutoCompare** on GitHub · 2026-11-25 01:18 UTC · [original](https://github.com/xcl-dev/xcl/pull/1759#issuecomment-7149422449) **Tested** - Exact PR head `2eede34dbb94ad3c95f5aa5e128b21ef0bf798e1`, with a clean detached worktree before and after both runs. Windows 11 Enterprise Evaluation x64 (26200.9974), AMD Ryzen 7 3800X, portable CPython 3.13.7 x64 (NuGet). - `python -B scripts/test_bvhb_shaders.py -v` — 2 passed, 0 failed, 0 ignored, 0 skipped. - `python -B L:/XclTooling/pr1759-2eede34/check_mixed_spaces.py -v` — 2 passed, 0 failed, 0 ignored, 0 skipped. This local harness ran `scripts/re/bvhb_shaders.py` on one synthetic fixture per root-signature version (1.0 and 1.1). It checked the complete stdout line, empty stderr, and byte-for-byte extraction of each embedded DXBC container. Both versions printed these bindings: ```text consts b17 space42 x6 | consts b17 x2 | CBV b17 space9 | SRV t17 | UAV u17 space31 | table[SRVx3@12,SRVx2@12 space18,UAVx4@6 space27] ``` **Not tested** Retail DLLs or game assets, GPU execution, Cargo workspace tests, and GitHub Actions. **AI use** Codex (gpt-6.2-sol) created the temporary harness, ran both suites, and wrote this report.
Author
Owner

@⁠RavenCurseBurg on GitHub · 2026-11-25 20:05 UTC · original · edited 2026-11-25 20:14 UTC

Tested on 2eede34dbb94ad3c95f5aa5e128b21ef0bf798e1 and its parent c160d86ef2efe3a07e4dfb473e4fa72eafb413c0. Windows 11 build 26100.9711, Core i7-13700, Python 3.14.3.

I ran python -B scripts/re/bvhb_shaders.py synthetic.bin out with two generated DXBC containers, one root signature v1.0 and one v1.1. Each had two SRV ranges on register 8: count 2 in space 3, then an unbounded range in space 7. With redirected UTF-8 stdout, the PR head reported both spaces on both lines and the extracted containers matched the source bytes.

With PYTHONIOENCODING=cp1252:strict and redirected stdout, the head and parent both exited 1 with UnicodeEncodeError while printing the infinity symbol. Each wrote the first container intact, printed no summary and stopped before extracting the second. The encoding failure predates this PR.

The candidate follow-up with a regression test prints unbounded in place of the glyph. Under both encodings it produced both summaries and two byte-identical outputs. The ranges read table[SRVx2@8 space3,SRVxunbounded@8 space7]. The new regression failed for both versions on the PR head. On the candidate, python -B scripts/test_bvhb_shaders.py passed 3/3 and python -B -m unittest discover -s scripts passed 18/18.

Not tested — A retail DLL, shader execution, or the Rust workspace suite. OpenAI Codex (GPT-6) generated the inputs, wrote and tested the follow-up, and prepared this report.

**@⁠RavenCurseBurg** on GitHub · 2026-11-25 20:05 UTC · [original](https://github.com/xcl-dev/xcl/pull/1759#issuecomment-7173176590) · edited 2026-11-25 20:14 UTC **Tested** on `2eede34dbb94ad3c95f5aa5e128b21ef0bf798e1` and its parent `c160d86ef2efe3a07e4dfb473e4fa72eafb413c0`. Windows 11 build 26100.9711, Core i7-13700, Python 3.14.3. I ran `python -B scripts/re/bvhb_shaders.py synthetic.bin out` with two generated DXBC containers, one root signature v1.0 and one v1.1. Each had two SRV ranges on register 8: count 2 in space 3, then an unbounded range in space 7. With redirected UTF-8 stdout, the PR head reported both spaces on both lines and the extracted containers matched the source bytes. With `PYTHONIOENCODING=cp1252:strict` and redirected stdout, the head and parent both exited 1 with `UnicodeEncodeError` while printing the infinity symbol. Each wrote the first container intact, printed no summary and stopped before extracting the second. The encoding failure predates this PR. The [candidate follow-up with a regression test](https://github.com/RavenCurseBurg/xcl/commit/383e9695299018fb5be9fe5908f5a8f90ce17a5b) prints `unbounded` in place of the glyph. Under both encodings it produced both summaries and two byte-identical outputs. The ranges read `table[SRVx2@8 space3,SRVxunbounded@8 space7]`. The new regression failed for both versions on the PR head. On the candidate, `python -B scripts/test_bvhb_shaders.py` passed 3/3 and `python -B -m unittest discover -s scripts` passed 18/18. **Not tested** — A retail DLL, shader execution, or the Rust workspace suite. OpenAI Codex (GPT-6) generated the inputs, wrote and tested the follow-up, and prepared this report.
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/1759/head:github-bot/gh-1759'
git switch 'github-bot/gh-1759'

Merge

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