Files
metal2vulkan/docs
Anees Iqbal 4f6dc912f3 Identity domains: a plain ulong texture slot is the RG32 element its resource ID names
A `ulong` texture slot that no `ulong` atomic updates is an `RG32` unsigned image whose two words
the shader joins and splits (`TexelClass::Uint64`), declared `Rg32ui` where it is a storage image
(`ulong_format`, under the floor's `shaderStorageImageExtendedFormats`). Under the identity domains
identity_class refused every `ulong` declaration, so such a kernel was
`Unsupported{IdentityDomains}` ("a type the identity arrays hold no element of"). It now admits it:
its class is the unsigned integer class of its shape, as its declared image is, and a storage
declaration of `Rg32ui` is the class `StorageFormatClass::Format(R32G32_UINT)`, whose variable is
the storage-image array's (set 1, binding 1, which every storage class aliases), as Metal binds
only an `RG32Uint` texture there. A slot a `ulong` atomic updates (an `R64ui` image) and an
argument buffer's `ulong` texture stay refused. The default domains are unchanged.

Docs: RESOURCE-ID.md's arrays name the `RG32Uint` storage class of a `ulong` texture; API.md's
identity forms name a `ulong` slot's reads and writes.

Test: engine_identity's ulong_texture_slots_are_rg32_elements_their_resource_ids_name: the owned
fixture unk_ulong_access (a sample-access and a read-access `texture2d<ulong>`, a write-access
`texture3d<ulong>`) under the identity domains on lavapipe, moltenvk-m3 and moltenvk-m3 without
robustImageAccess2: each passes L3, its classes are the sampled array's unsigned 2D class and the
storage array's 3D `R32G32_UINT` class, and on the CPU interpreter each of 20 threads reads its
elements' two words joined as `(v, 0, 0, 1)`, `(0, 0, 0, 1)` outside the textures, and writes the
sum's two words inside the texture alone.

SEMANTICS_VERSION 2246 -> 2247: a refusal becomes a module.

Evidence:
- The 9 public conformance cases on the plain ulong slot (unk_ulong_rw x7, unk_ulong_access
  x2): before, at f3418eacb9 on lavapipe (m3-max-61725), the 2 access rows not_supported;
  after, at 2796fb6e14 (an earlier form of this commit), 9/9 match, the 2 access rows on
  runtime-compute (m3-max-61703).
- States-only play of all 36 streams at 3bb97361a8 (an earlier form of this commit plus probe
  commits that never land): every render and compute pipeline state made, 0 refused. msi
  m3-max-61733 (1 stream), um870 61734 (1), um790 61760 (5), ms01 61775 (7), gem10 61795 (22).
2026-11-20 22:10:44 -08:00
..