AGC: scalar Wave32 VCC mask repeats on 8-lane Vulkan subgroups #25298
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?
Imported from boykopovar/AnyPS5. Originally posted by mihiii1337 on 2026-11-21T21:47:25Z.
The current-main reproduction uses a scalar
s_mov_b32to VCC_LO and plainv_cndmask_b32. The original SDWA clamp reproduction below is historical after #25300.What happens
agc_driver_integer_sdwa_output_modifiersreturns0xffff7ffffor lane 8'sv_cndmask_b32 clamp; the expected value is0x00000080. The same lane and values fail on the 8-lane software adapter in Linux CI and in a local Windows comparison.Title, test or build step
agc_driver_integer_sdwa_output_modifiersAnyPS5 commit
mainatd8ecf92a4e69e86b2f8b6aedecdbc9129709cf48.e60b2f74adnative build with the shader recompiler source tree and the test fixture taken fromd8ecf92a4e.System
Linux CI selected llvmpipe (LLVM 21.1.8), subgroup size 8. Locally, Windows 11 build 26300, i7-14650HX, WinLibs GCC 15.2 Release. The software run used the checksum-pinned Mesa 26.2.6 Windows asset from the project's workflow. The Vulkan validation layer was 1.4.369.
Steps to reproduce
Build
agc_driver_integer_sdwa_output_modifiers_testson the CI commit. Select an 8-lane lavapipe ICD for the process (I usedVK_DRIVER_FILESfor the Windows software run). SetANYPS5_REQUIRE_VULKAN=1,ANYPS5_NO_SHADER_CACHE=1,APS5_NO_PIPELINE_JOURNAL=1,VK_INSTANCE_LAYERS=VK_LAYER_KHRONOS_validationandVK_LOADER_DEBUG=layerand run:The local software runs fail within one second. Verify the
Selected GPUlog names llvmpipe and showssubgroup=8.Log
What was checked
All nine logs show the Khronos layer inserted and zero
VUID-orSYNC-HAZARDmessages. No title was needed.The fixture uses a 32-thread wave and writes
0x96a596a5into VCC_LO. Bit 8 is clear and bit 0 is set. The returned value is exactly lane 8's second input. This is consistent with the second 8-lane host subgroup using local lane 0 when selecting the bit. The source path usesthreadBit(LaneId())on the VCC_LO write and emitsSubgroupLocalInvocationIdfor this non-spanned compute shader. This accounts for the observed mismatch; I did not test other instructions that read the VCC mask.The exact test and error text led to merged #19566. I found no open issue or PR covering this 8-lane case.
AI-assisted: yes