Repository navigation
Docs: no game CS takes the SHADER-309 LDS bounds check; drop the stale hypothesis - #3941
465d6a0eac wants to merge 2 commits into
Conversation
|
Independent recount with my own 1.0.2.1 copy (Apple M4, Python 3.15): your numbers hold exactly. At
That is the same split as your table, with the 485 read from the translator rather than from the FSSM header. So the rewritten row and the comment are right: no game CS takes the SHADER-309 bounds check. On
No game data (counts only). AI-assisted. |
|
Independently checked the LDS census in e2c7d8f from my local 1.0.2.1 package. CachyOS Linux 7.3.5, LLVM 23.1.5, translator aa2988c. I ran all 2,689 compute listings through translate() in native mode and with wave64 emulation. Both modes translated all 2,689, with 485 LDS users, zero constant extents beyond the declared allocation and zero shaders setting lds_bound. These are CPU-side translator counts. No game data attached. |
|
Checked this on my machine (RTX 2070, Linux), one data point for the pile:
One honest limit: my local shader carve is 11,983 blobs and contains no CS with LDS memory access at all (only |
|
Checked against my own 1.0.2.1 copy (counts only) at I translated every corpus compute shader (2,689
So no game CS takes the bounds-checked path at the default cap, either way, which is what the updated row says. A related number for the 32 KiB drivers (AMD Windows, which this row measures on an RX 9070 XT, and Intel). In the full-corpus AI-assisted (Claude Code). |
docs/design.md conflicted in the Workgroup memory limit (SHADER-309) row: main added the SHADER-579 clause (the 3 barrier-round counts move into the LDS array past 16,384 B), this branch rewrote the hypothesis sentence. Both kept. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G9awjJFWaLKL6vcYaYtu2r
|
Merged Recount at the merge, so the claim holds on today's
Tested under WSL Ubuntu (Python 3.14.4, llvm-mc 21.1.8), CPU only. AI-assisted (Claude Code). |
kacper-serewis
left a comment
There was a problem hiding this comment.
Independent AI-assisted CPU check at ae06ddd: please qualify the zero guard-selection count with the default 65,536-byte cap. At 32,768 and 16,384 bytes the wave64 emulation translator selected bounded LDS for 24 and 32 cached FSSM compute shaders respectively. Native selected zero at both. At default cap the full-corpus selection check found zero candidates in both modes. The adjacent LDS row still reports 15/486 overruns. Across 2,689 FSSM compute exports 485 used LDS; exact access widths gave zero constant-offset overruns, versus 37 flagged by the historical four-dword estimate. The 29 FSPX compute exports added five LDS users and zero overruns. All 15 shared-memory tests passed; this was not full emitted-module or GPU validation. A trial merge with #3422 conflicts only in docs/design.md; preserve its reachable full-LDS fallback when combining the two.
|
Independent recount of ae06ddd on my own 1.0.2.1 package, by running
Not re-measured: the figure of 37 for the old bound, and the 32768-byte variant from the review. Counts only; AI-assisted (Claude Code). |
|
Tested ae06ddd merged with main 3faac55 on Linux (WSL2), Python 3.12.16: concern.
|
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> # Conflicts: # docs/design.md
…pothesis e2c7d8f (this branch's change) is on main, but the round-44 docs pass (2e52b2f) put the old "Hypothesis, not yet counted over the corpus: the 16 of 486 ..." sentences back into the Workgroup memory limit (SHADER-309) row, next to the "No game shader takes this path" text that replaced them. The row now says both. Keep main's two new rows (Wave64 leading-bit scans, scalar exits from a folded EXECZ region) and take the row without the re-added sentences, so the branch's diff to main is that removal. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G9awjJFWaLKL6vcYaYtu2r
|
Merged
AI-assisted (Claude Code). |
…ER-309 row The round-44 docs pass (2e52b2f, "one row per topic") merged three copies of the "Workgroup memory limit (SHADER-309)" row into one. Two of them predated e2c7d8f (ItsNotRexed#3941), so the merged row put back "Hypothesis, not yet counted over the corpus: the 16 of 486 ..." and towade's older count sentence. Both now sat after the "No game shader takes this path" text that replaced them. Remove them. The LDS-bounds part of the row is again the same as in e2c7d8f. Found by 465d6a0eac in ItsNotRexed#5781. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
shayderrr
left a comment
There was a problem hiding this comment.
Review
Reviewed documentation in PR #3941: Docs: no game CS takes the SHADER-309 LDS bounds check; drop the stale hypothesis.
Scope: docs/design.md
Diff: +1 / -1 across 1 file(s).
The change stays inside the stated scope and the touched files line up with the description. No unrelated production paths are pulled in, and the stated behavior is directly exercised by the diff. I'm approving this one.
Reviewed by shayderrr via automated batch review.
|
Thanks @465d6a0eac - I went through Docs: no game CS takes the SHADER-309 LDS bounds check; drop the stale hypothesis and the diff around |
Claimed in the coordination issue as: new docs item, SHADER-309 follow-up
What and why
The "Workgroup memory limit (SHADER-309)" row in
docs/design.mdcontradicts itself. It still says "Hypothesis, not yet counted over the corpus: the 16 of 486 LDS-using CS that index past LDS_SIZE with constant offsets (the Compute shaders row) now read 0 there", and the very next sentence is towade's count (#1882) answering it: none of the 485 does. That count also points at "the Compute shaders row" for the 16 of 486, but that row no longer has the figure. The only other copy is a comment intools/rdna2spirv.pyat the CS RSRC2 block, which still says "470 of 486 LDS-using CS stay below it; the rest index past it".This PR merges the two sentences into one statement: no game shader takes the bounds-checked path, so only the synthetic tests exercise it. It adds my independent recount and fixes the code comment. No behaviour change.
When I claimed this I hadn't seen towade's sentence; it arrived on
mainin the last merge round. This PR therefore confirms that count rather than replacing it.Measured (my own 1.0.2.1 copy, counts only)
At
mainaa2988cc, I ranrdna2spirv.translate()on each of the 2,689 CS and read theGenit builds (lds_declared,lds_need,lds_bound, and calls tolds_access), natively and with--wave64-emulate:--wave64-emulateLDS_SIZE0ds_const_extent)lds_boundset), including a shrunk arrayoffset // 4 + 4boundSo "16 of 486" came from the older estimate, as towade's sentence says. That bound flags 37 of the 485 today, and every one of them is inside its allocation once the access width is counted. The 485 agree with the FSSM header's LDS byte count at
+0x10C, which is non-zero in exactly 485 CS.Tested
python -I tests/test_docs_*.py: all 7 OK (design_rows,links,list_items,repo_paths,table_rows,cli_flags,python_deps).compileallontools/rdna2spirv.pyis clean, and so isgit diff --check.tests/semantic/test_cs_shared_memory_limit.pyin WSL (llvm-mc 21.1.8, SPIRV-Tools v2026.1): 15 tests OK.--limit 200slice fromaa2988ccand from this branch is byte-identical, 200 translated and 200 passingspirv-valboth times.Checklist
docs/design.md, with how it was confirmed. (n/a: no rule changes)AI-assisted (Claude Code).
🤖 Generated with Claude Code