Repository navigation
feat(rdna2spirv): implement image_sample_c_l_o - #3492
klarnet2009 wants to merge 1 commit into
Conversation
|
Tested ccf30b5 on NVIDIA GeForce RTX 4090 (Ada, subgroup 32..32), 621.14, Windows 11 (26200): pass, no change against Test programs: MSVC 19.44 RelWithDebInfo build of
On the branch:
Not run: the full |
|
Tested
Synthetic fixtures only, no game data. AI-assisted (Claude Code). |
|
Tested ccf30b5 on AMD Radeon RX 9070 XT (RADV GFX1201) and the Ryzen 7 9800X3D iGPU (RADV RAPHAEL_MENDOCINO, gfx1036), Mesa 26.2.6, Linux 7.3.4: pass, no regressions.
No game files. AI-assisted. |
whattheflop
left a comment
There was a problem hiding this comment.
AI-assisted verification at ccf30b5b. Both LLVM-assembled forms validated with the maintenance8 option. The RTX 3080 readback checked this opcode directly: all 4,096 pixels chose the expected mip and texel. The scratch run used #3045 for the sampled-array dynamic indexing declaration and #3347 for feature chaining in the test device. The exact head omits the declaration even though both descriptor indices are runtime lookups. Standalone spirv-val did not catch that omission.
The new depth-compare form also inherits an issue in the shared --texel-offset-fallback. With nearest mip filtering and explicit LOD 0.75, the sample uses mip 1, while texel_offset_fold() floors that LOD and uses mip 0 to scale the offset. On an 8x8 base mip and 4x4 mip 1, UV (0.6875,0.5625) with offset (-1,+1) computes mip-1 texel (2,2) instead of (1,3). I checked the emitted size-query chain and confirmed the CPU coordinate calculation. The native run covers integer LODs with maintenance8. Vulkan mip selection
|
Tested ccf30b5 on Steam Deck LCD (Jupiter), AMD Custom GPU 0405 "Van Gogh", RADV Mesa 26.2.0-devel (git-5c65d4fc31), Vulkan 1.4.350, SteamOS 3.9.5 (holo), kernel 7.2.7-valve2-2-neptune-72-g31504582a073: pass
No runtime C++ changes; GPU suite run from the PR worktree against the existing main runtime build. AI-assisted (OpenCode). |
|
Tested ccf30b5 on Windows 11 Pro 10.0.26300, Python 3.12.10 (CPU checks; this PR has no GPU fixture):
Run in a temporary worktree at the PR head. Not GPU-checked: the PR adds no fixture for AI-assisted. |
Implements
image_sample_c_l_o(explicit-LOD depth-compare sample with packed signed 6-bit texel offsets) intools/rdna2spirv.py.Changes
"image_sample_c_l_o"to MIMG dispatch and scalar 2D depth comparison address-length validation (want_addr = 4undera16,5withouta16).off) and explicit LOD extraction (lod) forkind == "_c_l", emittingOpImageSampleDrefExplicitLod %floatwithLod|Offset {lod} {off}in valid SPIR-VImageOperandsbit order (Lod=0x2,Offset=0x10).docs/design.mdwithimage_sample_c_l_odocumentation (CPU/assembler-verified; not yet GPU-measured).tests/semantic/test_image_sample_c_l_o.pycoveringLod|Offset, signed 6-bit offset extraction,d16,a16,Unsupportedrejections, andspirv_asm.assemble()verification on every emitted module.Verification
py -3.12 -I tests/semantic/test_image_sample_c_l_o.py -v: 3/3 OK (0.086s)py -3.12 -I tests/test_isa_coverage.py -v: 18 tests OK (3 skipped:LEONIDA_RDNA2_ISA_XMLunset)py -3.12 -I tests/test_ctest_registration.py -v: 4/4 OKpy -3.12 -I -m compileall -q tools/rdna2spirv.py tests/semantic/test_image_sample_c_l_o.py: OK