Skip to content

docs/design.md: drop the stitched fragments from the Global atomics row - #3084

Merged
ItsNotRexed merged 1 commit into
ItsNotRexed:mainfrom
UNYTIX:docs-atomics-row-stitch
Nov 22, 2026
Merged

ItsNotRexed merged 1 commit into
ItsNotRexed:mainfrom
UNYTIX:docs-atomics-row-stitch

Conversation

@UNYTIX

@UNYTIX UNYTIX commented Nov 22, 2026

Copy link
Copy Markdown
Contributor

Claim: #2891 (comment)

What and why

The "Global atomics" row in docs/design.md has an older version of itself stitched into it by the round-40 merges. The same cell:

  1. said the float atomics are still Unsupported, two sentences before documenting the fmin/fmax CAS loop — which tools/rdna2spirv.py's global_atomic_float implements (OpAtomicCompareExchange + GLSL.std.450 NMin/NMax, with glsl_op = "NMin" if kind == "fmin" else "NMax");
  2. repeated "Approximation: the returned pair comes from two reads, so another lane's 64-bit op on the same element between them can show up half done (as for ds_and/or/xor_b64)." verbatim — the clause already ends the sentence before it;
  3. kept the older, shorter test_global_atomics.py sentence (without fmin/fmax, NaN/±0/±inf, the CAS contention case, _x2, or test_global_atomics_x2.py).

Only those three fragments are removed. Every fact stays, including the accurate Unsupported list (add/sub/min/max/fmin/fmax_x2, cmpswap_x2, inc/dec, fcmpswap, slc/dlc), the tearing approximation, "Until 2026-11-22 every global atomic was rejected", both test files, the spirv-val note and Not GPU-verified.

Evidence

Counts inside the row, before → after:

probe before after
Still `Unsupported` 2 1
**Approximation:** 2 1
CPU-checked by 2 1
`fmin` and `fmax` 1 1
fcmpswap, `inc`/`dec`, slc`/`dlc`, test_global_atomics_x2 1 each 1 each

Tests

python -I tests/test_docs_design_rows.py    -> Ran 2 tests, OK
python -I tests/test_docs_links.py          -> OK
python -I tests/test_docs_list_items.py     -> OK
python -I tests/test_docs_repo_paths.py     -> OK

No new test: a "no repeated ≥60-character sentence inside a row" guard fails on main today for three unrelated rows (the v_pack_b32_f16 source-modifiers row and the d16 and f16 format narrowing row), so it can only land once those are fixed; tests/test_docs_design_rows.py (one row per topic) remains the guard for this table.

Docs only — no GPU used, no game files, no keys. I checked first that no open PR touches these sentences (#2994, #3005, #2945, #2913 and #2832 are other rows; #2063 removes duplicate rows and is conflicting).

One related line left alone on purpose: tools/rdna2spirv.py's global_atomic docstring still ends with the same stale "the float atomics stay Unsupported". It is a comment-only change in a tool, and a tool edit triggers the full runtime CI run that BUILD-856 is trying to avoid, so it belongs in a translator PR rather than here.

AI-assisted.

The round-40 merges left an older version of the row inside the current one:
it still listed the float atomics as Unsupported (the same row documents the
fmin/fmax CAS loop), repeated the "returned pair comes from two reads"
sentence, and kept the shorter older test_global_atomics.py sentence. Every
fact stays; only those three duplicated fragments go.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <noreply@codebuff.com>
@iurysf

iurysf commented Nov 22, 2026

Copy link
Copy Markdown
Contributor

Code read of b523c58: the three removals are right and nothing is lost.

  • The stale "Still Unsupported: ... the float atomics ..." sentence contradicts the fmin/fmax CAS loop in the same cell, which tools/rdna2spirv.py:1693 (global_atomic_float) and :1725 (NMin/NMax) implement. The remaining "Still Unsupported" list keeps add/sub/min/max/fmin/fmax_x2, cmpswap_x2, inc/dec, fcmpswap, slc/dlc.
  • After the PR the row has each of "Approximation", "the returned pair comes from two reads", "CPU-checked by", test_global_atomics_x2, "Not GPU-verified" exactly once.

Ran at this commit (Windows 11): tests/test_docs_design_rows.py, test_docs_links.py, test_docs_list_items.py, test_docs_repo_paths.py, test_i18n_index.py — all OK; python -I -m unittest discover -s tests/semantic -p "test_global_atomics*.py" — 16 tests OK.

Heads-up: #3065 also rewrites this row. A trial merge of #3084 and #3065 conflicts in docs/design.md, and #3065's version still has two "Approximation:" and two "CPU-checked by" sentences, so whichever lands second needs the clean-up redone by hand.

AI-assisted code read (Claude). No game data used.

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