1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -mtriple=riscv32 -mattr=+d,+zvfh,+v -target-abi=ilp32d \
3 ; RUN: -verify-machineinstrs < %s | FileCheck %s --check-prefixes=CHECK,ZVFH
4 ; RUN: llc -mtriple=riscv64 -mattr=+d,+zvfh,+v -target-abi=lp64d \
5 ; RUN: -verify-machineinstrs < %s | FileCheck %s --check-prefixes=CHECK,ZVFH
6 ; RUN: llc -mtriple=riscv32 -mattr=+d,+zfhmin,+zvfhmin,+v -target-abi=ilp32d \
7 ; RUN: -verify-machineinstrs < %s | FileCheck %s --check-prefixes=CHECK,ZVFHMIN
8 ; RUN: llc -mtriple=riscv64 -mattr=+d,+zfhmin,+zvfhmin,+v -target-abi=lp64d \
9 ; RUN: -verify-machineinstrs < %s | FileCheck %s --check-prefixes=CHECK,ZVFHMIN
11 declare <vscale x 1 x half> @llvm.vp.fmul.nxv1f16(<vscale x 1 x half>, <vscale x 1 x half>, <vscale x 1 x i1>, i32)
13 define <vscale x 1 x half> @vfmul_vv_nxv1f16(<vscale x 1 x half> %va, <vscale x 1 x half> %b, <vscale x 1 x i1> %m, i32 zeroext %evl) {
14 ; ZVFH-LABEL: vfmul_vv_nxv1f16:
16 ; ZVFH-NEXT: vsetvli zero, a0, e16, mf4, ta, ma
17 ; ZVFH-NEXT: vfmul.vv v8, v8, v9, v0.t
20 ; ZVFHMIN-LABEL: vfmul_vv_nxv1f16:
22 ; ZVFHMIN-NEXT: vsetvli a1, zero, e16, mf4, ta, ma
23 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v10, v9
24 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v9, v8
25 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, mf2, ta, ma
26 ; ZVFHMIN-NEXT: vfmul.vv v9, v9, v10, v0.t
27 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, mf4, ta, ma
28 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v9
30 %v = call <vscale x 1 x half> @llvm.vp.fmul.nxv1f16(<vscale x 1 x half> %va, <vscale x 1 x half> %b, <vscale x 1 x i1> %m, i32 %evl)
31 ret <vscale x 1 x half> %v
34 define <vscale x 1 x half> @vfmul_vv_nxv1f16_unmasked(<vscale x 1 x half> %va, <vscale x 1 x half> %b, i32 zeroext %evl) {
35 ; ZVFH-LABEL: vfmul_vv_nxv1f16_unmasked:
37 ; ZVFH-NEXT: vsetvli zero, a0, e16, mf4, ta, ma
38 ; ZVFH-NEXT: vfmul.vv v8, v8, v9
41 ; ZVFHMIN-LABEL: vfmul_vv_nxv1f16_unmasked:
43 ; ZVFHMIN-NEXT: vsetvli a1, zero, e16, mf4, ta, ma
44 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v10, v9
45 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v9, v8
46 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, mf2, ta, ma
47 ; ZVFHMIN-NEXT: vfmul.vv v9, v9, v10
48 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, mf4, ta, ma
49 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v9
51 %v = call <vscale x 1 x half> @llvm.vp.fmul.nxv1f16(<vscale x 1 x half> %va, <vscale x 1 x half> %b, <vscale x 1 x i1> splat (i1 true), i32 %evl)
52 ret <vscale x 1 x half> %v
55 define <vscale x 1 x half> @vfmul_vf_nxv1f16(<vscale x 1 x half> %va, half %b, <vscale x 1 x i1> %m, i32 zeroext %evl) {
56 ; ZVFH-LABEL: vfmul_vf_nxv1f16:
58 ; ZVFH-NEXT: vsetvli zero, a0, e16, mf4, ta, ma
59 ; ZVFH-NEXT: vfmul.vf v8, v8, fa0, v0.t
62 ; ZVFHMIN-LABEL: vfmul_vf_nxv1f16:
64 ; ZVFHMIN-NEXT: fmv.x.h a1, fa0
65 ; ZVFHMIN-NEXT: vsetvli a2, zero, e16, mf4, ta, ma
66 ; ZVFHMIN-NEXT: vmv.v.x v9, a1
67 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v10, v8
68 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v8, v9
69 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, mf2, ta, ma
70 ; ZVFHMIN-NEXT: vfmul.vv v9, v10, v8, v0.t
71 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, mf4, ta, ma
72 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v9
74 %elt.head = insertelement <vscale x 1 x half> poison, half %b, i32 0
75 %vb = shufflevector <vscale x 1 x half> %elt.head, <vscale x 1 x half> poison, <vscale x 1 x i32> zeroinitializer
76 %v = call <vscale x 1 x half> @llvm.vp.fmul.nxv1f16(<vscale x 1 x half> %va, <vscale x 1 x half> %vb, <vscale x 1 x i1> %m, i32 %evl)
77 ret <vscale x 1 x half> %v
80 define <vscale x 1 x half> @vfmul_vf_nxv1f16_unmasked(<vscale x 1 x half> %va, half %b, i32 zeroext %evl) {
81 ; ZVFH-LABEL: vfmul_vf_nxv1f16_unmasked:
83 ; ZVFH-NEXT: vsetvli zero, a0, e16, mf4, ta, ma
84 ; ZVFH-NEXT: vfmul.vf v8, v8, fa0
87 ; ZVFHMIN-LABEL: vfmul_vf_nxv1f16_unmasked:
89 ; ZVFHMIN-NEXT: fmv.x.h a1, fa0
90 ; ZVFHMIN-NEXT: vsetvli a2, zero, e16, mf4, ta, ma
91 ; ZVFHMIN-NEXT: vmv.v.x v9, a1
92 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v10, v8
93 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v8, v9
94 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, mf2, ta, ma
95 ; ZVFHMIN-NEXT: vfmul.vv v9, v10, v8
96 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, mf4, ta, ma
97 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v9
99 %elt.head = insertelement <vscale x 1 x half> poison, half %b, i32 0
100 %vb = shufflevector <vscale x 1 x half> %elt.head, <vscale x 1 x half> poison, <vscale x 1 x i32> zeroinitializer
101 %v = call <vscale x 1 x half> @llvm.vp.fmul.nxv1f16(<vscale x 1 x half> %va, <vscale x 1 x half> %vb, <vscale x 1 x i1> splat (i1 true), i32 %evl)
102 ret <vscale x 1 x half> %v
105 declare <vscale x 2 x half> @llvm.vp.fmul.nxv2f16(<vscale x 2 x half>, <vscale x 2 x half>, <vscale x 2 x i1>, i32)
107 define <vscale x 2 x half> @vfmul_vv_nxv2f16(<vscale x 2 x half> %va, <vscale x 2 x half> %b, <vscale x 2 x i1> %m, i32 zeroext %evl) {
108 ; ZVFH-LABEL: vfmul_vv_nxv2f16:
110 ; ZVFH-NEXT: vsetvli zero, a0, e16, mf2, ta, ma
111 ; ZVFH-NEXT: vfmul.vv v8, v8, v9, v0.t
114 ; ZVFHMIN-LABEL: vfmul_vv_nxv2f16:
116 ; ZVFHMIN-NEXT: vsetvli a1, zero, e16, mf2, ta, ma
117 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v10, v9
118 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v9, v8
119 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m1, ta, ma
120 ; ZVFHMIN-NEXT: vfmul.vv v9, v9, v10, v0.t
121 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, mf2, ta, ma
122 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v9
124 %v = call <vscale x 2 x half> @llvm.vp.fmul.nxv2f16(<vscale x 2 x half> %va, <vscale x 2 x half> %b, <vscale x 2 x i1> %m, i32 %evl)
125 ret <vscale x 2 x half> %v
128 define <vscale x 2 x half> @vfmul_vv_nxv2f16_unmasked(<vscale x 2 x half> %va, <vscale x 2 x half> %b, i32 zeroext %evl) {
129 ; ZVFH-LABEL: vfmul_vv_nxv2f16_unmasked:
131 ; ZVFH-NEXT: vsetvli zero, a0, e16, mf2, ta, ma
132 ; ZVFH-NEXT: vfmul.vv v8, v8, v9
135 ; ZVFHMIN-LABEL: vfmul_vv_nxv2f16_unmasked:
137 ; ZVFHMIN-NEXT: vsetvli a1, zero, e16, mf2, ta, ma
138 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v10, v9
139 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v9, v8
140 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m1, ta, ma
141 ; ZVFHMIN-NEXT: vfmul.vv v9, v9, v10
142 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, mf2, ta, ma
143 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v9
145 %v = call <vscale x 2 x half> @llvm.vp.fmul.nxv2f16(<vscale x 2 x half> %va, <vscale x 2 x half> %b, <vscale x 2 x i1> splat (i1 true), i32 %evl)
146 ret <vscale x 2 x half> %v
149 define <vscale x 2 x half> @vfmul_vf_nxv2f16(<vscale x 2 x half> %va, half %b, <vscale x 2 x i1> %m, i32 zeroext %evl) {
150 ; ZVFH-LABEL: vfmul_vf_nxv2f16:
152 ; ZVFH-NEXT: vsetvli zero, a0, e16, mf2, ta, ma
153 ; ZVFH-NEXT: vfmul.vf v8, v8, fa0, v0.t
156 ; ZVFHMIN-LABEL: vfmul_vf_nxv2f16:
158 ; ZVFHMIN-NEXT: fmv.x.h a1, fa0
159 ; ZVFHMIN-NEXT: vsetvli a2, zero, e16, mf2, ta, ma
160 ; ZVFHMIN-NEXT: vmv.v.x v9, a1
161 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v10, v8
162 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v8, v9
163 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m1, ta, ma
164 ; ZVFHMIN-NEXT: vfmul.vv v9, v10, v8, v0.t
165 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, mf2, ta, ma
166 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v9
168 %elt.head = insertelement <vscale x 2 x half> poison, half %b, i32 0
169 %vb = shufflevector <vscale x 2 x half> %elt.head, <vscale x 2 x half> poison, <vscale x 2 x i32> zeroinitializer
170 %v = call <vscale x 2 x half> @llvm.vp.fmul.nxv2f16(<vscale x 2 x half> %va, <vscale x 2 x half> %vb, <vscale x 2 x i1> %m, i32 %evl)
171 ret <vscale x 2 x half> %v
174 define <vscale x 2 x half> @vfmul_vf_nxv2f16_unmasked(<vscale x 2 x half> %va, half %b, i32 zeroext %evl) {
175 ; ZVFH-LABEL: vfmul_vf_nxv2f16_unmasked:
177 ; ZVFH-NEXT: vsetvli zero, a0, e16, mf2, ta, ma
178 ; ZVFH-NEXT: vfmul.vf v8, v8, fa0
181 ; ZVFHMIN-LABEL: vfmul_vf_nxv2f16_unmasked:
183 ; ZVFHMIN-NEXT: fmv.x.h a1, fa0
184 ; ZVFHMIN-NEXT: vsetvli a2, zero, e16, mf2, ta, ma
185 ; ZVFHMIN-NEXT: vmv.v.x v9, a1
186 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v10, v8
187 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v8, v9
188 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m1, ta, ma
189 ; ZVFHMIN-NEXT: vfmul.vv v9, v10, v8
190 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, mf2, ta, ma
191 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v9
193 %elt.head = insertelement <vscale x 2 x half> poison, half %b, i32 0
194 %vb = shufflevector <vscale x 2 x half> %elt.head, <vscale x 2 x half> poison, <vscale x 2 x i32> zeroinitializer
195 %v = call <vscale x 2 x half> @llvm.vp.fmul.nxv2f16(<vscale x 2 x half> %va, <vscale x 2 x half> %vb, <vscale x 2 x i1> splat (i1 true), i32 %evl)
196 ret <vscale x 2 x half> %v
199 declare <vscale x 4 x half> @llvm.vp.fmul.nxv4f16(<vscale x 4 x half>, <vscale x 4 x half>, <vscale x 4 x i1>, i32)
201 define <vscale x 4 x half> @vfmul_vv_nxv4f16(<vscale x 4 x half> %va, <vscale x 4 x half> %b, <vscale x 4 x i1> %m, i32 zeroext %evl) {
202 ; ZVFH-LABEL: vfmul_vv_nxv4f16:
204 ; ZVFH-NEXT: vsetvli zero, a0, e16, m1, ta, ma
205 ; ZVFH-NEXT: vfmul.vv v8, v8, v9, v0.t
208 ; ZVFHMIN-LABEL: vfmul_vv_nxv4f16:
210 ; ZVFHMIN-NEXT: vsetvli a1, zero, e16, m1, ta, ma
211 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v10, v9
212 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v12, v8
213 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m2, ta, ma
214 ; ZVFHMIN-NEXT: vfmul.vv v10, v12, v10, v0.t
215 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m1, ta, ma
216 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v10
218 %v = call <vscale x 4 x half> @llvm.vp.fmul.nxv4f16(<vscale x 4 x half> %va, <vscale x 4 x half> %b, <vscale x 4 x i1> %m, i32 %evl)
219 ret <vscale x 4 x half> %v
222 define <vscale x 4 x half> @vfmul_vv_nxv4f16_unmasked(<vscale x 4 x half> %va, <vscale x 4 x half> %b, i32 zeroext %evl) {
223 ; ZVFH-LABEL: vfmul_vv_nxv4f16_unmasked:
225 ; ZVFH-NEXT: vsetvli zero, a0, e16, m1, ta, ma
226 ; ZVFH-NEXT: vfmul.vv v8, v8, v9
229 ; ZVFHMIN-LABEL: vfmul_vv_nxv4f16_unmasked:
231 ; ZVFHMIN-NEXT: vsetvli a1, zero, e16, m1, ta, ma
232 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v10, v9
233 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v12, v8
234 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m2, ta, ma
235 ; ZVFHMIN-NEXT: vfmul.vv v10, v12, v10
236 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m1, ta, ma
237 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v10
239 %v = call <vscale x 4 x half> @llvm.vp.fmul.nxv4f16(<vscale x 4 x half> %va, <vscale x 4 x half> %b, <vscale x 4 x i1> splat (i1 true), i32 %evl)
240 ret <vscale x 4 x half> %v
243 define <vscale x 4 x half> @vfmul_vf_nxv4f16(<vscale x 4 x half> %va, half %b, <vscale x 4 x i1> %m, i32 zeroext %evl) {
244 ; ZVFH-LABEL: vfmul_vf_nxv4f16:
246 ; ZVFH-NEXT: vsetvli zero, a0, e16, m1, ta, ma
247 ; ZVFH-NEXT: vfmul.vf v8, v8, fa0, v0.t
250 ; ZVFHMIN-LABEL: vfmul_vf_nxv4f16:
252 ; ZVFHMIN-NEXT: fmv.x.h a1, fa0
253 ; ZVFHMIN-NEXT: vsetvli a2, zero, e16, m1, ta, ma
254 ; ZVFHMIN-NEXT: vmv.v.x v9, a1
255 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v10, v8
256 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v12, v9
257 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m2, ta, ma
258 ; ZVFHMIN-NEXT: vfmul.vv v10, v10, v12, v0.t
259 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m1, ta, ma
260 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v10
262 %elt.head = insertelement <vscale x 4 x half> poison, half %b, i32 0
263 %vb = shufflevector <vscale x 4 x half> %elt.head, <vscale x 4 x half> poison, <vscale x 4 x i32> zeroinitializer
264 %v = call <vscale x 4 x half> @llvm.vp.fmul.nxv4f16(<vscale x 4 x half> %va, <vscale x 4 x half> %vb, <vscale x 4 x i1> %m, i32 %evl)
265 ret <vscale x 4 x half> %v
268 define <vscale x 4 x half> @vfmul_vf_nxv4f16_unmasked(<vscale x 4 x half> %va, half %b, i32 zeroext %evl) {
269 ; ZVFH-LABEL: vfmul_vf_nxv4f16_unmasked:
271 ; ZVFH-NEXT: vsetvli zero, a0, e16, m1, ta, ma
272 ; ZVFH-NEXT: vfmul.vf v8, v8, fa0
275 ; ZVFHMIN-LABEL: vfmul_vf_nxv4f16_unmasked:
277 ; ZVFHMIN-NEXT: fmv.x.h a1, fa0
278 ; ZVFHMIN-NEXT: vsetvli a2, zero, e16, m1, ta, ma
279 ; ZVFHMIN-NEXT: vmv.v.x v9, a1
280 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v10, v8
281 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v12, v9
282 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m2, ta, ma
283 ; ZVFHMIN-NEXT: vfmul.vv v10, v10, v12
284 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m1, ta, ma
285 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v10
287 %elt.head = insertelement <vscale x 4 x half> poison, half %b, i32 0
288 %vb = shufflevector <vscale x 4 x half> %elt.head, <vscale x 4 x half> poison, <vscale x 4 x i32> zeroinitializer
289 %v = call <vscale x 4 x half> @llvm.vp.fmul.nxv4f16(<vscale x 4 x half> %va, <vscale x 4 x half> %vb, <vscale x 4 x i1> splat (i1 true), i32 %evl)
290 ret <vscale x 4 x half> %v
293 declare <vscale x 8 x half> @llvm.vp.fmul.nxv8f16(<vscale x 8 x half>, <vscale x 8 x half>, <vscale x 8 x i1>, i32)
295 define <vscale x 8 x half> @vfmul_vv_nxv8f16(<vscale x 8 x half> %va, <vscale x 8 x half> %b, <vscale x 8 x i1> %m, i32 zeroext %evl) {
296 ; ZVFH-LABEL: vfmul_vv_nxv8f16:
298 ; ZVFH-NEXT: vsetvli zero, a0, e16, m2, ta, ma
299 ; ZVFH-NEXT: vfmul.vv v8, v8, v10, v0.t
302 ; ZVFHMIN-LABEL: vfmul_vv_nxv8f16:
304 ; ZVFHMIN-NEXT: vsetvli a1, zero, e16, m2, ta, ma
305 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v12, v10
306 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v8
307 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m4, ta, ma
308 ; ZVFHMIN-NEXT: vfmul.vv v12, v16, v12, v0.t
309 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m2, ta, ma
310 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v12
312 %v = call <vscale x 8 x half> @llvm.vp.fmul.nxv8f16(<vscale x 8 x half> %va, <vscale x 8 x half> %b, <vscale x 8 x i1> %m, i32 %evl)
313 ret <vscale x 8 x half> %v
316 define <vscale x 8 x half> @vfmul_vv_nxv8f16_unmasked(<vscale x 8 x half> %va, <vscale x 8 x half> %b, i32 zeroext %evl) {
317 ; ZVFH-LABEL: vfmul_vv_nxv8f16_unmasked:
319 ; ZVFH-NEXT: vsetvli zero, a0, e16, m2, ta, ma
320 ; ZVFH-NEXT: vfmul.vv v8, v8, v10
323 ; ZVFHMIN-LABEL: vfmul_vv_nxv8f16_unmasked:
325 ; ZVFHMIN-NEXT: vsetvli a1, zero, e16, m2, ta, ma
326 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v12, v10
327 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v8
328 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m4, ta, ma
329 ; ZVFHMIN-NEXT: vfmul.vv v12, v16, v12
330 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m2, ta, ma
331 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v12
333 %v = call <vscale x 8 x half> @llvm.vp.fmul.nxv8f16(<vscale x 8 x half> %va, <vscale x 8 x half> %b, <vscale x 8 x i1> splat (i1 true), i32 %evl)
334 ret <vscale x 8 x half> %v
337 define <vscale x 8 x half> @vfmul_vf_nxv8f16(<vscale x 8 x half> %va, half %b, <vscale x 8 x i1> %m, i32 zeroext %evl) {
338 ; ZVFH-LABEL: vfmul_vf_nxv8f16:
340 ; ZVFH-NEXT: vsetvli zero, a0, e16, m2, ta, ma
341 ; ZVFH-NEXT: vfmul.vf v8, v8, fa0, v0.t
344 ; ZVFHMIN-LABEL: vfmul_vf_nxv8f16:
346 ; ZVFHMIN-NEXT: fmv.x.h a1, fa0
347 ; ZVFHMIN-NEXT: vsetvli a2, zero, e16, m2, ta, ma
348 ; ZVFHMIN-NEXT: vmv.v.x v10, a1
349 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v12, v8
350 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v10
351 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m4, ta, ma
352 ; ZVFHMIN-NEXT: vfmul.vv v12, v12, v16, v0.t
353 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m2, ta, ma
354 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v12
356 %elt.head = insertelement <vscale x 8 x half> poison, half %b, i32 0
357 %vb = shufflevector <vscale x 8 x half> %elt.head, <vscale x 8 x half> poison, <vscale x 8 x i32> zeroinitializer
358 %v = call <vscale x 8 x half> @llvm.vp.fmul.nxv8f16(<vscale x 8 x half> %va, <vscale x 8 x half> %vb, <vscale x 8 x i1> %m, i32 %evl)
359 ret <vscale x 8 x half> %v
362 define <vscale x 8 x half> @vfmul_vf_nxv8f16_unmasked(<vscale x 8 x half> %va, half %b, i32 zeroext %evl) {
363 ; ZVFH-LABEL: vfmul_vf_nxv8f16_unmasked:
365 ; ZVFH-NEXT: vsetvli zero, a0, e16, m2, ta, ma
366 ; ZVFH-NEXT: vfmul.vf v8, v8, fa0
369 ; ZVFHMIN-LABEL: vfmul_vf_nxv8f16_unmasked:
371 ; ZVFHMIN-NEXT: fmv.x.h a1, fa0
372 ; ZVFHMIN-NEXT: vsetvli a2, zero, e16, m2, ta, ma
373 ; ZVFHMIN-NEXT: vmv.v.x v10, a1
374 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v12, v8
375 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v10
376 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m4, ta, ma
377 ; ZVFHMIN-NEXT: vfmul.vv v12, v12, v16
378 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m2, ta, ma
379 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v12
381 %elt.head = insertelement <vscale x 8 x half> poison, half %b, i32 0
382 %vb = shufflevector <vscale x 8 x half> %elt.head, <vscale x 8 x half> poison, <vscale x 8 x i32> zeroinitializer
383 %v = call <vscale x 8 x half> @llvm.vp.fmul.nxv8f16(<vscale x 8 x half> %va, <vscale x 8 x half> %vb, <vscale x 8 x i1> splat (i1 true), i32 %evl)
384 ret <vscale x 8 x half> %v
387 declare <vscale x 16 x half> @llvm.vp.fmul.nxv16f16(<vscale x 16 x half>, <vscale x 16 x half>, <vscale x 16 x i1>, i32)
389 define <vscale x 16 x half> @vfmul_vv_nxv16f16(<vscale x 16 x half> %va, <vscale x 16 x half> %b, <vscale x 16 x i1> %m, i32 zeroext %evl) {
390 ; ZVFH-LABEL: vfmul_vv_nxv16f16:
392 ; ZVFH-NEXT: vsetvli zero, a0, e16, m4, ta, ma
393 ; ZVFH-NEXT: vfmul.vv v8, v8, v12, v0.t
396 ; ZVFHMIN-LABEL: vfmul_vv_nxv16f16:
398 ; ZVFHMIN-NEXT: vsetvli a1, zero, e16, m4, ta, ma
399 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v12
400 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v24, v8
401 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m8, ta, ma
402 ; ZVFHMIN-NEXT: vfmul.vv v16, v24, v16, v0.t
403 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m4, ta, ma
404 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v16
406 %v = call <vscale x 16 x half> @llvm.vp.fmul.nxv16f16(<vscale x 16 x half> %va, <vscale x 16 x half> %b, <vscale x 16 x i1> %m, i32 %evl)
407 ret <vscale x 16 x half> %v
410 define <vscale x 16 x half> @vfmul_vv_nxv16f16_unmasked(<vscale x 16 x half> %va, <vscale x 16 x half> %b, i32 zeroext %evl) {
411 ; ZVFH-LABEL: vfmul_vv_nxv16f16_unmasked:
413 ; ZVFH-NEXT: vsetvli zero, a0, e16, m4, ta, ma
414 ; ZVFH-NEXT: vfmul.vv v8, v8, v12
417 ; ZVFHMIN-LABEL: vfmul_vv_nxv16f16_unmasked:
419 ; ZVFHMIN-NEXT: vsetvli a1, zero, e16, m4, ta, ma
420 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v12
421 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v24, v8
422 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m8, ta, ma
423 ; ZVFHMIN-NEXT: vfmul.vv v16, v24, v16
424 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m4, ta, ma
425 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v16
427 %v = call <vscale x 16 x half> @llvm.vp.fmul.nxv16f16(<vscale x 16 x half> %va, <vscale x 16 x half> %b, <vscale x 16 x i1> splat (i1 true), i32 %evl)
428 ret <vscale x 16 x half> %v
431 define <vscale x 16 x half> @vfmul_vf_nxv16f16(<vscale x 16 x half> %va, half %b, <vscale x 16 x i1> %m, i32 zeroext %evl) {
432 ; ZVFH-LABEL: vfmul_vf_nxv16f16:
434 ; ZVFH-NEXT: vsetvli zero, a0, e16, m4, ta, ma
435 ; ZVFH-NEXT: vfmul.vf v8, v8, fa0, v0.t
438 ; ZVFHMIN-LABEL: vfmul_vf_nxv16f16:
440 ; ZVFHMIN-NEXT: fmv.x.h a1, fa0
441 ; ZVFHMIN-NEXT: vsetvli a2, zero, e16, m4, ta, ma
442 ; ZVFHMIN-NEXT: vmv.v.x v12, a1
443 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v8
444 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v24, v12
445 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m8, ta, ma
446 ; ZVFHMIN-NEXT: vfmul.vv v16, v16, v24, v0.t
447 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m4, ta, ma
448 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v16
450 %elt.head = insertelement <vscale x 16 x half> poison, half %b, i32 0
451 %vb = shufflevector <vscale x 16 x half> %elt.head, <vscale x 16 x half> poison, <vscale x 16 x i32> zeroinitializer
452 %v = call <vscale x 16 x half> @llvm.vp.fmul.nxv16f16(<vscale x 16 x half> %va, <vscale x 16 x half> %vb, <vscale x 16 x i1> %m, i32 %evl)
453 ret <vscale x 16 x half> %v
456 define <vscale x 16 x half> @vfmul_vf_nxv16f16_unmasked(<vscale x 16 x half> %va, half %b, i32 zeroext %evl) {
457 ; ZVFH-LABEL: vfmul_vf_nxv16f16_unmasked:
459 ; ZVFH-NEXT: vsetvli zero, a0, e16, m4, ta, ma
460 ; ZVFH-NEXT: vfmul.vf v8, v8, fa0
463 ; ZVFHMIN-LABEL: vfmul_vf_nxv16f16_unmasked:
465 ; ZVFHMIN-NEXT: fmv.x.h a1, fa0
466 ; ZVFHMIN-NEXT: vsetvli a2, zero, e16, m4, ta, ma
467 ; ZVFHMIN-NEXT: vmv.v.x v12, a1
468 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v8
469 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v24, v12
470 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m8, ta, ma
471 ; ZVFHMIN-NEXT: vfmul.vv v16, v16, v24
472 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m4, ta, ma
473 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v16
475 %elt.head = insertelement <vscale x 16 x half> poison, half %b, i32 0
476 %vb = shufflevector <vscale x 16 x half> %elt.head, <vscale x 16 x half> poison, <vscale x 16 x i32> zeroinitializer
477 %v = call <vscale x 16 x half> @llvm.vp.fmul.nxv16f16(<vscale x 16 x half> %va, <vscale x 16 x half> %vb, <vscale x 16 x i1> splat (i1 true), i32 %evl)
478 ret <vscale x 16 x half> %v
481 declare <vscale x 32 x half> @llvm.vp.fmul.nxv32f16(<vscale x 32 x half>, <vscale x 32 x half>, <vscale x 32 x i1>, i32)
483 define <vscale x 32 x half> @vfmul_vv_nxv32f16(<vscale x 32 x half> %va, <vscale x 32 x half> %b, <vscale x 32 x i1> %m, i32 zeroext %evl) {
484 ; ZVFH-LABEL: vfmul_vv_nxv32f16:
486 ; ZVFH-NEXT: vsetvli zero, a0, e16, m8, ta, ma
487 ; ZVFH-NEXT: vfmul.vv v8, v8, v16, v0.t
490 ; ZVFHMIN-LABEL: vfmul_vv_nxv32f16:
492 ; ZVFHMIN-NEXT: addi sp, sp, -16
493 ; ZVFHMIN-NEXT: .cfi_def_cfa_offset 16
494 ; ZVFHMIN-NEXT: csrr a1, vlenb
495 ; ZVFHMIN-NEXT: slli a1, a1, 3
496 ; ZVFHMIN-NEXT: sub sp, sp, a1
497 ; ZVFHMIN-NEXT: .cfi_escape 0x0f, 0x0d, 0x72, 0x00, 0x11, 0x10, 0x22, 0x11, 0x08, 0x92, 0xa2, 0x38, 0x00, 0x1e, 0x22 # sp + 16 + 8 * vlenb
498 ; ZVFHMIN-NEXT: vmv1r.v v7, v0
499 ; ZVFHMIN-NEXT: csrr a2, vlenb
500 ; ZVFHMIN-NEXT: addi a1, sp, 16
501 ; ZVFHMIN-NEXT: vs8r.v v16, (a1) # Unknown-size Folded Spill
502 ; ZVFHMIN-NEXT: vsetvli a1, zero, e16, m4, ta, ma
503 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v24, v20
504 ; ZVFHMIN-NEXT: slli a1, a2, 1
505 ; ZVFHMIN-NEXT: srli a2, a2, 2
506 ; ZVFHMIN-NEXT: sub a3, a0, a1
507 ; ZVFHMIN-NEXT: vsetvli a4, zero, e8, mf2, ta, ma
508 ; ZVFHMIN-NEXT: vslidedown.vx v0, v0, a2
509 ; ZVFHMIN-NEXT: sltu a2, a0, a3
510 ; ZVFHMIN-NEXT: addi a2, a2, -1
511 ; ZVFHMIN-NEXT: and a2, a2, a3
512 ; ZVFHMIN-NEXT: vsetvli a3, zero, e16, m4, ta, ma
513 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v12
514 ; ZVFHMIN-NEXT: vsetvli zero, a2, e32, m8, ta, ma
515 ; ZVFHMIN-NEXT: vfmul.vv v16, v16, v24, v0.t
516 ; ZVFHMIN-NEXT: vsetvli a2, zero, e16, m4, ta, ma
517 ; ZVFHMIN-NEXT: vfncvt.f.f.w v12, v16
518 ; ZVFHMIN-NEXT: bltu a0, a1, .LBB20_2
519 ; ZVFHMIN-NEXT: # %bb.1:
520 ; ZVFHMIN-NEXT: mv a0, a1
521 ; ZVFHMIN-NEXT: .LBB20_2:
522 ; ZVFHMIN-NEXT: addi a1, sp, 16
523 ; ZVFHMIN-NEXT: vl8r.v v24, (a1) # Unknown-size Folded Reload
524 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v24
525 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v24, v8
526 ; ZVFHMIN-NEXT: vmv1r.v v0, v7
527 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m8, ta, ma
528 ; ZVFHMIN-NEXT: vfmul.vv v16, v24, v16, v0.t
529 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m4, ta, ma
530 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v16
531 ; ZVFHMIN-NEXT: csrr a0, vlenb
532 ; ZVFHMIN-NEXT: slli a0, a0, 3
533 ; ZVFHMIN-NEXT: add sp, sp, a0
534 ; ZVFHMIN-NEXT: .cfi_def_cfa sp, 16
535 ; ZVFHMIN-NEXT: addi sp, sp, 16
536 ; ZVFHMIN-NEXT: .cfi_def_cfa_offset 0
538 %v = call <vscale x 32 x half> @llvm.vp.fmul.nxv32f16(<vscale x 32 x half> %va, <vscale x 32 x half> %b, <vscale x 32 x i1> %m, i32 %evl)
539 ret <vscale x 32 x half> %v
542 define <vscale x 32 x half> @vfmul_vv_nxv32f16_unmasked(<vscale x 32 x half> %va, <vscale x 32 x half> %b, i32 zeroext %evl) {
543 ; ZVFH-LABEL: vfmul_vv_nxv32f16_unmasked:
545 ; ZVFH-NEXT: vsetvli zero, a0, e16, m8, ta, ma
546 ; ZVFH-NEXT: vfmul.vv v8, v8, v16
549 ; ZVFHMIN-LABEL: vfmul_vv_nxv32f16_unmasked:
551 ; ZVFHMIN-NEXT: addi sp, sp, -16
552 ; ZVFHMIN-NEXT: .cfi_def_cfa_offset 16
553 ; ZVFHMIN-NEXT: csrr a1, vlenb
554 ; ZVFHMIN-NEXT: slli a1, a1, 3
555 ; ZVFHMIN-NEXT: sub sp, sp, a1
556 ; ZVFHMIN-NEXT: .cfi_escape 0x0f, 0x0d, 0x72, 0x00, 0x11, 0x10, 0x22, 0x11, 0x08, 0x92, 0xa2, 0x38, 0x00, 0x1e, 0x22 # sp + 16 + 8 * vlenb
557 ; ZVFHMIN-NEXT: csrr a2, vlenb
558 ; ZVFHMIN-NEXT: vsetvli a1, zero, e8, m4, ta, ma
559 ; ZVFHMIN-NEXT: vmset.m v7
560 ; ZVFHMIN-NEXT: addi a1, sp, 16
561 ; ZVFHMIN-NEXT: vs8r.v v16, (a1) # Unknown-size Folded Spill
562 ; ZVFHMIN-NEXT: vsetvli a1, zero, e16, m4, ta, ma
563 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v24, v20
564 ; ZVFHMIN-NEXT: slli a1, a2, 1
565 ; ZVFHMIN-NEXT: srli a2, a2, 2
566 ; ZVFHMIN-NEXT: sub a3, a0, a1
567 ; ZVFHMIN-NEXT: vsetvli a4, zero, e8, mf2, ta, ma
568 ; ZVFHMIN-NEXT: vslidedown.vx v0, v7, a2
569 ; ZVFHMIN-NEXT: sltu a2, a0, a3
570 ; ZVFHMIN-NEXT: addi a2, a2, -1
571 ; ZVFHMIN-NEXT: and a2, a2, a3
572 ; ZVFHMIN-NEXT: vsetvli a3, zero, e16, m4, ta, ma
573 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v12
574 ; ZVFHMIN-NEXT: vsetvli zero, a2, e32, m8, ta, ma
575 ; ZVFHMIN-NEXT: vfmul.vv v16, v16, v24, v0.t
576 ; ZVFHMIN-NEXT: vsetvli a2, zero, e16, m4, ta, ma
577 ; ZVFHMIN-NEXT: vfncvt.f.f.w v12, v16
578 ; ZVFHMIN-NEXT: bltu a0, a1, .LBB21_2
579 ; ZVFHMIN-NEXT: # %bb.1:
580 ; ZVFHMIN-NEXT: mv a0, a1
581 ; ZVFHMIN-NEXT: .LBB21_2:
582 ; ZVFHMIN-NEXT: addi a1, sp, 16
583 ; ZVFHMIN-NEXT: vl8r.v v24, (a1) # Unknown-size Folded Reload
584 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v24
585 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v24, v8
586 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m8, ta, ma
587 ; ZVFHMIN-NEXT: vfmul.vv v16, v24, v16
588 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m4, ta, ma
589 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v16
590 ; ZVFHMIN-NEXT: csrr a0, vlenb
591 ; ZVFHMIN-NEXT: slli a0, a0, 3
592 ; ZVFHMIN-NEXT: add sp, sp, a0
593 ; ZVFHMIN-NEXT: .cfi_def_cfa sp, 16
594 ; ZVFHMIN-NEXT: addi sp, sp, 16
595 ; ZVFHMIN-NEXT: .cfi_def_cfa_offset 0
597 %v = call <vscale x 32 x half> @llvm.vp.fmul.nxv32f16(<vscale x 32 x half> %va, <vscale x 32 x half> %b, <vscale x 32 x i1> splat (i1 true), i32 %evl)
598 ret <vscale x 32 x half> %v
601 define <vscale x 32 x half> @vfmul_vf_nxv32f16(<vscale x 32 x half> %va, half %b, <vscale x 32 x i1> %m, i32 zeroext %evl) {
602 ; ZVFH-LABEL: vfmul_vf_nxv32f16:
604 ; ZVFH-NEXT: vsetvli zero, a0, e16, m8, ta, ma
605 ; ZVFH-NEXT: vfmul.vf v8, v8, fa0, v0.t
608 ; ZVFHMIN-LABEL: vfmul_vf_nxv32f16:
610 ; ZVFHMIN-NEXT: addi sp, sp, -16
611 ; ZVFHMIN-NEXT: .cfi_def_cfa_offset 16
612 ; ZVFHMIN-NEXT: csrr a1, vlenb
613 ; ZVFHMIN-NEXT: slli a2, a1, 4
614 ; ZVFHMIN-NEXT: add a1, a2, a1
615 ; ZVFHMIN-NEXT: sub sp, sp, a1
616 ; ZVFHMIN-NEXT: .cfi_escape 0x0f, 0x0d, 0x72, 0x00, 0x11, 0x10, 0x22, 0x11, 0x11, 0x92, 0xa2, 0x38, 0x00, 0x1e, 0x22 # sp + 16 + 17 * vlenb
617 ; ZVFHMIN-NEXT: vmv8r.v v16, v8
618 ; ZVFHMIN-NEXT: fmv.x.h a1, fa0
619 ; ZVFHMIN-NEXT: csrr a2, vlenb
620 ; ZVFHMIN-NEXT: addi a3, sp, 16
621 ; ZVFHMIN-NEXT: vs8r.v v8, (a3) # Unknown-size Folded Spill
622 ; ZVFHMIN-NEXT: vsetvli a3, zero, e16, m4, ta, ma
623 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v8, v20
624 ; ZVFHMIN-NEXT: vsetvli a3, zero, e16, m8, ta, ma
625 ; ZVFHMIN-NEXT: vmv.v.x v16, a1
626 ; ZVFHMIN-NEXT: csrr a1, vlenb
627 ; ZVFHMIN-NEXT: slli a3, a1, 3
628 ; ZVFHMIN-NEXT: add a1, a3, a1
629 ; ZVFHMIN-NEXT: add a1, sp, a1
630 ; ZVFHMIN-NEXT: addi a1, a1, 16
631 ; ZVFHMIN-NEXT: vs8r.v v16, (a1) # Unknown-size Folded Spill
632 ; ZVFHMIN-NEXT: slli a1, a2, 1
633 ; ZVFHMIN-NEXT: srli a2, a2, 2
634 ; ZVFHMIN-NEXT: sub a3, a0, a1
635 ; ZVFHMIN-NEXT: csrr a4, vlenb
636 ; ZVFHMIN-NEXT: slli a4, a4, 3
637 ; ZVFHMIN-NEXT: add a4, sp, a4
638 ; ZVFHMIN-NEXT: addi a4, a4, 16
639 ; ZVFHMIN-NEXT: vs1r.v v0, (a4) # Unknown-size Folded Spill
640 ; ZVFHMIN-NEXT: vsetvli a4, zero, e8, mf2, ta, ma
641 ; ZVFHMIN-NEXT: vslidedown.vx v0, v0, a2
642 ; ZVFHMIN-NEXT: sltu a2, a0, a3
643 ; ZVFHMIN-NEXT: addi a2, a2, -1
644 ; ZVFHMIN-NEXT: and a2, a2, a3
645 ; ZVFHMIN-NEXT: csrr a3, vlenb
646 ; ZVFHMIN-NEXT: slli a4, a3, 3
647 ; ZVFHMIN-NEXT: add a3, a4, a3
648 ; ZVFHMIN-NEXT: add a3, sp, a3
649 ; ZVFHMIN-NEXT: addi a3, a3, 16
650 ; ZVFHMIN-NEXT: vl8r.v v24, (a3) # Unknown-size Folded Reload
651 ; ZVFHMIN-NEXT: vsetvli a3, zero, e16, m4, ta, ma
652 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v28
653 ; ZVFHMIN-NEXT: vsetvli zero, a2, e32, m8, ta, ma
654 ; ZVFHMIN-NEXT: vfmul.vv v16, v8, v16, v0.t
655 ; ZVFHMIN-NEXT: vsetvli a2, zero, e16, m4, ta, ma
656 ; ZVFHMIN-NEXT: vfncvt.f.f.w v12, v16
657 ; ZVFHMIN-NEXT: bltu a0, a1, .LBB22_2
658 ; ZVFHMIN-NEXT: # %bb.1:
659 ; ZVFHMIN-NEXT: mv a0, a1
660 ; ZVFHMIN-NEXT: .LBB22_2:
661 ; ZVFHMIN-NEXT: addi a1, sp, 16
662 ; ZVFHMIN-NEXT: vl8r.v v24, (a1) # Unknown-size Folded Reload
663 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v24
664 ; ZVFHMIN-NEXT: csrr a1, vlenb
665 ; ZVFHMIN-NEXT: slli a2, a1, 3
666 ; ZVFHMIN-NEXT: add a1, a2, a1
667 ; ZVFHMIN-NEXT: add a1, sp, a1
668 ; ZVFHMIN-NEXT: addi a1, a1, 16
669 ; ZVFHMIN-NEXT: vl8r.v v0, (a1) # Unknown-size Folded Reload
670 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v24, v0
671 ; ZVFHMIN-NEXT: csrr a1, vlenb
672 ; ZVFHMIN-NEXT: slli a1, a1, 3
673 ; ZVFHMIN-NEXT: add a1, sp, a1
674 ; ZVFHMIN-NEXT: addi a1, a1, 16
675 ; ZVFHMIN-NEXT: vl1r.v v0, (a1) # Unknown-size Folded Reload
676 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m8, ta, ma
677 ; ZVFHMIN-NEXT: vfmul.vv v16, v16, v24, v0.t
678 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m4, ta, ma
679 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v16
680 ; ZVFHMIN-NEXT: csrr a0, vlenb
681 ; ZVFHMIN-NEXT: slli a1, a0, 4
682 ; ZVFHMIN-NEXT: add a0, a1, a0
683 ; ZVFHMIN-NEXT: add sp, sp, a0
684 ; ZVFHMIN-NEXT: .cfi_def_cfa sp, 16
685 ; ZVFHMIN-NEXT: addi sp, sp, 16
686 ; ZVFHMIN-NEXT: .cfi_def_cfa_offset 0
688 %elt.head = insertelement <vscale x 32 x half> poison, half %b, i32 0
689 %vb = shufflevector <vscale x 32 x half> %elt.head, <vscale x 32 x half> poison, <vscale x 32 x i32> zeroinitializer
690 %v = call <vscale x 32 x half> @llvm.vp.fmul.nxv32f16(<vscale x 32 x half> %va, <vscale x 32 x half> %vb, <vscale x 32 x i1> %m, i32 %evl)
691 ret <vscale x 32 x half> %v
694 define <vscale x 32 x half> @vfmul_vf_nxv32f16_unmasked(<vscale x 32 x half> %va, half %b, i32 zeroext %evl) {
695 ; ZVFH-LABEL: vfmul_vf_nxv32f16_unmasked:
697 ; ZVFH-NEXT: vsetvli zero, a0, e16, m8, ta, ma
698 ; ZVFH-NEXT: vfmul.vf v8, v8, fa0
701 ; ZVFHMIN-LABEL: vfmul_vf_nxv32f16_unmasked:
703 ; ZVFHMIN-NEXT: addi sp, sp, -16
704 ; ZVFHMIN-NEXT: .cfi_def_cfa_offset 16
705 ; ZVFHMIN-NEXT: csrr a1, vlenb
706 ; ZVFHMIN-NEXT: slli a1, a1, 4
707 ; ZVFHMIN-NEXT: sub sp, sp, a1
708 ; ZVFHMIN-NEXT: .cfi_escape 0x0f, 0x0d, 0x72, 0x00, 0x11, 0x10, 0x22, 0x11, 0x10, 0x92, 0xa2, 0x38, 0x00, 0x1e, 0x22 # sp + 16 + 16 * vlenb
709 ; ZVFHMIN-NEXT: vmv8r.v v16, v8
710 ; ZVFHMIN-NEXT: fmv.x.h a1, fa0
711 ; ZVFHMIN-NEXT: csrr a2, vlenb
712 ; ZVFHMIN-NEXT: vsetvli a3, zero, e8, m4, ta, ma
713 ; ZVFHMIN-NEXT: vmset.m v7
714 ; ZVFHMIN-NEXT: addi a3, sp, 16
715 ; ZVFHMIN-NEXT: vs8r.v v8, (a3) # Unknown-size Folded Spill
716 ; ZVFHMIN-NEXT: vsetvli a3, zero, e16, m4, ta, ma
717 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v8, v20
718 ; ZVFHMIN-NEXT: vsetvli a3, zero, e16, m8, ta, ma
719 ; ZVFHMIN-NEXT: vmv.v.x v16, a1
720 ; ZVFHMIN-NEXT: csrr a1, vlenb
721 ; ZVFHMIN-NEXT: slli a1, a1, 3
722 ; ZVFHMIN-NEXT: add a1, sp, a1
723 ; ZVFHMIN-NEXT: addi a1, a1, 16
724 ; ZVFHMIN-NEXT: vs8r.v v16, (a1) # Unknown-size Folded Spill
725 ; ZVFHMIN-NEXT: slli a1, a2, 1
726 ; ZVFHMIN-NEXT: srli a2, a2, 2
727 ; ZVFHMIN-NEXT: sub a3, a0, a1
728 ; ZVFHMIN-NEXT: vsetvli a4, zero, e8, mf2, ta, ma
729 ; ZVFHMIN-NEXT: vslidedown.vx v0, v7, a2
730 ; ZVFHMIN-NEXT: sltu a2, a0, a3
731 ; ZVFHMIN-NEXT: addi a2, a2, -1
732 ; ZVFHMIN-NEXT: and a2, a2, a3
733 ; ZVFHMIN-NEXT: csrr a3, vlenb
734 ; ZVFHMIN-NEXT: slli a3, a3, 3
735 ; ZVFHMIN-NEXT: add a3, sp, a3
736 ; ZVFHMIN-NEXT: addi a3, a3, 16
737 ; ZVFHMIN-NEXT: vl8r.v v24, (a3) # Unknown-size Folded Reload
738 ; ZVFHMIN-NEXT: vsetvli a3, zero, e16, m4, ta, ma
739 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v28
740 ; ZVFHMIN-NEXT: vsetvli zero, a2, e32, m8, ta, ma
741 ; ZVFHMIN-NEXT: vfmul.vv v16, v8, v16, v0.t
742 ; ZVFHMIN-NEXT: vsetvli a2, zero, e16, m4, ta, ma
743 ; ZVFHMIN-NEXT: vfncvt.f.f.w v12, v16
744 ; ZVFHMIN-NEXT: bltu a0, a1, .LBB23_2
745 ; ZVFHMIN-NEXT: # %bb.1:
746 ; ZVFHMIN-NEXT: mv a0, a1
747 ; ZVFHMIN-NEXT: .LBB23_2:
748 ; ZVFHMIN-NEXT: addi a1, sp, 16
749 ; ZVFHMIN-NEXT: vl8r.v v24, (a1) # Unknown-size Folded Reload
750 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v16, v24
751 ; ZVFHMIN-NEXT: csrr a1, vlenb
752 ; ZVFHMIN-NEXT: slli a1, a1, 3
753 ; ZVFHMIN-NEXT: add a1, sp, a1
754 ; ZVFHMIN-NEXT: addi a1, a1, 16
755 ; ZVFHMIN-NEXT: vl8r.v v0, (a1) # Unknown-size Folded Reload
756 ; ZVFHMIN-NEXT: vfwcvt.f.f.v v24, v0
757 ; ZVFHMIN-NEXT: vsetvli zero, a0, e32, m8, ta, ma
758 ; ZVFHMIN-NEXT: vfmul.vv v16, v16, v24
759 ; ZVFHMIN-NEXT: vsetvli a0, zero, e16, m4, ta, ma
760 ; ZVFHMIN-NEXT: vfncvt.f.f.w v8, v16
761 ; ZVFHMIN-NEXT: csrr a0, vlenb
762 ; ZVFHMIN-NEXT: slli a0, a0, 4
763 ; ZVFHMIN-NEXT: add sp, sp, a0
764 ; ZVFHMIN-NEXT: .cfi_def_cfa sp, 16
765 ; ZVFHMIN-NEXT: addi sp, sp, 16
766 ; ZVFHMIN-NEXT: .cfi_def_cfa_offset 0
768 %elt.head = insertelement <vscale x 32 x half> poison, half %b, i32 0
769 %vb = shufflevector <vscale x 32 x half> %elt.head, <vscale x 32 x half> poison, <vscale x 32 x i32> zeroinitializer
770 %v = call <vscale x 32 x half> @llvm.vp.fmul.nxv32f16(<vscale x 32 x half> %va, <vscale x 32 x half> %vb, <vscale x 32 x i1> splat (i1 true), i32 %evl)
771 ret <vscale x 32 x half> %v
774 declare <vscale x 1 x float> @llvm.vp.fmul.nxv1f32(<vscale x 1 x float>, <vscale x 1 x float>, <vscale x 1 x i1>, i32)
776 define <vscale x 1 x float> @vfmul_vv_nxv1f32(<vscale x 1 x float> %va, <vscale x 1 x float> %b, <vscale x 1 x i1> %m, i32 zeroext %evl) {
777 ; CHECK-LABEL: vfmul_vv_nxv1f32:
779 ; CHECK-NEXT: vsetvli zero, a0, e32, mf2, ta, ma
780 ; CHECK-NEXT: vfmul.vv v8, v8, v9, v0.t
782 %v = call <vscale x 1 x float> @llvm.vp.fmul.nxv1f32(<vscale x 1 x float> %va, <vscale x 1 x float> %b, <vscale x 1 x i1> %m, i32 %evl)
783 ret <vscale x 1 x float> %v
786 define <vscale x 1 x float> @vfmul_vv_nxv1f32_unmasked(<vscale x 1 x float> %va, <vscale x 1 x float> %b, i32 zeroext %evl) {
787 ; CHECK-LABEL: vfmul_vv_nxv1f32_unmasked:
789 ; CHECK-NEXT: vsetvli zero, a0, e32, mf2, ta, ma
790 ; CHECK-NEXT: vfmul.vv v8, v8, v9
792 %v = call <vscale x 1 x float> @llvm.vp.fmul.nxv1f32(<vscale x 1 x float> %va, <vscale x 1 x float> %b, <vscale x 1 x i1> splat (i1 true), i32 %evl)
793 ret <vscale x 1 x float> %v
796 define <vscale x 1 x float> @vfmul_vf_nxv1f32(<vscale x 1 x float> %va, float %b, <vscale x 1 x i1> %m, i32 zeroext %evl) {
797 ; CHECK-LABEL: vfmul_vf_nxv1f32:
799 ; CHECK-NEXT: vsetvli zero, a0, e32, mf2, ta, ma
800 ; CHECK-NEXT: vfmul.vf v8, v8, fa0, v0.t
802 %elt.head = insertelement <vscale x 1 x float> poison, float %b, i32 0
803 %vb = shufflevector <vscale x 1 x float> %elt.head, <vscale x 1 x float> poison, <vscale x 1 x i32> zeroinitializer
804 %v = call <vscale x 1 x float> @llvm.vp.fmul.nxv1f32(<vscale x 1 x float> %va, <vscale x 1 x float> %vb, <vscale x 1 x i1> %m, i32 %evl)
805 ret <vscale x 1 x float> %v
808 define <vscale x 1 x float> @vfmul_vf_nxv1f32_unmasked(<vscale x 1 x float> %va, float %b, i32 zeroext %evl) {
809 ; CHECK-LABEL: vfmul_vf_nxv1f32_unmasked:
811 ; CHECK-NEXT: vsetvli zero, a0, e32, mf2, ta, ma
812 ; CHECK-NEXT: vfmul.vf v8, v8, fa0
814 %elt.head = insertelement <vscale x 1 x float> poison, float %b, i32 0
815 %vb = shufflevector <vscale x 1 x float> %elt.head, <vscale x 1 x float> poison, <vscale x 1 x i32> zeroinitializer
816 %v = call <vscale x 1 x float> @llvm.vp.fmul.nxv1f32(<vscale x 1 x float> %va, <vscale x 1 x float> %vb, <vscale x 1 x i1> splat (i1 true), i32 %evl)
817 ret <vscale x 1 x float> %v
820 declare <vscale x 2 x float> @llvm.vp.fmul.nxv2f32(<vscale x 2 x float>, <vscale x 2 x float>, <vscale x 2 x i1>, i32)
822 define <vscale x 2 x float> @vfmul_vv_nxv2f32(<vscale x 2 x float> %va, <vscale x 2 x float> %b, <vscale x 2 x i1> %m, i32 zeroext %evl) {
823 ; CHECK-LABEL: vfmul_vv_nxv2f32:
825 ; CHECK-NEXT: vsetvli zero, a0, e32, m1, ta, ma
826 ; CHECK-NEXT: vfmul.vv v8, v8, v9, v0.t
828 %v = call <vscale x 2 x float> @llvm.vp.fmul.nxv2f32(<vscale x 2 x float> %va, <vscale x 2 x float> %b, <vscale x 2 x i1> %m, i32 %evl)
829 ret <vscale x 2 x float> %v
832 define <vscale x 2 x float> @vfmul_vv_nxv2f32_unmasked(<vscale x 2 x float> %va, <vscale x 2 x float> %b, i32 zeroext %evl) {
833 ; CHECK-LABEL: vfmul_vv_nxv2f32_unmasked:
835 ; CHECK-NEXT: vsetvli zero, a0, e32, m1, ta, ma
836 ; CHECK-NEXT: vfmul.vv v8, v8, v9
838 %v = call <vscale x 2 x float> @llvm.vp.fmul.nxv2f32(<vscale x 2 x float> %va, <vscale x 2 x float> %b, <vscale x 2 x i1> splat (i1 true), i32 %evl)
839 ret <vscale x 2 x float> %v
842 define <vscale x 2 x float> @vfmul_vf_nxv2f32(<vscale x 2 x float> %va, float %b, <vscale x 2 x i1> %m, i32 zeroext %evl) {
843 ; CHECK-LABEL: vfmul_vf_nxv2f32:
845 ; CHECK-NEXT: vsetvli zero, a0, e32, m1, ta, ma
846 ; CHECK-NEXT: vfmul.vf v8, v8, fa0, v0.t
848 %elt.head = insertelement <vscale x 2 x float> poison, float %b, i32 0
849 %vb = shufflevector <vscale x 2 x float> %elt.head, <vscale x 2 x float> poison, <vscale x 2 x i32> zeroinitializer
850 %v = call <vscale x 2 x float> @llvm.vp.fmul.nxv2f32(<vscale x 2 x float> %va, <vscale x 2 x float> %vb, <vscale x 2 x i1> %m, i32 %evl)
851 ret <vscale x 2 x float> %v
854 define <vscale x 2 x float> @vfmul_vf_nxv2f32_unmasked(<vscale x 2 x float> %va, float %b, i32 zeroext %evl) {
855 ; CHECK-LABEL: vfmul_vf_nxv2f32_unmasked:
857 ; CHECK-NEXT: vsetvli zero, a0, e32, m1, ta, ma
858 ; CHECK-NEXT: vfmul.vf v8, v8, fa0
860 %elt.head = insertelement <vscale x 2 x float> poison, float %b, i32 0
861 %vb = shufflevector <vscale x 2 x float> %elt.head, <vscale x 2 x float> poison, <vscale x 2 x i32> zeroinitializer
862 %v = call <vscale x 2 x float> @llvm.vp.fmul.nxv2f32(<vscale x 2 x float> %va, <vscale x 2 x float> %vb, <vscale x 2 x i1> splat (i1 true), i32 %evl)
863 ret <vscale x 2 x float> %v
866 declare <vscale x 4 x float> @llvm.vp.fmul.nxv4f32(<vscale x 4 x float>, <vscale x 4 x float>, <vscale x 4 x i1>, i32)
868 define <vscale x 4 x float> @vfmul_vv_nxv4f32(<vscale x 4 x float> %va, <vscale x 4 x float> %b, <vscale x 4 x i1> %m, i32 zeroext %evl) {
869 ; CHECK-LABEL: vfmul_vv_nxv4f32:
871 ; CHECK-NEXT: vsetvli zero, a0, e32, m2, ta, ma
872 ; CHECK-NEXT: vfmul.vv v8, v8, v10, v0.t
874 %v = call <vscale x 4 x float> @llvm.vp.fmul.nxv4f32(<vscale x 4 x float> %va, <vscale x 4 x float> %b, <vscale x 4 x i1> %m, i32 %evl)
875 ret <vscale x 4 x float> %v
878 define <vscale x 4 x float> @vfmul_vv_nxv4f32_unmasked(<vscale x 4 x float> %va, <vscale x 4 x float> %b, i32 zeroext %evl) {
879 ; CHECK-LABEL: vfmul_vv_nxv4f32_unmasked:
881 ; CHECK-NEXT: vsetvli zero, a0, e32, m2, ta, ma
882 ; CHECK-NEXT: vfmul.vv v8, v8, v10
884 %v = call <vscale x 4 x float> @llvm.vp.fmul.nxv4f32(<vscale x 4 x float> %va, <vscale x 4 x float> %b, <vscale x 4 x i1> splat (i1 true), i32 %evl)
885 ret <vscale x 4 x float> %v
888 define <vscale x 4 x float> @vfmul_vf_nxv4f32(<vscale x 4 x float> %va, float %b, <vscale x 4 x i1> %m, i32 zeroext %evl) {
889 ; CHECK-LABEL: vfmul_vf_nxv4f32:
891 ; CHECK-NEXT: vsetvli zero, a0, e32, m2, ta, ma
892 ; CHECK-NEXT: vfmul.vf v8, v8, fa0, v0.t
894 %elt.head = insertelement <vscale x 4 x float> poison, float %b, i32 0
895 %vb = shufflevector <vscale x 4 x float> %elt.head, <vscale x 4 x float> poison, <vscale x 4 x i32> zeroinitializer
896 %v = call <vscale x 4 x float> @llvm.vp.fmul.nxv4f32(<vscale x 4 x float> %va, <vscale x 4 x float> %vb, <vscale x 4 x i1> %m, i32 %evl)
897 ret <vscale x 4 x float> %v
900 define <vscale x 4 x float> @vfmul_vf_nxv4f32_unmasked(<vscale x 4 x float> %va, float %b, i32 zeroext %evl) {
901 ; CHECK-LABEL: vfmul_vf_nxv4f32_unmasked:
903 ; CHECK-NEXT: vsetvli zero, a0, e32, m2, ta, ma
904 ; CHECK-NEXT: vfmul.vf v8, v8, fa0
906 %elt.head = insertelement <vscale x 4 x float> poison, float %b, i32 0
907 %vb = shufflevector <vscale x 4 x float> %elt.head, <vscale x 4 x float> poison, <vscale x 4 x i32> zeroinitializer
908 %v = call <vscale x 4 x float> @llvm.vp.fmul.nxv4f32(<vscale x 4 x float> %va, <vscale x 4 x float> %vb, <vscale x 4 x i1> splat (i1 true), i32 %evl)
909 ret <vscale x 4 x float> %v
912 declare <vscale x 8 x float> @llvm.vp.fmul.nxv8f32(<vscale x 8 x float>, <vscale x 8 x float>, <vscale x 8 x i1>, i32)
914 define <vscale x 8 x float> @vfmul_vv_nxv8f32(<vscale x 8 x float> %va, <vscale x 8 x float> %b, <vscale x 8 x i1> %m, i32 zeroext %evl) {
915 ; CHECK-LABEL: vfmul_vv_nxv8f32:
917 ; CHECK-NEXT: vsetvli zero, a0, e32, m4, ta, ma
918 ; CHECK-NEXT: vfmul.vv v8, v8, v12, v0.t
920 %v = call <vscale x 8 x float> @llvm.vp.fmul.nxv8f32(<vscale x 8 x float> %va, <vscale x 8 x float> %b, <vscale x 8 x i1> %m, i32 %evl)
921 ret <vscale x 8 x float> %v
924 define <vscale x 8 x float> @vfmul_vv_nxv8f32_unmasked(<vscale x 8 x float> %va, <vscale x 8 x float> %b, i32 zeroext %evl) {
925 ; CHECK-LABEL: vfmul_vv_nxv8f32_unmasked:
927 ; CHECK-NEXT: vsetvli zero, a0, e32, m4, ta, ma
928 ; CHECK-NEXT: vfmul.vv v8, v8, v12
930 %v = call <vscale x 8 x float> @llvm.vp.fmul.nxv8f32(<vscale x 8 x float> %va, <vscale x 8 x float> %b, <vscale x 8 x i1> splat (i1 true), i32 %evl)
931 ret <vscale x 8 x float> %v
934 define <vscale x 8 x float> @vfmul_vf_nxv8f32(<vscale x 8 x float> %va, float %b, <vscale x 8 x i1> %m, i32 zeroext %evl) {
935 ; CHECK-LABEL: vfmul_vf_nxv8f32:
937 ; CHECK-NEXT: vsetvli zero, a0, e32, m4, ta, ma
938 ; CHECK-NEXT: vfmul.vf v8, v8, fa0, v0.t
940 %elt.head = insertelement <vscale x 8 x float> poison, float %b, i32 0
941 %vb = shufflevector <vscale x 8 x float> %elt.head, <vscale x 8 x float> poison, <vscale x 8 x i32> zeroinitializer
942 %v = call <vscale x 8 x float> @llvm.vp.fmul.nxv8f32(<vscale x 8 x float> %va, <vscale x 8 x float> %vb, <vscale x 8 x i1> %m, i32 %evl)
943 ret <vscale x 8 x float> %v
946 define <vscale x 8 x float> @vfmul_vf_nxv8f32_unmasked(<vscale x 8 x float> %va, float %b, i32 zeroext %evl) {
947 ; CHECK-LABEL: vfmul_vf_nxv8f32_unmasked:
949 ; CHECK-NEXT: vsetvli zero, a0, e32, m4, ta, ma
950 ; CHECK-NEXT: vfmul.vf v8, v8, fa0
952 %elt.head = insertelement <vscale x 8 x float> poison, float %b, i32 0
953 %vb = shufflevector <vscale x 8 x float> %elt.head, <vscale x 8 x float> poison, <vscale x 8 x i32> zeroinitializer
954 %v = call <vscale x 8 x float> @llvm.vp.fmul.nxv8f32(<vscale x 8 x float> %va, <vscale x 8 x float> %vb, <vscale x 8 x i1> splat (i1 true), i32 %evl)
955 ret <vscale x 8 x float> %v
958 declare <vscale x 16 x float> @llvm.vp.fmul.nxv16f32(<vscale x 16 x float>, <vscale x 16 x float>, <vscale x 16 x i1>, i32)
960 define <vscale x 16 x float> @vfmul_vv_nxv16f32(<vscale x 16 x float> %va, <vscale x 16 x float> %b, <vscale x 16 x i1> %m, i32 zeroext %evl) {
961 ; CHECK-LABEL: vfmul_vv_nxv16f32:
963 ; CHECK-NEXT: vsetvli zero, a0, e32, m8, ta, ma
964 ; CHECK-NEXT: vfmul.vv v8, v8, v16, v0.t
966 %v = call <vscale x 16 x float> @llvm.vp.fmul.nxv16f32(<vscale x 16 x float> %va, <vscale x 16 x float> %b, <vscale x 16 x i1> %m, i32 %evl)
967 ret <vscale x 16 x float> %v
970 define <vscale x 16 x float> @vfmul_vv_nxv16f32_unmasked(<vscale x 16 x float> %va, <vscale x 16 x float> %b, i32 zeroext %evl) {
971 ; CHECK-LABEL: vfmul_vv_nxv16f32_unmasked:
973 ; CHECK-NEXT: vsetvli zero, a0, e32, m8, ta, ma
974 ; CHECK-NEXT: vfmul.vv v8, v8, v16
976 %v = call <vscale x 16 x float> @llvm.vp.fmul.nxv16f32(<vscale x 16 x float> %va, <vscale x 16 x float> %b, <vscale x 16 x i1> splat (i1 true), i32 %evl)
977 ret <vscale x 16 x float> %v
980 define <vscale x 16 x float> @vfmul_vf_nxv16f32(<vscale x 16 x float> %va, float %b, <vscale x 16 x i1> %m, i32 zeroext %evl) {
981 ; CHECK-LABEL: vfmul_vf_nxv16f32:
983 ; CHECK-NEXT: vsetvli zero, a0, e32, m8, ta, ma
984 ; CHECK-NEXT: vfmul.vf v8, v8, fa0, v0.t
986 %elt.head = insertelement <vscale x 16 x float> poison, float %b, i32 0
987 %vb = shufflevector <vscale x 16 x float> %elt.head, <vscale x 16 x float> poison, <vscale x 16 x i32> zeroinitializer
988 %v = call <vscale x 16 x float> @llvm.vp.fmul.nxv16f32(<vscale x 16 x float> %va, <vscale x 16 x float> %vb, <vscale x 16 x i1> %m, i32 %evl)
989 ret <vscale x 16 x float> %v
992 define <vscale x 16 x float> @vfmul_vf_nxv16f32_unmasked(<vscale x 16 x float> %va, float %b, i32 zeroext %evl) {
993 ; CHECK-LABEL: vfmul_vf_nxv16f32_unmasked:
995 ; CHECK-NEXT: vsetvli zero, a0, e32, m8, ta, ma
996 ; CHECK-NEXT: vfmul.vf v8, v8, fa0
998 %elt.head = insertelement <vscale x 16 x float> poison, float %b, i32 0
999 %vb = shufflevector <vscale x 16 x float> %elt.head, <vscale x 16 x float> poison, <vscale x 16 x i32> zeroinitializer
1000 %v = call <vscale x 16 x float> @llvm.vp.fmul.nxv16f32(<vscale x 16 x float> %va, <vscale x 16 x float> %vb, <vscale x 16 x i1> splat (i1 true), i32 %evl)
1001 ret <vscale x 16 x float> %v
1004 declare <vscale x 1 x double> @llvm.vp.fmul.nxv1f64(<vscale x 1 x double>, <vscale x 1 x double>, <vscale x 1 x i1>, i32)
1006 define <vscale x 1 x double> @vfmul_vv_nxv1f64(<vscale x 1 x double> %va, <vscale x 1 x double> %b, <vscale x 1 x i1> %m, i32 zeroext %evl) {
1007 ; CHECK-LABEL: vfmul_vv_nxv1f64:
1009 ; CHECK-NEXT: vsetvli zero, a0, e64, m1, ta, ma
1010 ; CHECK-NEXT: vfmul.vv v8, v8, v9, v0.t
1012 %v = call <vscale x 1 x double> @llvm.vp.fmul.nxv1f64(<vscale x 1 x double> %va, <vscale x 1 x double> %b, <vscale x 1 x i1> %m, i32 %evl)
1013 ret <vscale x 1 x double> %v
1016 define <vscale x 1 x double> @vfmul_vv_nxv1f64_unmasked(<vscale x 1 x double> %va, <vscale x 1 x double> %b, i32 zeroext %evl) {
1017 ; CHECK-LABEL: vfmul_vv_nxv1f64_unmasked:
1019 ; CHECK-NEXT: vsetvli zero, a0, e64, m1, ta, ma
1020 ; CHECK-NEXT: vfmul.vv v8, v8, v9
1022 %v = call <vscale x 1 x double> @llvm.vp.fmul.nxv1f64(<vscale x 1 x double> %va, <vscale x 1 x double> %b, <vscale x 1 x i1> splat (i1 true), i32 %evl)
1023 ret <vscale x 1 x double> %v
1026 define <vscale x 1 x double> @vfmul_vf_nxv1f64(<vscale x 1 x double> %va, double %b, <vscale x 1 x i1> %m, i32 zeroext %evl) {
1027 ; CHECK-LABEL: vfmul_vf_nxv1f64:
1029 ; CHECK-NEXT: vsetvli zero, a0, e64, m1, ta, ma
1030 ; CHECK-NEXT: vfmul.vf v8, v8, fa0, v0.t
1032 %elt.head = insertelement <vscale x 1 x double> poison, double %b, i32 0
1033 %vb = shufflevector <vscale x 1 x double> %elt.head, <vscale x 1 x double> poison, <vscale x 1 x i32> zeroinitializer
1034 %v = call <vscale x 1 x double> @llvm.vp.fmul.nxv1f64(<vscale x 1 x double> %va, <vscale x 1 x double> %vb, <vscale x 1 x i1> %m, i32 %evl)
1035 ret <vscale x 1 x double> %v
1038 define <vscale x 1 x double> @vfmul_vf_nxv1f64_unmasked(<vscale x 1 x double> %va, double %b, i32 zeroext %evl) {
1039 ; CHECK-LABEL: vfmul_vf_nxv1f64_unmasked:
1041 ; CHECK-NEXT: vsetvli zero, a0, e64, m1, ta, ma
1042 ; CHECK-NEXT: vfmul.vf v8, v8, fa0
1044 %elt.head = insertelement <vscale x 1 x double> poison, double %b, i32 0
1045 %vb = shufflevector <vscale x 1 x double> %elt.head, <vscale x 1 x double> poison, <vscale x 1 x i32> zeroinitializer
1046 %v = call <vscale x 1 x double> @llvm.vp.fmul.nxv1f64(<vscale x 1 x double> %va, <vscale x 1 x double> %vb, <vscale x 1 x i1> splat (i1 true), i32 %evl)
1047 ret <vscale x 1 x double> %v
1050 declare <vscale x 2 x double> @llvm.vp.fmul.nxv2f64(<vscale x 2 x double>, <vscale x 2 x double>, <vscale x 2 x i1>, i32)
1052 define <vscale x 2 x double> @vfmul_vv_nxv2f64(<vscale x 2 x double> %va, <vscale x 2 x double> %b, <vscale x 2 x i1> %m, i32 zeroext %evl) {
1053 ; CHECK-LABEL: vfmul_vv_nxv2f64:
1055 ; CHECK-NEXT: vsetvli zero, a0, e64, m2, ta, ma
1056 ; CHECK-NEXT: vfmul.vv v8, v8, v10, v0.t
1058 %v = call <vscale x 2 x double> @llvm.vp.fmul.nxv2f64(<vscale x 2 x double> %va, <vscale x 2 x double> %b, <vscale x 2 x i1> %m, i32 %evl)
1059 ret <vscale x 2 x double> %v
1062 define <vscale x 2 x double> @vfmul_vv_nxv2f64_unmasked(<vscale x 2 x double> %va, <vscale x 2 x double> %b, i32 zeroext %evl) {
1063 ; CHECK-LABEL: vfmul_vv_nxv2f64_unmasked:
1065 ; CHECK-NEXT: vsetvli zero, a0, e64, m2, ta, ma
1066 ; CHECK-NEXT: vfmul.vv v8, v8, v10
1068 %v = call <vscale x 2 x double> @llvm.vp.fmul.nxv2f64(<vscale x 2 x double> %va, <vscale x 2 x double> %b, <vscale x 2 x i1> splat (i1 true), i32 %evl)
1069 ret <vscale x 2 x double> %v
1072 define <vscale x 2 x double> @vfmul_vf_nxv2f64(<vscale x 2 x double> %va, double %b, <vscale x 2 x i1> %m, i32 zeroext %evl) {
1073 ; CHECK-LABEL: vfmul_vf_nxv2f64:
1075 ; CHECK-NEXT: vsetvli zero, a0, e64, m2, ta, ma
1076 ; CHECK-NEXT: vfmul.vf v8, v8, fa0, v0.t
1078 %elt.head = insertelement <vscale x 2 x double> poison, double %b, i32 0
1079 %vb = shufflevector <vscale x 2 x double> %elt.head, <vscale x 2 x double> poison, <vscale x 2 x i32> zeroinitializer
1080 %v = call <vscale x 2 x double> @llvm.vp.fmul.nxv2f64(<vscale x 2 x double> %va, <vscale x 2 x double> %vb, <vscale x 2 x i1> %m, i32 %evl)
1081 ret <vscale x 2 x double> %v
1084 define <vscale x 2 x double> @vfmul_vf_nxv2f64_unmasked(<vscale x 2 x double> %va, double %b, i32 zeroext %evl) {
1085 ; CHECK-LABEL: vfmul_vf_nxv2f64_unmasked:
1087 ; CHECK-NEXT: vsetvli zero, a0, e64, m2, ta, ma
1088 ; CHECK-NEXT: vfmul.vf v8, v8, fa0
1090 %elt.head = insertelement <vscale x 2 x double> poison, double %b, i32 0
1091 %vb = shufflevector <vscale x 2 x double> %elt.head, <vscale x 2 x double> poison, <vscale x 2 x i32> zeroinitializer
1092 %v = call <vscale x 2 x double> @llvm.vp.fmul.nxv2f64(<vscale x 2 x double> %va, <vscale x 2 x double> %vb, <vscale x 2 x i1> splat (i1 true), i32 %evl)
1093 ret <vscale x 2 x double> %v
1096 declare <vscale x 4 x double> @llvm.vp.fmul.nxv4f64(<vscale x 4 x double>, <vscale x 4 x double>, <vscale x 4 x i1>, i32)
1098 define <vscale x 4 x double> @vfmul_vv_nxv4f64(<vscale x 4 x double> %va, <vscale x 4 x double> %b, <vscale x 4 x i1> %m, i32 zeroext %evl) {
1099 ; CHECK-LABEL: vfmul_vv_nxv4f64:
1101 ; CHECK-NEXT: vsetvli zero, a0, e64, m4, ta, ma
1102 ; CHECK-NEXT: vfmul.vv v8, v8, v12, v0.t
1104 %v = call <vscale x 4 x double> @llvm.vp.fmul.nxv4f64(<vscale x 4 x double> %va, <vscale x 4 x double> %b, <vscale x 4 x i1> %m, i32 %evl)
1105 ret <vscale x 4 x double> %v
1108 define <vscale x 4 x double> @vfmul_vv_nxv4f64_unmasked(<vscale x 4 x double> %va, <vscale x 4 x double> %b, i32 zeroext %evl) {
1109 ; CHECK-LABEL: vfmul_vv_nxv4f64_unmasked:
1111 ; CHECK-NEXT: vsetvli zero, a0, e64, m4, ta, ma
1112 ; CHECK-NEXT: vfmul.vv v8, v8, v12
1114 %v = call <vscale x 4 x double> @llvm.vp.fmul.nxv4f64(<vscale x 4 x double> %va, <vscale x 4 x double> %b, <vscale x 4 x i1> splat (i1 true), i32 %evl)
1115 ret <vscale x 4 x double> %v
1118 define <vscale x 4 x double> @vfmul_vf_nxv4f64(<vscale x 4 x double> %va, double %b, <vscale x 4 x i1> %m, i32 zeroext %evl) {
1119 ; CHECK-LABEL: vfmul_vf_nxv4f64:
1121 ; CHECK-NEXT: vsetvli zero, a0, e64, m4, ta, ma
1122 ; CHECK-NEXT: vfmul.vf v8, v8, fa0, v0.t
1124 %elt.head = insertelement <vscale x 4 x double> poison, double %b, i32 0
1125 %vb = shufflevector <vscale x 4 x double> %elt.head, <vscale x 4 x double> poison, <vscale x 4 x i32> zeroinitializer
1126 %v = call <vscale x 4 x double> @llvm.vp.fmul.nxv4f64(<vscale x 4 x double> %va, <vscale x 4 x double> %vb, <vscale x 4 x i1> %m, i32 %evl)
1127 ret <vscale x 4 x double> %v
1130 define <vscale x 4 x double> @vfmul_vf_nxv4f64_unmasked(<vscale x 4 x double> %va, double %b, i32 zeroext %evl) {
1131 ; CHECK-LABEL: vfmul_vf_nxv4f64_unmasked:
1133 ; CHECK-NEXT: vsetvli zero, a0, e64, m4, ta, ma
1134 ; CHECK-NEXT: vfmul.vf v8, v8, fa0
1136 %elt.head = insertelement <vscale x 4 x double> poison, double %b, i32 0
1137 %vb = shufflevector <vscale x 4 x double> %elt.head, <vscale x 4 x double> poison, <vscale x 4 x i32> zeroinitializer
1138 %v = call <vscale x 4 x double> @llvm.vp.fmul.nxv4f64(<vscale x 4 x double> %va, <vscale x 4 x double> %vb, <vscale x 4 x i1> splat (i1 true), i32 %evl)
1139 ret <vscale x 4 x double> %v
1142 declare <vscale x 7 x double> @llvm.vp.fmul.nxv7f64(<vscale x 7 x double>, <vscale x 7 x double>, <vscale x 7 x i1>, i32)
1144 define <vscale x 7 x double> @vfmul_vv_nxv7f64(<vscale x 7 x double> %va, <vscale x 7 x double> %b, <vscale x 7 x i1> %m, i32 zeroext %evl) {
1145 ; CHECK-LABEL: vfmul_vv_nxv7f64:
1147 ; CHECK-NEXT: vsetvli zero, a0, e64, m8, ta, ma
1148 ; CHECK-NEXT: vfmul.vv v8, v8, v16, v0.t
1150 %v = call <vscale x 7 x double> @llvm.vp.fmul.nxv7f64(<vscale x 7 x double> %va, <vscale x 7 x double> %b, <vscale x 7 x i1> %m, i32 %evl)
1151 ret <vscale x 7 x double> %v
1154 declare <vscale x 8 x double> @llvm.vp.fmul.nxv8f64(<vscale x 8 x double>, <vscale x 8 x double>, <vscale x 8 x i1>, i32)
1156 define <vscale x 8 x double> @vfmul_vv_nxv8f64(<vscale x 8 x double> %va, <vscale x 8 x double> %b, <vscale x 8 x i1> %m, i32 zeroext %evl) {
1157 ; CHECK-LABEL: vfmul_vv_nxv8f64:
1159 ; CHECK-NEXT: vsetvli zero, a0, e64, m8, ta, ma
1160 ; CHECK-NEXT: vfmul.vv v8, v8, v16, v0.t
1162 %v = call <vscale x 8 x double> @llvm.vp.fmul.nxv8f64(<vscale x 8 x double> %va, <vscale x 8 x double> %b, <vscale x 8 x i1> %m, i32 %evl)
1163 ret <vscale x 8 x double> %v
1166 define <vscale x 8 x double> @vfmul_vv_nxv8f64_unmasked(<vscale x 8 x double> %va, <vscale x 8 x double> %b, i32 zeroext %evl) {
1167 ; CHECK-LABEL: vfmul_vv_nxv8f64_unmasked:
1169 ; CHECK-NEXT: vsetvli zero, a0, e64, m8, ta, ma
1170 ; CHECK-NEXT: vfmul.vv v8, v8, v16
1172 %v = call <vscale x 8 x double> @llvm.vp.fmul.nxv8f64(<vscale x 8 x double> %va, <vscale x 8 x double> %b, <vscale x 8 x i1> splat (i1 true), i32 %evl)
1173 ret <vscale x 8 x double> %v
1176 define <vscale x 8 x double> @vfmul_vf_nxv8f64(<vscale x 8 x double> %va, double %b, <vscale x 8 x i1> %m, i32 zeroext %evl) {
1177 ; CHECK-LABEL: vfmul_vf_nxv8f64:
1179 ; CHECK-NEXT: vsetvli zero, a0, e64, m8, ta, ma
1180 ; CHECK-NEXT: vfmul.vf v8, v8, fa0, v0.t
1182 %elt.head = insertelement <vscale x 8 x double> poison, double %b, i32 0
1183 %vb = shufflevector <vscale x 8 x double> %elt.head, <vscale x 8 x double> poison, <vscale x 8 x i32> zeroinitializer
1184 %v = call <vscale x 8 x double> @llvm.vp.fmul.nxv8f64(<vscale x 8 x double> %va, <vscale x 8 x double> %vb, <vscale x 8 x i1> %m, i32 %evl)
1185 ret <vscale x 8 x double> %v
1188 define <vscale x 8 x double> @vfmul_vf_nxv8f64_unmasked(<vscale x 8 x double> %va, double %b, i32 zeroext %evl) {
1189 ; CHECK-LABEL: vfmul_vf_nxv8f64_unmasked:
1191 ; CHECK-NEXT: vsetvli zero, a0, e64, m8, ta, ma
1192 ; CHECK-NEXT: vfmul.vf v8, v8, fa0
1194 %elt.head = insertelement <vscale x 8 x double> poison, double %b, i32 0
1195 %vb = shufflevector <vscale x 8 x double> %elt.head, <vscale x 8 x double> poison, <vscale x 8 x i32> zeroinitializer
1196 %v = call <vscale x 8 x double> @llvm.vp.fmul.nxv8f64(<vscale x 8 x double> %va, <vscale x 8 x double> %vb, <vscale x 8 x i1> splat (i1 true), i32 %evl)
1197 ret <vscale x 8 x double> %v