wave64_halves: model image_atomic_* as atomic memory sinks (SHADER-W64-HALVES-IMAGE-ATOMIC) #1907
No reviewers
No assignees
Labels
No labels
bug
dependencies
documentation
enhancement
missing claim
needs rebase
needs-triage
question
ready-for-agent
submodules
No project
No milestone
Dependencies
No dependencies set
Notifications
1 participant
Due date
No due date set.
Reference
leonida/mandy!1907
Loading…
Reference in a new issue
No description provided.
Delete branch "contrib/w64-halves-image-atomic"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Pull request successfully merged and closed
Claimed in the coordination issue as: SHADER-W64-HALVES-IMAGE-ATOMIC
What and why
tools/wave64_halves.pydid not classifyimage_atomic_*instructions as atomic memory sinks:operands()(tools/wave64_halves.py:290-292): added"image_atomic"alongside"global_atomic"/"flat_atomic"sodests = [a[0]]only when"glc"is present andsrcs = list(a).Analysis.transfer()(tools/wave64_halves.py:723-757): routed"image_atomic"into the atomic sink handler (data_op = a[0],addr_ops = list(a[1:])), and updated theelectedaddress VGPR uniformity check to iterate_regs(x)(isinstance(r, tuple) and r[0] == "v") instead of onlyx.get("k") == "vgpr", so NSA coordinatevlistoperands are checked under elected-lane rules too.Analysis.stale_uses()(tools/wave64_halves.py:1776-1778): included"flat_atomic"and"image_atomic"(and dropped the deador dests and False) so scalar descriptor operands (s[0:7]) are always checked for stale-scalar reads.ImageAtomics(10 tests coveringoperands(), uniformA,lane-iddata/vector/NSA coords,lane-count,glcallocation-order, elected constantelected-side-effect, elected NSA non-uniform coordelected-lane, aggregatedBidiom, andstale-scalardescriptor) intests/semantic/test_wave64_halves.pyand updated theWave64 graphics: partition invariance (SHADER-10)contract row indocs/design.md.Tested
python -I scripts/check_no_game_data.py tools/wave64_halves.py tests/semantic/test_wave64_halves.py docs/design.md-> exit 0python -I tests/semantic/test_wave64_halves.py-> Ran 137 tests in 8.223s OKpython -I -m compileall -q make_game.py tools tests-> exit 0python -I tests/test_text_write_line_endings.py(3 OK),tests/test_report_paths.py(22 tests, 1 skipped, OK),tests/test_docs_design_rows.py(5 OK),tests/test_docs_repo_paths.py(3 OK),tests/test_docs_repeated_lines.py(2 OK),tests/test_ci_registration.py(16 OK)3f81d46ac):python -I scripts/run_semantic_tests.py tests/semantic-> 487 files, 6289 tests, 0 files failed in 213 spytestis not installed locally, sotests/test_wave64_halves_fixtures.pyand GPU fixtures were not run locally.GPUs tested: n/a
AI-assisted: yes
Checklist
mainand merges cleanly (a conflicting pull request is labeledneeds rebase).docs/design.md, with how it was confirmed.Hi @JordanWebDev, thanks for this pull request. It currently conflicts with
main(conflicting file(s):docs/design.md,tests/semantic/test_wave64_halves.py), so it carries theneeds rebaselabel. CONTRIBUTING.md asks authors to rebase their branch onmain; once it merges cleanly the label goes within the hour, and reviews start with the pull requests that do. Could you update the branch when you have a moment? If you no longer plan to continue with it, please say so here.AI-assisted (Claude Code, Claude Opus 5.5).
RUN of #1907 (
python -I, no build, no game, no GPU)Heads tested: PR head
1cfb452aad8b, current mainb6bf3aa0be76. Merged = main + PR head withgit merge --no-ff, local only. The merge is not clean: one conflict indocs/design.md(one hunk, the contract table). For the merged run I kept main'sdocs/design.mdand took the auto-merged code and tests (tools/wave64_halves.py,tests/semantic/test_wave64_halves.py). So the merged run does not cover the PR's docs row; the PR needs a rebase for that file.Commands, one process each, from the worktree root:
python -I tests/semantic/test_wave64_halves.pyRelated (28 files): the other
tests/semanticfiles named*wave64_halves*or*w64*,tests/test_wave64_halves_fixtures.py,tests/test_wave64_emulate_opt_cfg.py,tests/test_json_bom_inputs.py,tests/test_docs_*.py,test_ci_registration.py,test_check_no_game_data.py,test_text_write_line_endings.py,test_report_paths.py.Translator suite:
python -I scripts/run_semantic_tests.py tests/semantic -j 3on the merged tree, compared with the same command (-j 4) on plain main.tools/wave64_halves.pyput back to the PR's merge-base version and the PR's tests kept,tests/semantic/test_wave64_halves.pyruns 137 tests and 9 fail, all in the newImageAtomicsclass (operands with and withoutglc, lane-id data and coordinates, lane-count, glc allocation order, elected constant side effect, elected NSA non-uniform coordinate, aggregated B idiom, stale scalar descriptor). The one other new test there (uniform A) passes, as a control.test_wave64_halves.py137 of 137 OK.test_valu_cvt_f16_int16_mods, and alsotest_interp_computed_ij_fallback). Merged: 529 files, 6535 tests (+10, the new class), the same 2 files failed, no new failure.test_wave64_halves_fixtures.py(needspytest, not installed),test_docs_cli_flags.py,test_docs_links.py(same 3 broken anchors on main). At the PR head two files are missing only because the PR's base is old (test_docs_adjacent_fenced_blocks.py,test_w64x_partial_swizzle.py).Machine: Windows 11 Pro 10.0.26300, CPython 3.13.12, GPU not used.
@JordanWebDev this PR now conflicts with
main(docs/design.md). Could you mergemaininto your branch (no force-push needed)? It was verified before the conflict: https://github.com/ProjectLeonida/mandy/pull/1907#issuecomment-7251295850. If there's no update within 24 h, OreoFR may carry it in a new PR that keeps you as co-author (per the maintainers' plan). — OreoFR's agent (AI-assisted)Carried as #2721 because of the conflict with main after #2566; @JordanWebDev, if you come back, say so and the carry is dropped.