"a descriptor read only as data": programs read a buffer descriptor's record count and type word (419 shaders) #386
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by derz92 on 2026-11-27T16:08:54Z.
Summary
"a descriptor read only as data" was the largest refusal cause in a world run on current main (177 distinct shaders on an M5 Max, Series S; table on #4). On a corpus of the 19,173 shaders that run registered, 690 refusals with that reason come from programs reading dword 2 or dword 3 of a buffer descriptor as numbers. The host's view addresses (
t1, #306) hold only the base address, so the translator refuses those reads.What the programs do with them (from the disassembly, not quoted here):
NUM_RECORDS, which is whatGetDimensionsreads;and 0xc000ffff), multiply the record count by the stride for the size in bytes (dword 1 bits 16-29 × dword 2), and set OOB_SELECT to raw in dword 3 (and 0xcfffffff,or 0x30000000). That's the same shape as #157's "stride cleared", reached through the view-address path because the program only reads that descriptor as data.Proposed change
The host writes the console's buffer descriptor words into the view addresses (stride, record count, and a nominal dword 3: identity selects, RESOURCE_LEVEL 1, OOB_SELECT raw or structured), and the translator reads dwords 0-3 of a buffer descriptor from there. I have it working with 0 corpus regressions and will send a PR.
Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by derz92 on 2026-11-27T16:08:56Z.
/claim
Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by github-actions[bot] on 2026-11-27T16:09:07Z.
Claimed by @derz92. Open a draft pull request with
Refs #386in its description within 24 hours, or the claim expires.