Debian Codegraph @

llvm/test/CodeGen/SPIRV/transcoding/OpAllAny.ll

raw
1 ; RUN: llc -O0 -mtriple=spirv32-unknown-unknown %s -o - | FileCheck %s --check-prefix=CHECK-SPIRV
2
3 ;; This test checks SYCL relational builtin any and all with vector input types.
4
5 ; CHECK-SPIRV: %[[#BoolTypeID:]] = OpTypeBool
6
7 ; CHECK-SPIRV: OpAny %[[#BoolTypeID]]
8 ; CHECK-SPIRV: OpAny %[[#BoolTypeID]]
9 ; CHECK-SPIRV: OpAny %[[#BoolTypeID]]
10 ; CHECK-SPIRV: OpAny %[[#BoolTypeID]]
11 ; CHECK-SPIRV: OpAll %[[#BoolTypeID]]
12 ; CHECK-SPIRV: OpAll %[[#BoolTypeID]]
13 ; CHECK-SPIRV: OpAll %[[#BoolTypeID]]
14 ; CHECK-SPIRV: OpAll %[[#BoolTypeID]]
15
16 define dso_local spir_func void @test_vector(ptr addrspace(4) nocapture writeonly %out, <2 x i8> %c, <2 x i16> %s, <2 x i32> %i, <2 x i64> %l) local_unnamed_addr {
17 entry:
18 %call = tail call spir_func i32 @_Z3anyDv2_c(<2 x i8> %c)
19 %call1 = tail call spir_func i32 @_Z3anyDv2_s(<2 x i16> %s)
20 %add = add nsw i32 %call1, %call
21 %call2 = tail call spir_func i32 @_Z3anyDv2_i(<2 x i32> %i)
22 %add3 = add nsw i32 %add, %call2
23 %call4 = tail call spir_func i32 @_Z3anyDv2_l(<2 x i64> %l)
24 %add5 = add nsw i32 %add3, %call4
25 %call6 = tail call spir_func i32 @_Z3allDv2_c(<2 x i8> %c)
26 %add7 = add nsw i32 %add5, %call6
27 %call8 = tail call spir_func i32 @_Z3allDv2_s(<2 x i16> %s)
28 %add9 = add nsw i32 %add7, %call8
29 %call10 = tail call spir_func i32 @_Z3allDv2_i(<2 x i32> %i)
30 %add11 = add nsw i32 %add9, %call10
31 %call12 = tail call spir_func i32 @_Z3allDv2_l(<2 x i64> %l)
32 %add13 = add nsw i32 %add11, %call12
33 store i32 %add13, ptr addrspace(4) %out, align 4
34 ret void
35 }
36
37 declare spir_func i32 @_Z3anyDv2_c(<2 x i8>) local_unnamed_addr
38
39 declare spir_func i32 @_Z3anyDv2_s(<2 x i16>) local_unnamed_addr
40
41 declare spir_func i32 @_Z3anyDv2_i(<2 x i32>) local_unnamed_addr
42
43 declare spir_func i32 @_Z3anyDv2_l(<2 x i64>) local_unnamed_addr
44
45 declare spir_func i32 @_Z3allDv2_c(<2 x i8>) local_unnamed_addr
46
47 declare spir_func i32 @_Z3allDv2_s(<2 x i16>) local_unnamed_addr
48
49 declare spir_func i32 @_Z3allDv2_i(<2 x i32>) local_unnamed_addr
50
51 declare spir_func i32 @_Z3allDv2_l(<2 x i64>) local_unnamed_addr