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 <4 x i1> @llvm.arm.mve.pred.i2v.v4i1(i32 %0)
99 %2 = tail call <2 x i64> @llvm.arm.mve.mull.int.predicated.v2i64.v4i32.v4i1(<4 x i32> %a, <4 x i32> %b, i32 0, i32 0, <4 x i1> %1, <2 x i64> %inactive)
103 declare <2 x i64> @llvm.arm.mve.mull.int.predicated.v2i64.v4i32.v4i1(<4 x i32>, <4 x i32>, i32, i32, <4 x i1>, <2 x i64>) #1
105 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 {
106 ; CHECK-LABEL: test_vmullbq_poly_m_p8:
107 ; CHECK: @ %bb.0: @ %entry
108 ; CHECK-NEXT: vmsr p0, r0
110 ; CHECK-NEXT: vmullbt.p8 q0, q1, q2
113 %0 = zext i16 %p to i32
114 %1 = tail call <8 x i1> @llvm.arm.mve.pred.i2v.v8i1(i32 %0)
115 %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)
119 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
121 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 {
122 ; CHECK-LABEL: test_vmullbq_int_x_u8:
123 ; CHECK: @ %bb.0: @ %entry
124 ; CHECK-NEXT: vmsr p0, r0
126 ; CHECK-NEXT: vmullbt.u8 q0, q0, q1
129 %0 = zext i16 %p to i32
130 %1 = tail call <8 x i1> @llvm.arm.mve.pred.i2v.v8i1(i32 %0)
131 %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)
135 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 {
136 ; CHECK-LABEL: test_vmullbq_int_x_s16:
137 ; CHECK: @ %bb.0: @ %entry
138 ; CHECK-NEXT: vmsr p0, r0
140 ; CHECK-NEXT: vmullbt.s16 q0, q0, q1
143 %0 = zext i16 %p to i32
144 %1 = tail call <4 x i1> @llvm.arm.mve.pred.i2v.v4i1(i32 %0)
145 %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)
149 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 {
150 ; CHECK-LABEL: test_vmullbq_int_x_u32:
151 ; CHECK: @ %bb.0: @ %entry
152 ; CHECK-NEXT: vmsr p0, r0
154 ; CHECK-NEXT: vmullbt.u32 q2, q0, q1
155 ; CHECK-NEXT: vmov q0, q2
158 %0 = zext i16 %p to i32
159 %1 = tail call <4 x i1> @llvm.arm.mve.pred.i2v.v4i1(i32 %0)
160 %2 = tail call <2 x i64> @llvm.arm.mve.mull.int.predicated.v2i64.v4i32.v4i1(<4 x i32> %a, <4 x i32> %b, i32 1, i32 0, <4 x i1> %1, <2 x i64> undef)
164 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 {
165 ; CHECK-LABEL: test_vmullbq_poly_x_p16:
166 ; CHECK: @ %bb.0: @ %entry
167 ; CHECK-NEXT: vmsr p0, r0
169 ; CHECK-NEXT: vmullbt.p16 q0, q0, q1
172 %0 = zext i16 %p to i32
173 %1 = tail call <4 x i1> @llvm.arm.mve.pred.i2v.v4i1(i32 %0)
174 %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)
178 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