Skip to content

Shaders: run single-wave Wave64 mesh groups on Wave32 hosts - #1

Draft
mohammadallami75-ops wants to merge 1 commit into
review/pr-439from
shader/wave64-mesh
Draft

mohammadallami75-ops wants to merge 1 commit into
review/pr-439from
shader/wave64-mesh

Conversation

@mohammadallami75-ops

@mohammadallami75-ops mohammadallami75-ops commented Nov 24, 2026 •

Copy link
Copy Markdown
Owner

Scope

Emulates one 64-thread console mesh wave on Wave32 hardware. This is a dependent draft on Marvisak/VIctory#439 (via upstream Marvisak#320, Marvisak#233 and Marvisak#223), with current upstream main ffe310e in its ancestry. The mesh-only commit is cd5c427. Related upstream reports are #778, #71 and #564. Upstream #578 is a separate refusal path. Upstream currently limits PR creation to collaborators, so this draft is in the fork and shows only the mesh commit.

Mesh shader model 6.6 has no WaveSize declaration. The mesh path uses the flat group ID for console lane numbering, shared-memory gathers and ballots, and uses uniform console branches with EXEC guarding per-lane effects. It orders LDS accesses across both hardware waves and lowers a single allocation that dominates exports to runtime D3D12 mesh output counts, with bounds checks and explicit primitive culling.

Other workgroup sizes, unsupported allocation control flow, DPP/swizzle, scatter permutes, recognized whole-wave reduction sections and descriptor waterfalls are refused on this path. Fixture coverage is synthetic. Title dispatch coverage, world rendering and performance are unverified.

Verification

  • RTX 2080 SUPER, driver 621.01, Ryzen 5 5600, 32 GB RAM, Windows 11 build 26200. The fixture failed on the Shaders: one console wave sharing LDS runs in the console flow on 32-lane hosts Marvisak/VIctory#439 baseline at a mesh lane read. With this commit it passed DXIL validation, matched 1,024 coverage pixels and 276 interpolated depth samples against independent HLSL, and rendered zero covered pixels with the cull bit set.
  • cargo test --workspace --locked: 380 passed, 6 ignored on retry. The first parallel run hit the existing frame-timing test while Clippy was running. A serial workspace run also passed with 380 passed and 6 ignored.
  • Both CI Clippy configurations with -D warnings and cargo xtask policy passed.
  • To repeat the targeted regression, set VICTORY_PC_DXC to the PC dxc.exe and VICTORY_DXIL to its accompanying dxil.dll, then run cargo test -p victory-shader --locked mesh_wave_tests -- --nocapture. The test selects a Wave32-only hardware adapter.

AI assistance: OpenAI Codex authored the implementation and synthetic fixtures and ran the checks on the reporter's machine. No game files were used.

Reuse console control flow, key exchanges by the flat group ID, and lower a single dominating mesh allocation to DXIL output counts. Validate against synthetic HLSL geometry and GPU readback.

AI assistance: OpenAI Codex authored the implementation and synthetic tests and ran the reported checks.
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.

1 participant