[PR #159] docs: salu_diff generates 99 opcodes by default; v_pack_b32_f16 abs is implemented (fixes #5519, fixes #5517) #212

Open
opened 2026-11-26 20:17:09 +01:00 by 4ld0 · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ubiquitarianism/leonida/pull/159
Author: @Andretuta
Created: 11/24/2026
Status: 🔄 Open

Base: main ← Head: old-pr/9891


📝 Commits (2)

  • a4cb8fd docs: salu_diff generates 99 opcodes by default; v_pack_b32_f16 abs is implemented (#5519, #5517)
  • 5ed4500 docs: clarify the default salu_diff opcode pool

📊 Changes

2 files changed (+7 additions, -6 deletions)

View changed files

📝 docs/design.md (+1 -1)
📝 docs/shader_validation.md (+6 -5)

📄 Description

Carried over from old PR 9891 by AlejoReyna in the original Leonida repository, which went private on 23 Nov 2026. The code is the branch old-pr/9891, exactly that PR's last commit. All carried-over PRs are listed in #17.
Opened as a draft, and the CI runs the opening started were cancelled so 250 PRs don't fill the queue. Re-run CI here when you review it.
AlejoReyna: this is your work. Feel free to take it over, by pushing to the branch or opening your own PR and closing this one.


Original description (mentions and #N references are disabled; the numbers refer to the old repository):

Fixes #5519, fixes #5517. Docs only; no game data.

  • docs/shader_validation.md: tools/salu_diff.py is described as a reference for 87 opcodes. At current main OPS has 112 entries, 13 of them in LANE_MASK_OPS, so the default run generates 99 (checked: len(OPS), len(LANE_MASK_OPS), len(set(OPS)-set(LANE_MASK_OPS)) -> 112 13 99). The sentence now says 99 by default, 112 in OPS (--list-ops).
  • docs/design.md row v_pack_b32_f16 input neg: said abs is still refused as unmeasured. The translator applies abs (clear bit 15 of the selected half, before neg) in tools/rdna2spirv.py, it is measured on gfx1036 (1,088 raw kernels, 0 mismatches; SHADER-260), and the neighbouring v_pack_b32_f16 source modifiers row already says so. The row now agrees with it.

Earlier PRs for these two issues (#5546, #5574, #7978 and others) were closed unmerged; none is open now and neither item was claimed in #9677.

Verification

  • python3 -I scripts/check_no_game_data.py: pass
  • python3 -I tests/test_text_write_line_endings.py: pass
  • opcode counts above checked on current main

AI-assisted: yes (Claude). Tested on macOS, CPU only, no GPU.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/ubiquitarianism/leonida/pull/159 **Author:** [@Andretuta](https://github.com/Andretuta) **Created:** 11/24/2026 **Status:** 🔄 Open **Base:** `main` ← **Head:** `old-pr/9891` --- ### 📝 Commits (2) - [`a4cb8fd`](https://github.com/ubiquitarianism/leonida/commit/a4cb8fd032b9ab7cafdcbd4b6c6d4149e30b2f70) docs: salu_diff generates 99 opcodes by default; v_pack_b32_f16 abs is implemented (#5519, #5517) - [`5ed4500`](https://github.com/ubiquitarianism/leonida/commit/5ed4500aa5e7487a6cb102a6ab60b9d65a5537bb) docs: clarify the default salu_diff opcode pool ### 📊 Changes **2 files changed** (+7 additions, -6 deletions) <details> <summary>View changed files</summary> 📝 `docs/design.md` (+1 -1) 📝 `docs/shader_validation.md` (+6 -5) </details> ### 📄 Description > Carried over from **old PR 9891** by `AlejoReyna` in the original Leonida repository, which went private on 23 Nov 2026. The code is the branch `old-pr/9891`, exactly that PR's last commit. All carried-over PRs are listed in #17. > Opened as a draft, and the CI runs the opening started were cancelled so 250 PRs don't fill the queue. Re-run CI here when you review it. > `AlejoReyna`: this is your work. Feel free to take it over, by pushing to the branch or opening your own PR and closing this one. --- Original description (mentions and `#N` references are disabled; the numbers refer to the old repository): Fixes `#5519`, fixes `#5517`. Docs only; no game data. - `docs/shader_validation.md`: `tools/salu_diff.py` is described as a reference for 87 opcodes. At current main `OPS` has 112 entries, 13 of them in `LANE_MASK_OPS`, so the default run generates 99 (checked: `len(OPS), len(LANE_MASK_OPS), len(set(OPS)-set(LANE_MASK_OPS))` -> `112 13 99`). The sentence now says 99 by default, 112 in `OPS` (`--list-ops`). - `docs/design.md` row `v_pack_b32_f16` input `neg`: said `abs` is still refused as unmeasured. The translator applies `abs` (clear bit 15 of the selected half, before `neg`) in `tools/rdna2spirv.py`, it is measured on gfx1036 (1,088 raw kernels, 0 mismatches; SHADER-260), and the neighbouring `v_pack_b32_f16` source modifiers row already says so. The row now agrees with it. Earlier PRs for these two issues (`#5546`, `#5574`, `#7978` and others) were closed unmerged; none is open now and neither item was claimed in `#9677`. ### Verification - `python3 -I scripts/check_no_game_data.py`: pass - `python3 -I tests/test_text_write_line_endings.py`: pass - opcode counts above checked on current main AI-assisted: yes (Claude). Tested on macOS, CPU only, no GPU. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
Sign in to join this conversation.
No labels
bug
pull-request
No milestone
No project
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.

Dependencies

No dependencies set

Reference
starred/leonida#212
No description provided.