Addresses and descriptors of 0x218 programs #100

Closed
Castyan wants to merge 48 commits from upstream-pr/100 into main
Castyan commented 2026-11-26 20:05:09 +00:00 (Migrated from github.com)

Imported from DexNom/VIctory. Originally posted by Castyan on 2026-11-26T20:05:09Z.


Stacked on #98 (0x218, itself on #64 and #61). The changes to review are the 3 commits after 60ff2e8.

What

  • e046271 A program whose lowering reads a value its block is not dominated by is now refused instead of panicking (seen on 0x218 m083). The check uses dominance. A unit test covers a phi input that is not dominated.
  • 3fc128a s_bfm_b64 of constants is folded into the words it writes. An execution test covers an immediate sampler built that way. The refusal "an address not from a root parameter" (the first in game before this) is now gone.
  • 1be2ae5 A structured buffer made raw, read by a typed load that names its format (tbuffer_load_format_xy ... offen format:[BUF_FMT_16_16_SNORM]). An MTBUF load takes its format from the instruction and, without idxen, its address from the byte offset alone, so it reads what the raw host view holds at that byte. Loads by index and buffer_load_format_* stay refused. Tests: resource tracking, and an execution test on the card and WARP; both fail without the change.

Results

Replay of two sets of 200 captured 0x218 descriptions on the RTX 5060: 1be2ae5 gains no program by itself. Its 22 programs now pass this point and stop further on (lane-mask joins, descriptors changed after loading, opaque lane masks). None lost.

Checks (RTX 5060, at 1be2ae5)

cargo clippy --workspace --all-targets --locked -- -D warnings, with and without --all-features: clean. cargo test --workspace --locked: 744 passed, 0 failed, 11 ignored.

🤖 Generated with Claude Code

<!-- greyfinch-sync:DexNom/VIctory:issue:5516459266 --> Imported from [DexNom/VIctory](https://github.com/DexNom/VIctory/pull/100). Originally posted by [Castyan](https://github.com/Castyan) on 2026-11-26T20:05:09Z. --- **Stacked on #98** (0x218, itself on #64 and #61). The changes to review are the 3 commits after `60ff2e8`. ## What - **`e046271` A program whose lowering reads a value its block is not dominated by is now refused** instead of panicking (seen on 0x218 `m083`). The check uses dominance. A unit test covers a phi input that is not dominated. - **`3fc128a` `s_bfm_b64` of constants is folded** into the words it writes. An execution test covers an immediate sampler built that way. The refusal "an address not from a root parameter" (the first in game before this) is now gone. - **`1be2ae5` A structured buffer made raw, read by a typed load that names its format** (`tbuffer_load_format_xy ... offen format:[BUF_FMT_16_16_SNORM]`). An MTBUF load takes its format from the instruction and, without `idxen`, its address from the byte offset alone, so it reads what the raw host view holds at that byte. Loads by index and `buffer_load_format_*` stay refused. Tests: resource tracking, and an execution test on the card and WARP; both fail without the change. ## Results Replay of two sets of 200 captured 0x218 descriptions on the RTX 5060: `1be2ae5` gains no program by itself. Its 22 programs now pass this point and stop further on (lane-mask joins, descriptors changed after loading, opaque lane masks). None lost. ## Checks (RTX 5060, at `1be2ae5`) `cargo clippy --workspace --all-targets --locked -- -D warnings`, with and without `--all-features`: clean. `cargo test --workspace --locked`: 744 passed, 0 failed, 11 ignored. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
andrewDoing commented 2026-11-26 23:23:16 +00:00 (Migrated from github.com)

Imported from DexNom/VIctory. Originally posted by andrewDoing on 2026-11-26T23:23:16Z.


Independent check at 1be2ae5 of the stacked typed byte-offset load change: 39 synthetic structured-to-raw loads on each of physical RTX 5070 and verified WARP, using strides 4/8/16 and 13 DWORD offsets across bytes 0–124. All 78 actual dispatches returned both expected 16-bit SNORM components within one float ULP, including signed endpoints and nonzero second DWORDs in structured records. This targets the typed byte-offset load specifically; no title data or gameplay was used.

Verification was AI-assisted with GPT-6.2 Astra.

<!-- greyfinch-sync:DexNom/VIctory:comment:7205497601 --> Imported from [DexNom/VIctory](https://github.com/DexNom/VIctory/pull/100#issuecomment-7205497601). Originally posted by [andrewDoing](https://github.com/andrewDoing) on 2026-11-26T23:23:16Z. --- Independent check at `1be2ae5` of the stacked typed byte-offset load change: 39 synthetic structured-to-raw loads on each of physical RTX 5070 and verified WARP, using strides 4/8/16 and 13 DWORD offsets across bytes 0–124. All 78 actual dispatches returned both expected 16-bit SNORM components within one float ULP, including signed endpoints and nonzero second DWORDs in structured records. This targets the typed byte-offset load specifically; no title data or gameplay was used. Verification was AI-assisted with GPT-6.2 Astra.
Castyan commented 2026-11-27 07:40:32 +00:00 (Migrated from github.com)

Imported from DexNom/VIctory. Originally posted by Castyan on 2026-11-27T07:40:32Z.


Merged into #64 (83bfddc), where this work continues. Closing as superseded.

<!-- greyfinch-sync:DexNom/VIctory:comment:7212705430 --> Imported from [DexNom/VIctory](https://github.com/DexNom/VIctory/pull/100#issuecomment-7212705430). Originally posted by [Castyan](https://github.com/Castyan) on 2026-11-27T07:40:32Z. --- Merged into #64 (`83bfddc`), where this work continues. Closing as superseded.

Pull request closed

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
DexNom/VIctory!100
No description provided.