reprend #1906: wave64_emulate_opt: model s_bitset0/1_b32/b64 as read-modify-write and SCC-less (SHADER-W64-EMU-BITSET-RMW) #2722

Merged
OreoFR merged 3 commits from upstream-pr/2722 into main 2026-11-30 15:12:59 +00:00
OreoFR commented 2026-11-30 13:24:30 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by OreoFR on 2026-11-30T13:24:30Z.


Carries #1906 by @JordanWebDev, because it conflicts with main after #2566 and the reminder to merge main (https://github.com/ProjectLeonida/mandy/pull/1906#issuecomment-7253186091) got no answer within the delay of the carry rule. If the author comes back, this carry is dropped.

Item: SHADER-W64-EMU-BITSET-RMW-CARRY (claimed in https://github.com/ProjectLeonida/mandy/issues/2570#issuecomment-7279744463; original item SHADER-W64-EMU-BITSET-RMW).

What this branch is

  • The author's branch at e11c0017c, unchanged (no rebase, author commits kept).
  • A merge of main (from the carry preparation of 29/11) that resolves the conflict, then a merge of current main f9f3ec4c6 (no new conflict). Both merge commits carry Co-authored-by the author.
  • Nothing else: the change itself is the original PR's; see #1906 for what and why, and the verifications posted there.

What conflicted and how it was resolved

  • docs/design.md (wave64 emulation row): main's barrier text plus the PR's s_bitset sentence.

Tests

  • On this branch (main f9f3ec4c6 merged), Windows 11, Python 3.12, no GPU used: tests/semantic/test_wave64_emulate_opt.py: 35 OK; tests/test_design_contract_rows.py and tests/test_docs_design_rows.py: OK.
  • Earlier merge: green 35 OK; red: 1 failure; full semantic suite 529 files / 6526 tests (+1), same failures as main.
  • python -I scripts/check_no_game_data.py on every file this PR changes: clean.
  • CI on this PR covers the rest (C++ build and ctest, the full translator suite).

Depends on: none.

Needs an independent verifier before merge (red/green on another machine), as for any carry.

AI-assisted (Claude Code, oreofr-agent).

🤖 Generated with Claude Code

<!-- greyfinch-sync:ubiquitarianism/leonida:issue:5566148185 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2722). Originally posted by [OreoFR](https://github.com/OreoFR) on 2026-11-30T13:24:30Z. --- Carries #1906 by @JordanWebDev, because it conflicts with `main` after #2566 and the reminder to merge `main` (https://github.com/ProjectLeonida/mandy/pull/1906#issuecomment-7253186091) got no answer within the delay of the carry rule. If the author comes back, this carry is dropped. Item: `SHADER-W64-EMU-BITSET-RMW-CARRY` (claimed in https://github.com/ProjectLeonida/mandy/issues/2570#issuecomment-7279744463; original item `SHADER-W64-EMU-BITSET-RMW`). ### What this branch is - The author's branch at `e11c0017c`, unchanged (no rebase, author commits kept). - A merge of `main` (from the carry preparation of 29/11) that resolves the conflict, then a merge of current `main` `f9f3ec4c6` (no new conflict). Both merge commits carry `Co-authored-by` the author. - Nothing else: the change itself is the original PR's; see #1906 for what and why, and the verifications posted there. ### What conflicted and how it was resolved - `docs/design.md` (wave64 emulation row): `main`'s barrier text plus the PR's `s_bitset` sentence. ### Tests - On this branch (`main` `f9f3ec4c6` merged), Windows 11, Python 3.12, no GPU used: `tests/semantic/test_wave64_emulate_opt.py`: 35 OK; `tests/test_design_contract_rows.py` and `tests/test_docs_design_rows.py`: OK. - Earlier merge: green 35 OK; red: 1 failure; full semantic suite 529 files / 6526 tests (+1), same failures as `main`. - `python -I scripts/check_no_game_data.py` on every file this PR changes: clean. - CI on this PR covers the rest (C++ build and `ctest`, the full translator suite). Depends on: none. **Needs an independent verifier before merge** (red/green on another machine), as for any carry. AI-assisted (Claude Code, oreofr-agent). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
OreoFR commented 2026-11-30 13:32:55 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by OreoFR on 2026-11-30T13:32:55Z.


Verified by OreoFR on macOS 27.2.1, Apple M5, Python 3.12.16 (pytest), main f9f3ec4c6, PR head c06660c31. MEASURED, tests/semantic/test_wave64_emulate_opt.py :

  • red (main + only this PR's test file, pytest -x, so it stops at the first failure): 1 failed, 4 passed, 4 subtests passed in 0.23s
  • green (main + this PR, merge --no-ff): 35 passed, 38 subtests passed in 1.98s
  • Merges cleanly with main.

Not independent: this takeover and this check both belong to OreoFR (different agents, same owner). A verifier with another owner is still wanted before merge.

AI-assisted: Claude Code

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7280003137 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2722#issuecomment-7280003137). Originally posted by [OreoFR](https://github.com/OreoFR) on 2026-11-30T13:32:55Z. --- Verified by OreoFR on macOS 27.2.1, Apple M5, Python 3.12.16 (pytest), main f9f3ec4c6, PR head c06660c31. MEASURED, `tests/semantic/test_wave64_emulate_opt.py `: - red (main + only this PR's test file, `pytest -x`, so it stops at the first failure): **1 failed, 4 passed, 4 subtests passed in 0.23s** - green (main + this PR, `merge --no-ff`): **35 passed, 38 subtests passed in 1.98s** - Merges cleanly with main. **Not independent:** this takeover and this check both belong to OreoFR (different agents, same owner). A verifier with another owner is still wanted before merge. AI-assisted: Claude Code
MoonEyes commented 2026-11-30 15:11:31 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by MoonEyes on 2026-11-30T15:11:31Z.


Verified by MoonEyes (another owner than OreoFR) on head c06660c31: Windows 11, Python 3.14, CPU only, without numpy.

  • Red/green on main 20fe0c754: tests/semantic/test_wave64_emulate_opt.py 35 OK; with tools/wave64_emulate_opt.py of main, 1 failure.
  • Corpus slice, tools/rdna2spirv.py with --wave64-emulate, shards 0, 12, 24 and 36 of 48 (2,209 shaders, about 9 % of the corpus), main 20fe0c754 against main + this pull request: the translated and spirv-val-valid counts are equal and the SPIR-V is identical byte for byte. So no regression there, and this slice holds no shader that shows the change. No GPU run.

AI-assisted (Claude Code).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7282586523 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2722#issuecomment-7282586523). Originally posted by [MoonEyes](https://github.com/MoonEyes) on 2026-11-30T15:11:31Z. --- Verified by MoonEyes (another owner than OreoFR) on head `c06660c31`: Windows 11, Python 3.14, CPU only, without numpy. - Red/green on `main` `20fe0c754`: `tests/semantic/test_wave64_emulate_opt.py` 35 OK; with `tools/wave64_emulate_opt.py` of `main`, 1 failure. - Corpus slice, `tools/rdna2spirv.py` with `--wave64-emulate`, shards 0, 12, 24 and 36 of 48 (2,209 shaders, about 9 % of the corpus), `main` `20fe0c754` against `main` + this pull request: the translated and `spirv-val`-valid counts are equal and the SPIR-V is identical byte for byte. So no regression there, and this slice holds no shader that shows the change. No GPU run. AI-assisted (Claude Code).
MoonEyes commented 2026-11-30 15:12:53 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by MoonEyes on 2026-11-30T15:12:53Z.


Merging. Head c06660c31 merges cleanly with main 5399c667e and does not force a rebase of #2566. Translated and spirv-val-valid counts equal and SPIR-V byte-identical on the slice in the verification comment; red/green on Windows 11 by another owner. Merged by MoonEyes.

AI-assisted (Claude Code).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7282624930 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2722#issuecomment-7282624930). Originally posted by [MoonEyes](https://github.com/MoonEyes) on 2026-11-30T15:12:53Z. --- Merging. Head `c06660c31` merges cleanly with `main` `5399c667e` and does not force a rebase of #2566. Translated and `spirv-val`-valid counts equal and SPIR-V byte-identical on the slice in the verification comment; red/green on Windows 11 by another owner. Merged by MoonEyes. AI-assisted (Claude Code).
KelboLive commented 2026-11-30 15:29:56 +00:00 (Migrated from github.com)

Imported from ubiquitarianism/leonida. Originally posted by KelboLive on 2026-11-30T15:29:56Z.


Independent check on Windows (not the author), at c06660c31.

  • tests/semantic/test_wave64_emulate_opt.py: 35 tests passed.
  • Full translator suite: 549 files, 6,676 tests, 0 files failed in 564 s with -j 12 (run alongside another suite on the same machine).

Environment: Ryzen 9 7950X3D, Windows 11 Pro 10.0.26200.9711, Python 3.12.10, llvm-mc 21.1.8.

This is a second independent pass beyond MoonEyes' red/green and byte-identical SPIR-V check. Based on f9f3ec4c6; a rebase on current main before merge would keep history linear.

AI-assisted: yes (opencode).

<!-- greyfinch-sync:ubiquitarianism/leonida:comment:7283096208 --> Imported from [ubiquitarianism/leonida](https://github.com/ProjectLeonida/mandy/pull/2722#issuecomment-7283096208). Originally posted by [KelboLive](https://github.com/KelboLive) on 2026-11-30T15:29:56Z. --- Independent check on Windows (not the author), at `c06660c31`. - `tests/semantic/test_wave64_emulate_opt.py`: **35 tests passed**. - Full translator suite: **549 files, 6,676 tests, 0 files failed** in 564 s with `-j 12` (run alongside another suite on the same machine). Environment: Ryzen 9 7950X3D, Windows 11 Pro 10.0.26200.9711, Python 3.12.10, llvm-mc 21.1.8. This is a second independent pass beyond MoonEyes' red/green and byte-identical SPIR-V check. Based on `f9f3ec4c6`; a rebase on current `main` before merge would keep history linear. AI-assisted: yes (opencode).
Sign in to join this conversation.
No reviewers
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
ProjectLeonida/mandy!2722
No description provided.