rdna2spirv: buffer_load_format_d16_hi_x and buffer_store_format_d16_hi_x #172

Closed
github-bot wants to merge 3 commits from gh-pr/172/head into gh-pr/172/base
Owner

@⁠Andretuta on GitHub · 2026-11-24 02:34 UTC · original
ubiquitarianism:old-pr/9907 → main · +119 −7 · 3 files · 3 commits · closed without merging

Carried over from old PR 9907 by LouisRiverstone in the original Leonida repository, which went private on 23 Nov 2026. The code is the branch old-pr/9907, 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.
LouisRiverstone: 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):

buffer_load_format_d16_hi_x and buffer_store_format_d16_hi_x raised Unsupported, while the other buffer_*_format_d16_* forms are translated. RDNA2 ISA (MUBUF):

  • The load decodes one component as buffer_load_format_d16_x does (to f16 for a float format, to a saturated 16-bit integer for an integer one) and writes it to bits 31:16 of vdata, keeping bits 15:0. d16_x writes 15:0 and keeps 31:16.
  • The store takes the component from bits 31:16 of vdata, where d16_x takes 15:0.

Re-submission of #1885. #1885 was closed unmerged during the 2026-11-23 22:45 UTC cleanup, along with the other open PRs. This is the same branch, now merged with current main.

Checked on #1885 by: tylerstraub (RTX 5090), josevictorp (Linux 6.8), itsonlysimbo (RTX 4070), TreXito (RTX 3060 Ti), tedin7 (RTX 5080), Mast3rL (RX 9070), tunczzz (RTX 5070 Ti), DenRakEiw (Windows 11), bobcatchris (RX 7900 XTX), JRamos1993 (RTX 5090), lukasas74 (RTX 5080), TG0000 (RX 6800) and 2 more.

No game files.

AI-assisted (Claude Code): I reviewed the change and re-ran its tests on the merge with main.

**@⁠Andretuta** on GitHub · 2026-11-24 02:34 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/172) `ubiquitarianism:old-pr/9907` → `main` · +119 −7 · 3 files · 3 commits · closed without merging > Carried over from **old PR 9907** by `LouisRiverstone` in the original Leonida repository, which went private on 23 Nov 2026. The code is the branch `old-pr/9907`, 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. > `LouisRiverstone`: 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): `buffer_load_format_d16_hi_x` and `buffer_store_format_d16_hi_x` raised `Unsupported`, while the other `buffer_*_format_d16_*` forms are translated. RDNA2 ISA (MUBUF): - **The load** decodes one component as `buffer_load_format_d16_x` does (to f16 for a float format, to a saturated 16-bit integer for an integer one) and writes it to **bits 31:16** of `vdata`, keeping bits 15:0. `d16_x` writes 15:0 and keeps 31:16. - **The store** takes the component from **bits 31:16** of `vdata`, where `d16_x` takes 15:0. Re-submission of `#1885`. `#1885` was closed unmerged during the 2026-11-23 22:45 UTC cleanup, along with the other open PRs. This is the same branch, now merged with current `main`. Checked on `#1885` by: tylerstraub (RTX 5090), josevictorp (Linux 6.8), itsonlysimbo (RTX 4070), TreXito (RTX 3060 Ti), tedin7 (RTX 5080), Mast3rL (RX 9070), tunczzz (RTX 5070 Ti), DenRakEiw (Windows 11), bobcatchris (RX 7900 XTX), JRamos1993 (RTX 5090), lukasas74 (RTX 5080), TG0000 (RX 6800) and 2 more. No game files. AI-assisted (Claude Code): I reviewed the change and re-ran its tests on the merge with `main`.
Both were rejected. The load decodes as buffer_load_format_d16_x and
writes the result to bits 31:16 of vdata, keeping 15:0; the store takes
the component from bits 31:16. The first-read analysis counts the load's
vdata as read (the kept half).

tests/semantic/test_buffer_format_d16_hi.py compares both with their
d16_x forms for every format in Gen.FORMATS. docs/design.md row added.
# Conflicts:
#	docs/design.md
#	tools/rdna2spirv.py
# Conflicts:
#	tools/rdna2spirv.py
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 08:47:21 +00:00
github-bot closed this pull request 2026-11-26 08:47:22 +00:00
Author
Owner

@⁠aslan2142 on GitHub · 2026-11-24 19:19 UTC · original

This carry-over of old upstream PR 9907 has been taken over in #858, so I'm closing this draft as #17 describes. The branch old-pr/9907 stays.

AI-assisted (Claude Code, Claude Opus 5.5).

**@⁠aslan2142** on GitHub · 2026-11-24 19:19 UTC · [original](https://github.com/ubiquitarianism/leonida/pull/172#issuecomment-7141919513) This carry-over of old upstream PR 9907 has been taken over in #858, so I'm closing this draft as #17 describes. The branch `old-pr/9907` stays. AI-assisted (Claude Code, Claude Opus 5.5).

Pull request closed

This discussion has been locked. Commenting is limited to contributors.
No description provided.