Skip to content

docs/design.md: one copy of each rule in the Global atomics row (stitched again after #3084) - #4879

Open
LouisRiverstone wants to merge 1 commit into
ItsNotRexed:mainfrom
LouisRiverstone:docs-global-atomics-row
Open

LouisRiverstone wants to merge 1 commit into
ItsNotRexed:mainfrom
LouisRiverstone:docs-global-atomics-row

Conversation

@LouisRiverstone

Copy link
Copy Markdown
Contributor

docs/design.md's "Global atomics (global_atomic_*, 32-bit)" row was stitched again after #3084 cleaned it. On main it held:

  • three contradictory "Still Unsupported" sentences. The first still lists inc/dec and the float atomics, which main translates (atomic_inc_dec_cas, global_atomic_float).
  • two copies each of the glc, cmpswap, and/or/xor/swap_x2 and approximation sentences, and two "CPU-checked by" lists.
  • the inc/dec sentence cut in half at its escaped \|\|: the first half was followed by the glc sentence, and the second half came after the first Not GPU-verified.

Change. The row keeps one copy of each rule, always the newest wording already in it (nothing is reworded):

  • the inc/dec sentence joined back whole
  • the last "Still Unsupported" list (add/sub/min/max/inc/dec/fmin/fmax_x2, cmpswap_x2, fcmpswap, slc/dlc)
  • the longest "CPU-checked" list, which names all three test files

It also adds one sentence pointing to the "Atomic natural alignment" row for the unaligned-lane rule, without repeating it. The row goes from 4,730 to 3,011 characters.

tools/rdna2spirv.py: global_atomic's docstring said the same stale thing ("inc/dec stay Unsupported"). It now says how inc/dec and fmin/fmax are lowered, and that fcmpswap stays Unsupported. Docstring only, no behaviour change.

Checked:

  • every kept claim against tools/rdna2spirv.py on main
  • the tests/test_docs_*.py checks (design_rows, table_rows, links, list_items, repo_paths) pass
  • test_global_atomics.py and test_atomic_inc_dec.py pass

#3637 (other rows' leftovers) doesn't touch this row. My open #3065, #3153 and #3193 each edit this row's "Still Unsupported" sentence. Whichever lands second gets a one-sentence rebase, which I'll do.

Docs and a docstring only. No game files. Claimed on #4816 before starting.

AI-assisted (Claude Code): I reviewed and ran the checks.

…ched again after ItsNotRexed#3084)

Later merges re-stitched the row ItsNotRexed#3084 cleaned: it had three contradictory
'Still Unsupported' sentences (the first still listing inc/dec and the float
atomics, which main translates), two copies of the glc, cmpswap, _x2 and
approximation sentences, two CPU-checked lists, and the inc/dec sentence cut
in half at its escaped '||' with the second half after the first 'Not
GPU-verified'. The row now keeps one copy of each rule, the newest wording
already in it, the inc/dec sentence whole, and a pointer to the natural
alignment row. global_atomic's docstring said the same stale thing about
inc/dec; it now names how inc/dec and fmin/fmax are lowered and that
fcmpswap stays Unsupported. No behaviour change.
@DenRakEiw

Copy link
Copy Markdown

Tested head 43a4b5d5280b4adc77f662f8bb4227d9ba67cde3 on Windows 11 / Python 3.12.10.

  • Trial-merge (origin/main): clean (git merge --no-commit --no-ff FETCH_HEAD exited 0 with Auto-merging docs/design.md; git diff --cached --check clean).
  • Tests:
    • python -I tests/test_docs_design_rows.py -v: 4 passed (0 failed)
    • python -I tests/test_docs_links.py -v: 6 passed (0 failed)
    • python -I -m compileall -q tools/rdna2spirv.py: exited 0
  • Code read: tools/rdna2spirv.py updates Gen.global_atomic's docstring to match its already-implemented atomic_inc_dec_cas and global_atomic_float branches and remaining Unsupported forms, while docs/design.md reconciles the Global atomics table row cleanly.

AI-assisted review (Gemini 4 Neon).

@LouisRiverstone

Copy link
Copy Markdown
Contributor Author

Thanks @DenRakEiw, on the current head 43a4b5d5. Nothing is pending. #4891 does the same kind of cleanup for the Known approximations and 64-bit scalar bitwise rows.

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.

2 participants