Shaders/Lower: return 6 faces for channel 2 of image_get_resinfo on SQ_RSRC_IMG_CUBE #3010
No reviewers
Labels
No labels
accessibility
area: build
area: formats
area: gpu
area: loader
area: runtime
area: shader
bug
documentation
duplicate
enhancement
good first issue
gpu: amd
gpu: intel
gpu: nvidia
help wanted
host: wine
invalid
out of scope
question
request
run report
triage: confirmed
triage: has patch
triage: merge candidate
triage: needs info
triage: needs rebase
triage: needs work
triage: proposed close
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/Marvisak--VIctory!3010
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-3010"
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?
@RVZO6 on GitHub · 2026-11-26 03:19 UTC · original
RVZO6:rvzo/cube-resinfo-faces→main· +203 −1 · 2 files · 1 commits · openLower::image_op(crates/victory-shader/src/emit/lower.rs:8670-8685) previously placedTextureCube(kind == 5) in2 | 5 | 6withpresent[2] = false, returning1for channel 2 (depth) ofimage_get_resinfoon a cubemap.Per public AMD documentation, compilers, and RDNA 2 hardware measurements:
nir_lower_tex.c) and AMD LLPC (ImageBuilder.cpp) both divide cubemapresinfodepth by 6.DIM CUBET# returns(8, 8, 6, 1).TextureCubeArray,kind == 9, by× 6).Emit constant
6whenkind == 5 && ch == 2, with tests incrates/victory-shader/src/emit/lower/cube_resinfo_tests.rs(keepinglower.rsat520,845 B, well under the 512 KiB limit).Verification
cube_image_get_resinfo_reports_six_faceslowersimage_get_resinfo dmask:0xf dim:SQ_RSRC_IMG_CUBE, validates withdxil.dll, and executes on WARP SM 6.6 against a 3-mip 8×8MippedCube, asserting[8, 8, 6, 3](mip 0) and[4, 4, 6, 3](mip 1).--tests+--features diagnosticsclippy,xtask policy, full workspace tests): RVZO6/VIctory CI run #45747688145 (green, combined Wave 9 check on63bcca4).AI-assisted: T3 Code (Antigravity, gemini-4-neon).
@Marvisak on GitHub · 2026-11-26 06:17 UTC · original
Automated triage for the maintainers.
For
image_get_resinfoon a cube (DXIL kind 5),Lower::image_opinemit/lower.rsnow returns the constant 6 in channel 2 instead of 1. Previously channel 2 counted as "not present" for cubes in the2 | 5 | 6arm. The evidence is public: the AMD ISA manuals' rule that a cubemap's depth is 6 times the number of slices, the RADV/LLPC lowering that divides by 6, and a stated gfx1031 (RDNA2) measurement. That is the kind of evidence a semantics change needs. The fix touches only kind 5, and cube arrays (kind 9) are left to #1256. The WARP test inlower/cube_resinfo_tests.rschecks[8, 8, 6, 3]at mip 0 and[4, 4, 6, 3]at mip 1.Minor: the inline comment's list of citations could be cut to one short reference.
CI:
checkpassing.Generated by Claude Code
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.