runtime: read declared CBV and past-table slots in slot 57 meshes #3565

Merged
lambirou merged 1 commit from upstream-pr/3565 into main 2026-11-30 08:58:07 +00:00
lambirou commented 2026-11-30 08:41:49 +00:00 (Migrated from github.com)

Imported from R0Y00/Xbox2Windows. Originally posted by lambirou on 2026-11-30T08:41:49Z.


Split from #3537 as requested in review https://github.com/R0Y00/Xbox2Windows/pull/3537#pullrequestreview-6108358331.

A captured depth-only slot 57 request reads constant data through a CBV range of its creation root, and through one descriptor past the last declared range. A table is only a heap region on the console, so both reads are valid there; the native loader refused them.

Read a slot a CBV range declares, and a slot past the last declared range, as a byte window: s_buffer_load carries no format, filtering or typed element, so the descriptor's memory read as raw dwords is the same value. The submission still resolves each table slot's token and refuses anything that is not a buffer SRV or a CBV, so an undeclared slot with a wrong view class fails before its descriptor table is bound.

Tests

native_fixed_mesh57_cbv_*: the same MS reads the same dword through a table slot declared as a CBV (PSO created, pixels match the SRV variant) and through one declared as a UAV (still refused as a buffer window). The source branch also passed the full native_fixed_mesh57_* set 26/26 on WARP and hardware.

This branch is a clean cherry-pick of f3590da0, based on 44a3ad5a; CI is the first build of the extracted branch.

AI-assisted.

<!-- greyfinch-sync:R0Y00/Xbox2Windows:issue:5561894798 --> Imported from [R0Y00/Xbox2Windows](https://github.com/R0Y00/Xbox2Windows/pull/3565). Originally posted by [lambirou](https://github.com/lambirou) on 2026-11-30T08:41:49Z. --- Split from #3537 as requested in review https://github.com/R0Y00/Xbox2Windows/pull/3537#pullrequestreview-6108358331. A captured depth-only slot 57 request reads constant data through a CBV range of its creation root, and through one descriptor past the last declared range. A table is only a heap region on the console, so both reads are valid there; the native loader refused them. Read a slot a CBV range declares, and a slot past the last declared range, as a byte window: `s_buffer_load` carries no format, filtering or typed element, so the descriptor's memory read as raw dwords is the same value. The submission still resolves each table slot's token and refuses anything that is not a buffer SRV or a CBV, so an undeclared slot with a wrong view class fails before its descriptor table is bound. ## Tests `native_fixed_mesh57_cbv_*`: the same MS reads the same dword through a table slot declared as a CBV (PSO created, pixels match the SRV variant) and through one declared as a UAV (still refused as a buffer window). The source branch also passed the full `native_fixed_mesh57_*` set 26/26 on WARP and hardware. This branch is a clean cherry-pick of `f3590da0`, based on `44a3ad5a`; CI is the first build of the extracted branch. AI-assisted.
Sign in to join this conversation.
No reviewers
No labels
No milestone
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.

Reference
R0Y00/Xbox2Windows!3565
No description provided.