Skip to content

Find complete shader layout pointer pair - #2668

Open
luckyteagirl wants to merge 1 commit into
xcl-dev:mainfrom
luckyteagirl:codex/check-layout-find-complete-pair
Open

luckyteagirl wants to merge 1 commit into
xcl-dev:mainfrom
luckyteagirl:codex/check-layout-find-complete-pair

Conversation

@luckyteagirl

Copy link
Copy Markdown
Contributor

The BVH layout checker stopped at the first s_and_b32 that masked s1. An unrelated mask could hide a later register pair and cause the checker to skip that shader's loads.

What is in it

  • Choose the first high-register mask with a matching low-register move.
  • Add a synthetic DXBC fixture and mocked disassembly with an unrelated mask before a valid pair, followed by one on-boundary and one off-boundary load.

Tested

  • Main b49be183 reported no table pointer and skipped both loads in the new fixture.
  • python -B -m unittest discover -s scripts -p 'test_*.py': 26 passed, 0 failed, 0 skipped on Windows with Python 3.11. The fixture reaches an existing unclosed-file ResourceWarning in the script.
  • git diff --check passed.

Regression run

  • Not applicable. The change affects only the Python layout checker and its test.

Not tested

  • A live BVH shader pack or native xcl disasm output. The regression uses a synthetic listing.
  • Rust and GPU tests or a retail title run.

AI use

  • Codex (GPT-6.2 Sol) implemented the change and test, verified behavior against main, and drafted this description.

@SlopTart

SlopTart commented Nov 26, 2026 •

Copy link
Copy Markdown

Tested on the Linux/Wine lane, full standard env (AMD rig: Ryzen 9 9900X, 96 GB DDR5, RX 7900 XT 20 GB, Arch kernel 7.2.15, Mesa 26.2.5 RADV, wine-11.0 Proton, rustc 1.94.0; d3d12,d3d12core,dxgi,d3d11,d3d10core=n,b overrides, official DXC kit, VKD3D_CONFIG=ignore_shared_fence, threads=2), head e9f20079, mergeable against main b49be183:
non-gpu suite (--skip gpu::): 596 passed, 3 failed, 4 ignored, 733 filtered.
The failure set is identical to bare main b49be183 measured on the same rig the same day (596 passed, 3 failed): gpu_promoted_uav_clear (our #2490), xma2_source_voice (#2481, vendored-FAudio gate). The third red, the sparse tile video-memory test, is a known batch flake (green solo).
Zero delta from this PR; every test it adds passes inside the suite.
Not tested: gpu suite, Windows native.
Correction: an earlier version of this row reported three extra reds; those runs lacked the d3d12,d3d12core=n,b DLL overrides and hit stub-DLL NOTIMPL artifacts. Re-ran with the standard env, artifacts gone.
AI use: Hermes agent (local Qwen-class) ran the tests and drafted this; I checked it before posting.

@oni-swr

oni-swr commented Nov 26, 2026

Copy link
Copy Markdown
Contributor

Independent native Windows CPU verification at e9f200797c1484e03586c1dc01181a18585c2cb5 against exact parent b49be1836844fe0b0cdb3211dce3cb7fb4e21ac7.

Windows 11 Pro build 26200, Ryzen 7 5700X3D, Python 3.11.9. py -3.11 -B -m unittest discover -s scripts -p 'test_*.py' passed 26 tests at the head and 25 on the parent, with zero failures or skips. The head emitted a ResourceWarning for an unclosed input file.

With a synthetic unrelated mask followed by two complete pairs, the parent reported no table pointer and counted zero loads. The head picked the first complete pair and counted one on-boundary and one off-boundary load. Both revisions handled the single-pair and missing-pair controls as expected. Cargo, GPU, native disassembly and retail smoke were outside this run.

AI use: Codex (gpt-6.2-sol) wrote and ran the synthetic checks and drafted this report.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants