[PR #275] [CLOSED] rdna2spirv: support VOP3 clamp on v_sad_* ops (SHADER-845) #327

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

📋 Pull Request Information

Original PR: https://github.com/ubiquitarianism/leonida/pull/275
Author: @kotekompotek
Created: 11/24/2026
Status: ❌ Closed

Base: main ← Head: work/shader-845-sad-clamp


📝 Commits (1)

  • 0ffb009 rdna2spirv: support VOP3 clamp on v_sad_* ops (SHADER-845)

📊 Changes

5 files changed (+75 additions, -14 deletions)

View changed files

📝 docs/design.md (+1 -1)
📝 tests/semantic/test_alu_sad.py (+3 -3)
📝 tests/semantic/test_alu_sad_u32.py (+8 -7)
➕ tests/semantic/test_sad_clamp.py (+57 -0)
📝 tools/rdna2spirv.py (+6 -3)

📄 Description

Claimed in the coordination issue as: SHADER-845 (coordination issue #14)

What and why

  • Rebased onto current main and squashed into one clean commit.
  • Supported VOP3 clamp (unsigned 32-bit saturating addition via OpULessThan + OpSelect to 0xFFFFFFFF) across all five v_sad_* ops in tools/rdna2spirv.py.
  • Synced the v_sad_* row in docs/design.md (marking the VOP3 clamp rule as CPU-checked and hardware-unmeasured).

Tested

  • python -I tests/semantic/test_sad_clamp.py (2/2 OK), tests/semantic/test_alu_sad.py (5/5 OK), tests/semantic/test_alu_sad_u32.py (35/35 OK), tests/test_ci_registration.py (15/15 OK).

GPUs tested: n/a

AI-assisted: yes

Checklist

  • Based on current main and merges cleanly (a conflicting pull request is labeled needs rebase).
  • One topic; follow-up work goes in a new pull request.
  • No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here.
  • A new translator rule is in the contract table of docs/design.md, with how it was confirmed.

🔄 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/275 **Author:** [@kotekompotek](https://github.com/kotekompotek) **Created:** 11/24/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `work/shader-845-sad-clamp` --- ### 📝 Commits (1) - [`0ffb009`](https://github.com/ubiquitarianism/leonida/commit/0ffb0099744cf83f746b28b0cc20b8da7bdae7a7) rdna2spirv: support VOP3 clamp on v_sad_* ops (SHADER-845) ### 📊 Changes **5 files changed** (+75 additions, -14 deletions) <details> <summary>View changed files</summary> 📝 `docs/design.md` (+1 -1) 📝 `tests/semantic/test_alu_sad.py` (+3 -3) 📝 `tests/semantic/test_alu_sad_u32.py` (+8 -7) ➕ `tests/semantic/test_sad_clamp.py` (+57 -0) 📝 `tools/rdna2spirv.py` (+6 -3) </details> ### 📄 Description Claimed in the coordination issue as: SHADER-845 (coordination issue #14) ### What and why - Rebased onto current `main` and squashed into one clean commit. - Supported VOP3 `clamp` (unsigned 32-bit saturating addition via `OpULessThan` + `OpSelect` to `0xFFFFFFFF`) across all five `v_sad_*` ops in `tools/rdna2spirv.py`. - Synced the `v_sad_*` row in `docs/design.md` (marking the VOP3 clamp rule as CPU-checked and hardware-unmeasured). ### Tested - `python -I tests/semantic/test_sad_clamp.py` (`2/2 OK`), `tests/semantic/test_alu_sad.py` (`5/5 OK`), `tests/semantic/test_alu_sad_u32.py` (`35/35 OK`), `tests/test_ci_registration.py` (`15/15 OK`). GPUs tested: n/a AI-assisted: yes ### Checklist - [x] Based on current `main` and merges cleanly (a conflicting pull request is labeled `needs rebase`). - [x] One topic; follow-up work goes in a new pull request. - [x] No game data, keys or decryption (CONTRIBUTING.md), including in logs or reports quoted here. - [x] A new translator rule is in the contract table of `docs/design.md`, with how it was confirmed. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
4ld0 2026-11-26 20:17:31 +01:00
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#327
No description provided.