numwaves-anchored-cap
Status: stub. The full-length analysis is queued for a v1.0.x patch release per ADR 0018, section 5, criterion #6. The companion rule page at docs/rules/numwaves-anchored-cap.md contains the canonical detection logic + GPU reasoning.
TL;DR
The current per-group lane cap is 1024 across every modern IHV (D3D12 spec limit). Exceeding it is a hard validator error in DXC -- but the proposal 0054 horizon adds a numWaves attribute that may relax this. Until 0054 ships, exceedance is an error worth flagging early.
What the rule fires on
A [numthreads(X, Y, Z)] declaration where X * Y * Z > 1024 (the current per-thread-group lane cap). Defensive rule for HLSL Specs proposal 0054 (numWaves, under-consideration).
See the What it detects section of the rule page for the full pattern definition.
Why it matters
The full GPU-mechanism analysis lives in the Why it matters on a GPU section of the companion rule page.
Examples
The bad / good code snippets are kept canonical on the rule page; see numwaves-anchored-cap.md -> Examples.
See also
- Rule page -- canonical reference + change log.
- workgroup overview -- broader context.
- ADR 0018 -- v1.0 readiness plan.
This is a v1.0-ship stub. Full analysis pending; track issue link TBD.