startup: 1D image sampling refuses the explicit-level forms (2 of 29 loading-screen shader refusals) #1721
Labels
No labels
accessibility
awaiting author
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
priority: P0
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/R0Y00--Xbox2Windows#1721
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?
@triggered02 on GitHub · 2026-11-24 17:49 UTC · original
Found while triaging the refusals in the first main-game loading-screen shader cache (#870). 2 of 29 refused shaders.
Problem
A 1D image has one coordinate, and
image_sample_lz/image_sample_lcarry the explicit level in the next address dword. The translator accepted 1D only for the implicit-levelimage_sample:Cause:
Stage.image()refused every 1D form exceptsample, even though the lowering already builds a single float location for a 1D sample andTexture1D.SampleLeveltakes exactly that.Measured
MIMG encodings built in the test (
0b111100prefix, opcode[24:18]/bit 0, dmask[11:8], dimension[5:3]),mainatdeeef352:image_sample_lz … dim:SQ_RSRC_IMG_1D dmask:0xft = r0.SampleLevel(smp0, F(v0), 0);image_sample_l … dim:SQ_RSRC_IMG_1D dmask:0x7t = r0.SampleLevel(smp0, F(v0), F(v1));image_sample … dim:SQ_RSRC_IMG_1Dt = r0.Sample(smp0, F(v0));image_sample_lz … dim:SQ_RSRC_IMG_2Dfloat2(F(v0), F(v1))image_load … dim:SQ_RSRC_IMG_1Dsample_lzwith two address dwordssample_lzwithunormCensus A/B over the local cache (aggregates only): refusals grouped as
SQ_RSRC_IMG_1Dgo 1 → 0 (the current cache holds one; the stored census had two), and that shader progresses tov_readfirstlane_b32 requires a proven uniform source.Done when
image_sample_lzandimage_sample_llower, with the level from the address (zero for lz).image_load, extra address dwords, and layout-changing modifiers (unorm,r128,a16,d16, …) stay refused by name.docs/experiments.mdrecords the accepted forms.Not in this slice: 1D
image_loadaddress packing, 1D array/gather forms, and proving the loading screen gets further (counts are aggregates only).AI-assisted (Claude Code).