masahi opened a new pull request, #15439: URL: https://github.com/apache/tvm/pull/15439
This allows using `builtin::tvm_warp_shuffle()`, `builtin::tvm_warp_shuffle_up/down()` for VK. We need to specify the warp size explicitly as `target = "vulkan -from_device=0 -thread_warp_size=32` to enable shuffle instructions. On NV it works correctly. TODO: test on AMD and add unit tests. On Intel the result is incorrect for some reason. In general subgroup on Intel GPU seems tricky, since unlike NV or AMD there is no well defined "subgroup (warp) size". Each instruction can execute with different subgroup sizes. To disable shuffle instructions, we can add `-supported_subgroup_operations=0` to the target string. Reference: https://www.khronos.org/blog/vulkan-subgroup-tutorial https://registry.khronos.org/SPIR-V/specs/unified1/SPIRV.html#_non_uniform_instructions https://registry.khronos.org/SPIR-V/specs/unified1/SPIRV.html#OpGroupNonUniformShuffleDown -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
