[PR #44] [MERGED] docs/design.md: the cube storage image contract (DOC-CUBE-STORE) #97

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

📋 Pull Request Information

Original PR: https://github.com/ubiquitarianism/leonida/pull/44
Author: @Mby159
Created: 11/24/2026
Status: ✅ Merged
Merged: 11/24/2026
Merged by: @ubiquitarianism

Base: main ← Head: docs/cube-store-contract


📝 Commits (1)

  • a5a22ad docs/design.md: the cube storage image contract

📊 Changes

1 file changed (+2 additions, -2 deletions)

View changed files

📝 docs/design.md (+2 -2)

📄 Description

claiming: DOC-CUBE-STORE

The contract table in docs/design.md still describes the state before cube storage images were supported.

"Coherent image accesses (glc)" ended with

glc on a sampled read (image_sample*, image_gather*, image_load_mip) or on a dimension without storage views (cube) is Unsupported

but a cube does have a storage view now: the translator maps dim:SQ_RSRC_IMG_CUBE to the 2D-array view, and a coherent image_load on a cube is accepted. The row now says that a sampled read is still Unsupported, and that a cube has no storage view of its own because it is bound as a six-layer 2D array, with bindings 11/12/13 and the third coordinate as the face.

"Typed image stores" listed only 2D, 2D array and 3D. It now lists cube as well, and spells out the binding (bindings 11/12/13 for float/uint/sint, OpTypeImage ... 2D 0 1 0 2 Unknown, %v3int coordinates (x, y, face)), that tfe and lwe are refused, and how the rule was confirmed.

How it was confirmed

CPU-checked by tests/semantic/test_image_cube_store_glc.py (image_store and coherent image_load on dim:SQ_RSRC_IMG_CUBE across dmask subsets, a16, d16, unorm, and the CS and PS stages, with spirv-val on every generated module). Not GPU-verified: no GPU fixture covers a cube store, so the row says so instead of claiming a GPU check.

Checks

  • python -I scripts/check_no_game_data.py docs/design.md - clean.
  • python -m unittest discover -s tests/semantic -p test_image_cube_store_glc.py - 9 tests, OK (2 skipped).
  • python -I scripts/run_semantic_tests.py tests/semantic on this main: 463 files, 6075 tests, 2 files failed (test_exec_computed, test_image_atomics_guard) - unchanged by this edit, which touches documentation only.

No game files; documentation only. AI-assisted (MiniMax Code).


🔄 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/44 **Author:** [@Mby159](https://github.com/Mby159) **Created:** 11/24/2026 **Status:** ✅ Merged **Merged:** 11/24/2026 **Merged by:** [@ubiquitarianism](https://github.com/ubiquitarianism) **Base:** `main` ← **Head:** `docs/cube-store-contract` --- ### 📝 Commits (1) - [`a5a22ad`](https://github.com/ubiquitarianism/leonida/commit/a5a22ad7a9473c07b612e8e146649fa4da91d8d3) docs/design.md: the cube storage image contract ### 📊 Changes **1 file changed** (+2 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `docs/design.md` (+2 -2) </details> ### 📄 Description claiming: DOC-CUBE-STORE The contract table in `docs/design.md` still describes the state before cube storage images were supported. **"Coherent image accesses (`glc`)"** ended with > `glc` on a sampled read (`image_sample*`, `image_gather*`, `image_load_mip`) or on a dimension without storage views (cube) is `Unsupported` but a cube does have a storage view now: the translator maps `dim:SQ_RSRC_IMG_CUBE` to the 2D-array view, and a coherent `image_load` on a cube is accepted. The row now says that a sampled read is still `Unsupported`, and that a cube has no storage view of its own because it is bound as a six-layer 2D array, with bindings 11/12/13 and the third coordinate as the face. **"Typed image stores"** listed only 2D, 2D array and 3D. It now lists cube as well, and spells out the binding (bindings 11/12/13 for float/uint/sint, `OpTypeImage ... 2D 0 1 0 2 Unknown`, `%v3int` coordinates (x, y, face)), that `tfe` and `lwe` are refused, and how the rule was confirmed. ## How it was confirmed CPU-checked by `tests/semantic/test_image_cube_store_glc.py` (image_store and coherent image_load on `dim:SQ_RSRC_IMG_CUBE` across dmask subsets, a16, d16, unorm, and the CS and PS stages, with `spirv-val` on every generated module). **Not GPU-verified**: no GPU fixture covers a cube store, so the row says so instead of claiming a GPU check. ## Checks - `python -I scripts/check_no_game_data.py docs/design.md` - clean. - `python -m unittest discover -s tests/semantic -p test_image_cube_store_glc.py` - 9 tests, OK (2 skipped). - `python -I scripts/run_semantic_tests.py tests/semantic` on this main: 463 files, 6075 tests, 2 files failed (`test_exec_computed`, `test_image_atomics_guard`) - unchanged by this edit, which touches documentation only. No game files; documentation only. AI-assisted (MiniMax Code). --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
4ld0 2026-11-26 20:16:47 +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#97
No description provided.