[llvm] [NFC][AMDGPU] Pre-commit crash test for OR with VOPC SDWA operand (PR #217384)
Matt Arsenault via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 25 12:22:29 PDT 2026
================
@@ -0,0 +1,13 @@
+; RUN: not --crash llc -mtriple=amdgpu10.30 < %s
+
+; VOPC SDWA has no dst_sel, so SIPeepholeSDWA crashes when it tries to fold
+; an OR with a VOPC SDWA operand assuming one exists.
+
+define i32 @or_of_vopc_sdwa(i32 %a, i32 %b) {
+ %ah = lshr i32 %a, 16
+ %bh = lshr i32 %b, 16
+ %sum = add i32 %ah, %bh
+ %mask = call i32 @llvm.amdgcn.icmp.i32.i32(i32 %ah, i32 %bh, i32 32)
----------------
arsenm wrote:
The intrinsic doesn't matter much for the encoding, you can probably realize the same situation with llvm.amdgcn.ballot
https://github.com/llvm/llvm-project/pull/217384
More information about the llvm-commits
mailing list