tests: verify formatted buffer loads in slot 57 mesh draws #2576

Manually merged
github merged 2 commits from gh-pr/2576/head into gh-pr/2576/base 2026-11-27 01:03:48 +00:00
Owner

@⁠RavenCurseBurg on GitHub · 2026-11-25 21:35 UTC · original
RavenCurseBurg:tests/mesh57-formatted-source → main · +81 −1 · 3 files · 2 commits · merged 2026-11-25 22:10 UTC

Part of #2413, T3. The accepted slot 57 mesh shape already lowers a single-component buffer_load_format_x through the shared MUBUF path. This adds a source-built readback for that path and its descriptor dependency. Claim and scope.

The fixture inserts a gfx1013 formatted load after the raw vertex-colour load. The load replaces red, so the other three channels are independent controls. The host test checks the published buffer SRV and its descword3 source, then checks that overwriting descriptor word 3 in the guest program produces the expected refusal.

The new WARP and hardware CTests read the constant locations from the published manifest. They draw the same compiled mesh/pixel pair with the same 512 bytes of input. Changing only descriptor word 3 selects R32_FLOAT X, RGBA8_UNORM X, or RGBA8_UNORM Z. The CPU reference obtains the expected channel directly from the fixture bytes and rasterizes all 1,024 pixels. The existing raw-draw CTest keeps its own time budget. Same-guest-list loading and indirect forwarding are tracked under R1.

Verification

  • After integrating #2566, Windows Server 2025 Release at ee748000 passed the host, existing WARP mesh draw (including the new wave-uniform branch cases), and formatted WARP draw, 3/3 with zero skips. The original f0402dd1 build passed the same three CTests.
  • On Windows 11 build 26100.9711, I verified the source commit and SHA-256 of the ee748000 build, then ran both draw modes on an NVIDIA RTX 4060 (32.0.15.9579) and WARP (10.0.26100.9711) with DXC 1.9.2609. All three formatted descriptors matched all 1,024 pixels on each adapter. Using the wrong format or channel reference changed exactly 259 pixels in each case. Intel UHD 770 (32.0.101.5973) reported an unsupported mesh shader tier and returned skip code 77 for both modes. The local D3D12 debug layer was unavailable.
  • On the RTX, forcing the compiled shader to use R32_FLOAT broke the UNORM-X case at 259 pixels. Forcing selector X broke the UNORM-Z case at 259 pixels.
  • LLVM 15 reassembled the original mesh, formatted mesh, overwritten-descriptor mesh, and paired pixel program to the fixture words. The standalone Python host test, documentation links, bidi check and git diff --check passed.

AI-assisted with Codex (GPT-6.2 Astra, xhigh).

**@⁠RavenCurseBurg** on GitHub · 2026-11-25 21:35 UTC · [original](https://github.com/R0Y00/Xbox2Windows/pull/2576) `RavenCurseBurg:tests/mesh57-formatted-source` → `main` · +81 −1 · 3 files · 2 commits · merged 2026-11-25 22:10 UTC Part of #2413, T3. The accepted slot 57 mesh shape already lowers a single-component `buffer_load_format_x` through the shared MUBUF path. This adds a source-built readback for that path and its descriptor dependency. [Claim and scope](https://git.gtahub.st/github/R0Y00--Xbox2Windows/issues/2413). The fixture inserts a gfx1013 formatted load after the raw vertex-colour load. The load replaces red, so the other three channels are independent controls. The host test checks the published buffer SRV and its `descword3` source, then checks that overwriting descriptor word 3 in the guest program produces the expected refusal. The new WARP and hardware CTests read the constant locations from the published manifest. They draw the same compiled mesh/pixel pair with the same 512 bytes of input. Changing only descriptor word 3 selects R32_FLOAT X, RGBA8_UNORM X, or RGBA8_UNORM Z. The CPU reference obtains the expected channel directly from the fixture bytes and rasterizes all 1,024 pixels. The existing raw-draw CTest keeps its own time budget. Same-guest-list loading and indirect forwarding are tracked under R1. ### Verification - After integrating #2566, [Windows Server 2025 Release at ee748000](https://github.com/RavenCurseBurg/Xbox2Windows/actions/runs/45709110399) passed the host, existing WARP mesh draw (including the new wave-uniform branch cases), and formatted WARP draw, 3/3 with zero skips. The [original f0402dd1 build](https://github.com/RavenCurseBurg/Xbox2Windows/actions/runs/45704958537) passed the same three CTests. - On Windows 11 build 26100.9711, I verified the source commit and SHA-256 of the ee748000 build, then ran both draw modes on an NVIDIA RTX 4060 (32.0.15.9579) and WARP (10.0.26100.9711) with DXC 1.9.2609. All three formatted descriptors matched all 1,024 pixels on each adapter. Using the wrong format or channel reference changed exactly 259 pixels in each case. Intel UHD 770 (32.0.101.5973) reported an unsupported mesh shader tier and returned skip code 77 for both modes. The local D3D12 debug layer was unavailable. - On the RTX, forcing the compiled shader to use R32_FLOAT broke the UNORM-X case at 259 pixels. Forcing selector X broke the UNORM-Z case at 259 pixels. - LLVM 15 reassembled the original mesh, formatted mesh, overwritten-descriptor mesh, and paired pixel program to the fixture words. The standalone Python host test, documentation links, bidi check and `git diff --check` passed. AI-assisted with Codex (GPT-6.2 Astra, xhigh).
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-27 01:03:47 +00:00
github manually merged commit ee748000a9 into gh-pr/2576/base 2026-11-27 01:03:48 +00:00
This discussion has been locked. Commenting is limited to contributors.
No description provided.