aboutsummaryrefslogtreecommitdiff
path: root/test/CodeGen/AMDGPU/llvm.amdgcn.sendmsg.ll
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2018-07-28 10:51:19 +0000
committerDimitry Andric <dim@FreeBSD.org>2018-07-28 10:51:19 +0000
commiteb11fae6d08f479c0799db45860a98af528fa6e7 (patch)
tree44d492a50c8c1a7eb8e2d17ea3360ec4d066f042 /test/CodeGen/AMDGPU/llvm.amdgcn.sendmsg.ll
parentb8a2042aa938069e862750553db0e4d82d25822c (diff)
downloadsrc-eb11fae6d08f479c0799db45860a98af528fa6e7.tar.gz
src-eb11fae6d08f479c0799db45860a98af528fa6e7.zip
Vendor import of llvm trunk r338150:vendor/llvm/llvm-trunk-r338150
Notes
Notes: svn path=/vendor/llvm/dist/; revision=336809 svn path=/vendor/llvm/llvm-trunk-r338150/; revision=336814; tag=vendor/llvm/llvm-trunk-r338150
Diffstat (limited to 'test/CodeGen/AMDGPU/llvm.amdgcn.sendmsg.ll')
-rw-r--r--test/CodeGen/AMDGPU/llvm.amdgcn.sendmsg.ll15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/CodeGen/AMDGPU/llvm.amdgcn.sendmsg.ll b/test/CodeGen/AMDGPU/llvm.amdgcn.sendmsg.ll
index 94aeb077ebef..594f76048790 100644
--- a/test/CodeGen/AMDGPU/llvm.amdgcn.sendmsg.ll
+++ b/test/CodeGen/AMDGPU/llvm.amdgcn.sendmsg.ll
@@ -121,6 +121,21 @@ body:
ret void
}
+; TODO: This should use s_mul_i32 instead of v_mul_u32_u24 + v_readfirstlane!
+;
+; GCN-LABEL: {{^}}test_mul24:
+; GCN: v_mul_u32_u24_e32
+; GCN: v_readfirstlane_b32
+; GCN: s_mov_b32 m0,
+; GCN: s_sendmsg sendmsg(MSG_INTERRUPT)
+define amdgpu_gs void @test_mul24(i32 inreg %arg) {
+body:
+ %tmp1 = and i32 %arg, 511
+ %tmp2 = mul nuw nsw i32 %tmp1, 12288
+ call void @llvm.amdgcn.s.sendmsg(i32 1, i32 %tmp2)
+ ret void
+}
+
declare void @llvm.amdgcn.s.sendmsg(i32, i32) #0
declare void @llvm.amdgcn.s.sendmsghalt(i32, i32) #0