1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -mtriple=thumbv8.1m.main -mattr=+mve.fp -verify-machineinstrs -o - %s | FileCheck %s
4 define arm_aapcs_vfpcc <8 x i16> @test_vmullbq_int_u8(<16 x i8> %a, <16 x i8> %b) local_unnamed_addr #0 {
5 ; CHECK-LABEL: test_vmullbq_int_u8:
6 ; CHECK: @ %bb.0: @ %entry
7 ; CHECK-NEXT: vmullb.u8 q0, q0, q1
10 %0 = tail call <8 x i16> @llvm.arm.mve.vmull.v8i16.v16i8(<16 x i8> %a, <16 x i8> %b, i32 1, i32 0)
14 declare <8 x i16> @llvm.arm.mve.vmull.v8i16.v16i8(<16 x i8>, <16 x i8>, i32, i32) #1
16 define arm_aapcs_vfpcc <4 x i32> @test_vmullbq_int_s16(<8 x i16> %a, <8 x i16> %b) local_unnamed_addr #0 {
17 ; CHECK-LABEL: test_vmullbq_int_s16:
18 ; CHECK: @ %bb.0: @ %entry
19 ; CHECK-NEXT: vmullb.s16 q0, q0, q1
22 %0 = tail call <4 x i32> @llvm.arm.mve.vmull.v4i32.v8i16(<8 x i16> %a, <8 x i16> %b, i32 0, i32 0)
26 declare <4 x i32> @llvm.arm.mve.vmull.v4i32.v8i16(<8 x i16>, <8 x i16>, i32, i32) #1
28 define arm_aapcs_vfpcc <2 x i64> @test_vmullbq_int_u32(<4 x i32> %a, <4 x i32> %b) local_unnamed_addr #0 {
29 ; CHECK-LABEL: test_vmullbq_int_u32:
30 ; CHECK: @ %bb.0: @ %entry
31 ; CHECK-NEXT: vmullb.u32 q2, q0, q1
32 ; CHECK-NEXT: vmov q0, q2
35 %0 = tail call <2 x i64> @llvm.arm.mve.vmull.v2i64.v4i32(<4 x i32> %a, <4 x i32> %b, i32 1, i32 0)
39 declare <2 x i64> @llvm.arm.mve.vmull.v2i64.v4i32(<4 x i32>, <4 x i32>, i32, i32) #1
41 define arm_aapcs_vfpcc <4 x i32> @test_vmullbq_poly_p16(<8 x i16> %a, <8 x i16> %b) local_unnamed_addr #0 {
42 ; CHECK-LABEL: test_vmullbq_poly_p16:
43 ; CHECK: @ %bb.0: @ %entry
44 ; CHECK-NEXT: vmullb.p16 q0, q0, q1
47 %0 = tail call <4 x i32> @llvm.arm.mve.vmull.poly.v4i32.v8i16(<8 x i16> %a, <8 x i16> %b, i32 0)
51 declare <4 x i32> @llvm.arm.mve.vmull.poly.v4i32.v8i16(<8 x i16>, <8 x i16>, i32) #1
53 define arm_aapcs_vfpcc <8 x i16> @test_vmullbq_int_m_s8(<8 x i16> %inactive, <16 x i8> %a, <16 x i8> %b, i16 zeroext %p) local_unnamed_addr #0 {
54 ; CHECK-LABEL: test_vmullbq_int_m_s8:
55 ; CHECK: @ %bb.0: @ %entry
56 ; CHECK-NEXT: vmsr p0, r0
58 ; CHECK-NEXT: vmullbt.s8 q0, q1, q2
61 %0 = zext i16 %p to i32
62 %1 = tail call <8 x i1> @llvm.arm.mve.pred.i2v.v8i1(i32 %0)
63 %2 = tail call <8 x i16> @llvm.arm.mve.mull.int.predicated.v8i16.v16i8.v8i1(<16 x i8> %a, <16 x i8> %b, i32 0, i32 0, <8 x i1> %1, <8 x i16> %inactive)
67 declare <8 x i1> @llvm.arm.mve.pred.i2v.v8i1(i32) #1
69 declare <8 x i16> @llvm.arm.mve.mull.int.predicated.v8i16.v16i8.v8i1(<16 x i8>, <16 x i8>, i32, i32, <8 x i1>, <8 x i16>) #1
71 define arm_aapcs_vfpcc <4 x i32> @test_vmullbq_int_m_u16(<4 x i32> %inactive, <8 x i16> %a, <8 x i16> %b, i16 zeroext %p) #0 {
72 ; CHECK-LABEL: test_vmullbq_int_m_u16:
73 ; CHECK: @ %bb.0: @ %entry
74 ; CHECK-NEXT: vmsr p0, r0
76 ; CHECK-NEXT: vmullbt.u16 q0, q1, q2
79 %0 = zext i16 %p to i32
80 %1 = tail call <4 x i1> @llvm.arm.mve.pred.i2v.v4i1(i32 %0)
81 %2 = tail call <4 x i32> @llvm.arm.mve.mull.int.predicated.v4i32.v8i16.v4i1(<8 x i16> %a, <8 x i16> %b, i32 1, i32 0, <4 x i1> %1, <4 x i32> %inactive)
85 declare <4 x i1> @llvm.arm.mve.pred.i2v.v4i1(i32) #1
87 declare <4 x i32> @llvm.arm.mve.mull.int.predicated.v4i32.v8i16.v4i1(<8 x i16>, <8 x i16>, i32, i32, <4 x i1>, <4 x i32>) #1
89 define arm_aapcs_vfpcc <2 x i64> @test_vmullbq_int_m_s32(<2 x i64> %inactive, <4 x i32> %a, <4 x i32> %b, i16 zeroext %p) local_unnamed_addr #0 {
90 ; CHECK-LABEL: test_vmullbq_int_m_s32:
91 ; CHECK: @ %bb.0: @ %entry
92 ; CHECK-NEXT: vmsr p0, r0
94 ; CHECK-NEXT: vmullbt.s32 q0, q1, q2
97 %0 = zext i16 %p to i32
98 %1 = tail call <2 x i1> @llvm.arm.mve.pred.i2v.v2i1(i32 %0)
99 %2 = tail call <2 x i64> @llvm.arm.mve.mull.int.predicated.v2i64.v4i32.v2i1(<4 x i32> %a, <4 x i32> %b, i32 0, i32 0, <2 x i1> %1, <2 x i64> %inactive)
103 declare <2 x i1> @llvm.arm.mve.pred.i2v.v2i1(i32)
104 declare <2 x i64> @llvm.arm.mve.mull.int.predicated.v2i64.v4i32.v2i1(<4 x i32>, <4 x i32>, i32, i32, <2 x i1>, <2 x i64>) #1
106 define arm_aapcs_vfpcc <8 x i16> @test_vmullbq_poly_m_p8(<8 x i16> %inactive, <16 x i8> %a, <16 x i8> %b, i16 zeroext %p) local_unnamed_addr #0 {
107 ; CHECK-LABEL: test_vmullbq_poly_m_p8:
108 ; CHECK: @ %bb.0: @ %entry
109 ; CHECK-NEXT: vmsr p0, r0
111 ; CHECK-NEXT: vmullbt.p8 q0, q1, q2
114 %0 = zext i16 %p to i32
115 %1 = tail call <8 x i1> @llvm.arm.mve.pred.i2v.v8i1(i32 %0)
116 %2 = tail call <8 x i16> @llvm.arm.mve.mull.poly.predicated.v8i16.v16i8.v8i1(<16 x i8> %a, <16 x i8> %b, i32 0, <8 x i1> %1, <8 x i16> %inactive)
120 declare <8 x i16> @llvm.arm.mve.mull.poly.predicated.v8i16.v16i8.v8i1(<16 x i8>, <16 x i8>, i32, <8 x i1>, <8 x i16>) #1
122 define arm_aapcs_vfpcc <8 x i16> @test_vmullbq_int_x_u8(<16 x i8> %a, <16 x i8> %b, i16 zeroext %p) local_unnamed_addr #0 {
123 ; CHECK-LABEL: test_vmullbq_int_x_u8:
124 ; CHECK: @ %bb.0: @ %entry
125 ; CHECK-NEXT: vmsr p0, r0
127 ; CHECK-NEXT: vmullbt.u8 q0, q0, q1
130 %0 = zext i16 %p to i32
131 %1 = tail call <8 x i1> @llvm.arm.mve.pred.i2v.v8i1(i32 %0)
132 %2 = tail call <8 x i16> @llvm.arm.mve.mull.int.predicated.v8i16.v16i8.v8i1(<16 x i8> %a, <16 x i8> %b, i32 1, i32 0, <8 x i1> %1, <8 x i16> undef)
136 define arm_aapcs_vfpcc <4 x i32> @test_vmullbq_int_x_s16(<8 x i16> %a, <8 x i16> %b, i16 zeroext %p) local_unnamed_addr #0 {
137 ; CHECK-LABEL: test_vmullbq_int_x_s16:
138 ; CHECK: @ %bb.0: @ %entry
139 ; CHECK-NEXT: vmsr p0, r0
141 ; CHECK-NEXT: vmullbt.s16 q0, q0, q1
144 %0 = zext i16 %p to i32
145 %1 = tail call <4 x i1> @llvm.arm.mve.pred.i2v.v4i1(i32 %0)
146 %2 = tail call <4 x i32> @llvm.arm.mve.mull.int.predicated.v4i32.v8i16.v4i1(<8 x i16> %a, <8 x i16> %b, i32 0, i32 0, <4 x i1> %1, <4 x i32> undef)
150 define arm_aapcs_vfpcc <2 x i64> @test_vmullbq_int_x_u32(<4 x i32> %a, <4 x i32> %b, i16 zeroext %p) local_unnamed_addr #0 {
151 ; CHECK-LABEL: test_vmullbq_int_x_u32:
152 ; CHECK: @ %bb.0: @ %entry
153 ; CHECK-NEXT: vmsr p0, r0
155 ; CHECK-NEXT: vmullbt.u32 q2, q0, q1
156 ; CHECK-NEXT: vmov q0, q2
159 %0 = zext i16 %p to i32
160 %1 = tail call <2 x i1> @llvm.arm.mve.pred.i2v.v2i1(i32 %0)
161 %2 = tail call <2 x i64> @llvm.arm.mve.mull.int.predicated.v2i64.v4i32.v2i1(<4 x i32> %a, <4 x i32> %b, i32 1, i32 0, <2 x i1> %1, <2 x i64> undef)
165 define arm_aapcs_vfpcc <4 x i32> @test_vmullbq_poly_x_p16(<8 x i16> %a, <8 x i16> %b, i16 zeroext %p) local_unnamed_addr #0 {
166 ; CHECK-LABEL: test_vmullbq_poly_x_p16:
167 ; CHECK: @ %bb.0: @ %entry
168 ; CHECK-NEXT: vmsr p0, r0
170 ; CHECK-NEXT: vmullbt.p16 q0, q0, q1
173 %0 = zext i16 %p to i32
174 %1 = tail call <4 x i1> @llvm.arm.mve.pred.i2v.v4i1(i32 %0)
175 %2 = tail call <4 x i32> @llvm.arm.mve.mull.poly.predicated.v4i32.v8i16.v4i1(<8 x i16> %a, <8 x i16> %b, i32 0, <4 x i1> %1, <4 x i32> undef)
179 declare <4 x i32> @llvm.arm.mve.mull.poly.predicated.v4i32.v8i16.v4i1(<8 x i16>, <8 x i16>, i32, <4 x i1>, <4 x i32>) #1