summaryrefslogtreecommitdiff
path: root/llvm/test/CodeGen/SPIRV/transcoding/OpVariable_Initializer.ll
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/test/CodeGen/SPIRV/transcoding/OpVariable_Initializer.ll')
-rw-r--r--llvm/test/CodeGen/SPIRV/transcoding/OpVariable_Initializer.ll11
1 files changed, 11 insertions, 0 deletions
diff --git a/llvm/test/CodeGen/SPIRV/transcoding/OpVariable_Initializer.ll b/llvm/test/CodeGen/SPIRV/transcoding/OpVariable_Initializer.ll
new file mode 100644
index 000000000000..c8953c701d47
--- /dev/null
+++ b/llvm/test/CodeGen/SPIRV/transcoding/OpVariable_Initializer.ll
@@ -0,0 +1,11 @@
+; RUN: llc -verify-machineinstrs -O0 -mtriple=spirv32-unknown-unknown %s -o - | FileCheck %s --check-prefix=CHECK-SPIRV
+; RUN: %if spirv-tools %{ llc -O0 -mtriple=spirv32-unknown-unknown %s -o - -filetype=obj | spirv-val %}
+
+; CHECK-SPIRV: [[#PtrT:]] = OpTypePointer Workgroup %[[#]]
+; CHECK-SPIRV: %[[#]] = OpVariable %[[#PtrT]] Workgroup
+
+@test_atomic_fn.L = internal addrspace(3) global [64 x i32] zeroinitializer, align 4
+
+define spir_kernel void @test_atomic_fn() {
+ ret void
+}