Skip to content

SHADER-1202: pack 1_5_5_5_UNORM image stores into R16_UINT - #8710

Closed
eugen1763 wants to merge 2 commits into
ItsNotRexed:mainfrom
eugen1763:shader-1202-pack-1555
Closed

eugen1763 wants to merge 2 commits into
ItsNotRexed:mainfrom
eugen1763:shader-1202-pack-1555

Conversation

@eugen1763

@eugen1763 eugen1763 commented Nov 23, 2026 •

Copy link
Copy Markdown

Claim: #8504 (comment)

Depends on: #7604

Draft / do not merge: the translator selects the uint storage table for T# FORMAT 134. The runtime must guarantee the R16_UINT view or provide a discriminator for native packed storage; see the contract discussion on #7604. No device-side changes in this draft.

The store clamps and rounds normalized components and writes A[15] R[14:10] G[9:5] B[4:0] as one R16_UINT texel. Sampled views are unchanged.

  • RTX 5080, NVIDIA 615.78.08, Arch Linux Vulkan: 64/64 exact texels (full-mask f32 and sparse D16), ordinary typed store and typed load/D16 load controls passed, and all four SPIR-V modules validated.
  • Python 3.14.9: python -I scripts/run_semantic_tests.py tests/semantic ran 5,957 cases from 447 files on both the patch and base 867d922f09; the same two files failed on both (test_image_atomics_guard, test_image_store_d16). No new failing files. python -I scripts/check_no_game_data.py passed for all eight changed paths.
  • Contract documented in docs/design.md. No game material, keys, decryption, or protection changes. AI-assisted (Codex).

Route FORMAT 134 stores to the R16_UINT view, retaining the float sampled format.
Verify full and sparse D16 writes against exact packed texels on RTX 5080.
Select the packed value only for format 134.
Verify the emitted view and texel types without requiring a specific SSA producer.
@eugen1763

Copy link
Copy Markdown
Author

Closing as a duplicate of #7878, which had the earlier coordination claim and is now linked in the same dependency chain. This draft assumes FORMAT 134 always binds R16_UINT; #7604 still leaves native A1R5G5B5 storage in use where supported, so this draft should not merge as written. The synthetic RTX 5080 results in this PR apply only to the R16_UINT route.

@eugen1763 eugen1763 closed this Nov 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant