1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: sed 's/iXLen/i32/g' %s | llc -mtriple=riscv32 -mattr=+v \
3 ; RUN: -verify-machineinstrs | FileCheck %s --check-prefixes=CHECK,RV32
4 ; RUN: sed 's/iXLen/i64/g' %s | llc -mtriple=riscv64 -mattr=+v \
5 ; RUN: -verify-machineinstrs | FileCheck %s --check-prefixes=CHECK,RV64
7 declare <vscale x 1 x i8> @llvm.riscv.vsbc.nxv1i8.nxv1i8(
14 define <vscale x 1 x i8> @intrinsic_vsbc_vvm_nxv1i8_nxv1i8_nxv1i8(<vscale x 1 x i8> %0, <vscale x 1 x i8> %1, <vscale x 1 x i1> %2, iXLen %3) nounwind {
15 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv1i8_nxv1i8_nxv1i8:
16 ; CHECK: # %bb.0: # %entry
17 ; CHECK-NEXT: vsetvli zero, a0, e8, mf8, ta, ma
18 ; CHECK-NEXT: vsbc.vvm v8, v8, v9, v0
21 %a = call <vscale x 1 x i8> @llvm.riscv.vsbc.nxv1i8.nxv1i8(
22 <vscale x 1 x i8> undef,
28 ret <vscale x 1 x i8> %a
31 declare <vscale x 2 x i8> @llvm.riscv.vsbc.nxv2i8.nxv2i8(
38 define <vscale x 2 x i8> @intrinsic_vsbc_vvm_nxv2i8_nxv2i8_nxv2i8(<vscale x 2 x i8> %0, <vscale x 2 x i8> %1, <vscale x 2 x i1> %2, iXLen %3) nounwind {
39 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv2i8_nxv2i8_nxv2i8:
40 ; CHECK: # %bb.0: # %entry
41 ; CHECK-NEXT: vsetvli zero, a0, e8, mf4, ta, ma
42 ; CHECK-NEXT: vsbc.vvm v8, v8, v9, v0
45 %a = call <vscale x 2 x i8> @llvm.riscv.vsbc.nxv2i8.nxv2i8(
46 <vscale x 2 x i8> undef,
52 ret <vscale x 2 x i8> %a
55 declare <vscale x 4 x i8> @llvm.riscv.vsbc.nxv4i8.nxv4i8(
62 define <vscale x 4 x i8> @intrinsic_vsbc_vvm_nxv4i8_nxv4i8_nxv4i8(<vscale x 4 x i8> %0, <vscale x 4 x i8> %1, <vscale x 4 x i1> %2, iXLen %3) nounwind {
63 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv4i8_nxv4i8_nxv4i8:
64 ; CHECK: # %bb.0: # %entry
65 ; CHECK-NEXT: vsetvli zero, a0, e8, mf2, ta, ma
66 ; CHECK-NEXT: vsbc.vvm v8, v8, v9, v0
69 %a = call <vscale x 4 x i8> @llvm.riscv.vsbc.nxv4i8.nxv4i8(
70 <vscale x 4 x i8> undef,
76 ret <vscale x 4 x i8> %a
79 declare <vscale x 8 x i8> @llvm.riscv.vsbc.nxv8i8.nxv8i8(
86 define <vscale x 8 x i8> @intrinsic_vsbc_vvm_nxv8i8_nxv8i8_nxv8i8(<vscale x 8 x i8> %0, <vscale x 8 x i8> %1, <vscale x 8 x i1> %2, iXLen %3) nounwind {
87 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv8i8_nxv8i8_nxv8i8:
88 ; CHECK: # %bb.0: # %entry
89 ; CHECK-NEXT: vsetvli zero, a0, e8, m1, ta, ma
90 ; CHECK-NEXT: vsbc.vvm v8, v8, v9, v0
93 %a = call <vscale x 8 x i8> @llvm.riscv.vsbc.nxv8i8.nxv8i8(
94 <vscale x 8 x i8> undef,
100 ret <vscale x 8 x i8> %a
103 declare <vscale x 16 x i8> @llvm.riscv.vsbc.nxv16i8.nxv16i8(
110 define <vscale x 16 x i8> @intrinsic_vsbc_vvm_nxv16i8_nxv16i8_nxv16i8(<vscale x 16 x i8> %0, <vscale x 16 x i8> %1, <vscale x 16 x i1> %2, iXLen %3) nounwind {
111 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv16i8_nxv16i8_nxv16i8:
112 ; CHECK: # %bb.0: # %entry
113 ; CHECK-NEXT: vsetvli zero, a0, e8, m2, ta, ma
114 ; CHECK-NEXT: vsbc.vvm v8, v8, v10, v0
117 %a = call <vscale x 16 x i8> @llvm.riscv.vsbc.nxv16i8.nxv16i8(
118 <vscale x 16 x i8> undef,
119 <vscale x 16 x i8> %0,
120 <vscale x 16 x i8> %1,
121 <vscale x 16 x i1> %2,
124 ret <vscale x 16 x i8> %a
127 declare <vscale x 32 x i8> @llvm.riscv.vsbc.nxv32i8.nxv32i8(
134 define <vscale x 32 x i8> @intrinsic_vsbc_vvm_nxv32i8_nxv32i8_nxv32i8(<vscale x 32 x i8> %0, <vscale x 32 x i8> %1, <vscale x 32 x i1> %2, iXLen %3) nounwind {
135 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv32i8_nxv32i8_nxv32i8:
136 ; CHECK: # %bb.0: # %entry
137 ; CHECK-NEXT: vsetvli zero, a0, e8, m4, ta, ma
138 ; CHECK-NEXT: vsbc.vvm v8, v8, v12, v0
141 %a = call <vscale x 32 x i8> @llvm.riscv.vsbc.nxv32i8.nxv32i8(
142 <vscale x 32 x i8> undef,
143 <vscale x 32 x i8> %0,
144 <vscale x 32 x i8> %1,
145 <vscale x 32 x i1> %2,
148 ret <vscale x 32 x i8> %a
151 declare <vscale x 64 x i8> @llvm.riscv.vsbc.nxv64i8.nxv64i8(
158 define <vscale x 64 x i8> @intrinsic_vsbc_vvm_nxv64i8_nxv64i8_nxv64i8(<vscale x 64 x i8> %0, <vscale x 64 x i8> %1, <vscale x 64 x i1> %2, iXLen %3) nounwind {
159 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv64i8_nxv64i8_nxv64i8:
160 ; CHECK: # %bb.0: # %entry
161 ; CHECK-NEXT: vsetvli zero, a0, e8, m8, ta, ma
162 ; CHECK-NEXT: vsbc.vvm v8, v8, v16, v0
165 %a = call <vscale x 64 x i8> @llvm.riscv.vsbc.nxv64i8.nxv64i8(
166 <vscale x 64 x i8> undef,
167 <vscale x 64 x i8> %0,
168 <vscale x 64 x i8> %1,
169 <vscale x 64 x i1> %2,
172 ret <vscale x 64 x i8> %a
175 declare <vscale x 1 x i16> @llvm.riscv.vsbc.nxv1i16.nxv1i16(
182 define <vscale x 1 x i16> @intrinsic_vsbc_vvm_nxv1i16_nxv1i16_nxv1i16(<vscale x 1 x i16> %0, <vscale x 1 x i16> %1, <vscale x 1 x i1> %2, iXLen %3) nounwind {
183 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv1i16_nxv1i16_nxv1i16:
184 ; CHECK: # %bb.0: # %entry
185 ; CHECK-NEXT: vsetvli zero, a0, e16, mf4, ta, ma
186 ; CHECK-NEXT: vsbc.vvm v8, v8, v9, v0
189 %a = call <vscale x 1 x i16> @llvm.riscv.vsbc.nxv1i16.nxv1i16(
190 <vscale x 1 x i16> undef,
191 <vscale x 1 x i16> %0,
192 <vscale x 1 x i16> %1,
193 <vscale x 1 x i1> %2,
196 ret <vscale x 1 x i16> %a
199 declare <vscale x 2 x i16> @llvm.riscv.vsbc.nxv2i16.nxv2i16(
206 define <vscale x 2 x i16> @intrinsic_vsbc_vvm_nxv2i16_nxv2i16_nxv2i16(<vscale x 2 x i16> %0, <vscale x 2 x i16> %1, <vscale x 2 x i1> %2, iXLen %3) nounwind {
207 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv2i16_nxv2i16_nxv2i16:
208 ; CHECK: # %bb.0: # %entry
209 ; CHECK-NEXT: vsetvli zero, a0, e16, mf2, ta, ma
210 ; CHECK-NEXT: vsbc.vvm v8, v8, v9, v0
213 %a = call <vscale x 2 x i16> @llvm.riscv.vsbc.nxv2i16.nxv2i16(
214 <vscale x 2 x i16> undef,
215 <vscale x 2 x i16> %0,
216 <vscale x 2 x i16> %1,
217 <vscale x 2 x i1> %2,
220 ret <vscale x 2 x i16> %a
223 declare <vscale x 4 x i16> @llvm.riscv.vsbc.nxv4i16.nxv4i16(
230 define <vscale x 4 x i16> @intrinsic_vsbc_vvm_nxv4i16_nxv4i16_nxv4i16(<vscale x 4 x i16> %0, <vscale x 4 x i16> %1, <vscale x 4 x i1> %2, iXLen %3) nounwind {
231 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv4i16_nxv4i16_nxv4i16:
232 ; CHECK: # %bb.0: # %entry
233 ; CHECK-NEXT: vsetvli zero, a0, e16, m1, ta, ma
234 ; CHECK-NEXT: vsbc.vvm v8, v8, v9, v0
237 %a = call <vscale x 4 x i16> @llvm.riscv.vsbc.nxv4i16.nxv4i16(
238 <vscale x 4 x i16> undef,
239 <vscale x 4 x i16> %0,
240 <vscale x 4 x i16> %1,
241 <vscale x 4 x i1> %2,
244 ret <vscale x 4 x i16> %a
247 declare <vscale x 8 x i16> @llvm.riscv.vsbc.nxv8i16.nxv8i16(
254 define <vscale x 8 x i16> @intrinsic_vsbc_vvm_nxv8i16_nxv8i16_nxv8i16(<vscale x 8 x i16> %0, <vscale x 8 x i16> %1, <vscale x 8 x i1> %2, iXLen %3) nounwind {
255 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv8i16_nxv8i16_nxv8i16:
256 ; CHECK: # %bb.0: # %entry
257 ; CHECK-NEXT: vsetvli zero, a0, e16, m2, ta, ma
258 ; CHECK-NEXT: vsbc.vvm v8, v8, v10, v0
261 %a = call <vscale x 8 x i16> @llvm.riscv.vsbc.nxv8i16.nxv8i16(
262 <vscale x 8 x i16> undef,
263 <vscale x 8 x i16> %0,
264 <vscale x 8 x i16> %1,
265 <vscale x 8 x i1> %2,
268 ret <vscale x 8 x i16> %a
271 declare <vscale x 16 x i16> @llvm.riscv.vsbc.nxv16i16.nxv16i16(
278 define <vscale x 16 x i16> @intrinsic_vsbc_vvm_nxv16i16_nxv16i16_nxv16i16(<vscale x 16 x i16> %0, <vscale x 16 x i16> %1, <vscale x 16 x i1> %2, iXLen %3) nounwind {
279 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv16i16_nxv16i16_nxv16i16:
280 ; CHECK: # %bb.0: # %entry
281 ; CHECK-NEXT: vsetvli zero, a0, e16, m4, ta, ma
282 ; CHECK-NEXT: vsbc.vvm v8, v8, v12, v0
285 %a = call <vscale x 16 x i16> @llvm.riscv.vsbc.nxv16i16.nxv16i16(
286 <vscale x 16 x i16> undef,
287 <vscale x 16 x i16> %0,
288 <vscale x 16 x i16> %1,
289 <vscale x 16 x i1> %2,
292 ret <vscale x 16 x i16> %a
295 declare <vscale x 32 x i16> @llvm.riscv.vsbc.nxv32i16.nxv32i16(
302 define <vscale x 32 x i16> @intrinsic_vsbc_vvm_nxv32i16_nxv32i16_nxv32i16(<vscale x 32 x i16> %0, <vscale x 32 x i16> %1, <vscale x 32 x i1> %2, iXLen %3) nounwind {
303 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv32i16_nxv32i16_nxv32i16:
304 ; CHECK: # %bb.0: # %entry
305 ; CHECK-NEXT: vsetvli zero, a0, e16, m8, ta, ma
306 ; CHECK-NEXT: vsbc.vvm v8, v8, v16, v0
309 %a = call <vscale x 32 x i16> @llvm.riscv.vsbc.nxv32i16.nxv32i16(
310 <vscale x 32 x i16> undef,
311 <vscale x 32 x i16> %0,
312 <vscale x 32 x i16> %1,
313 <vscale x 32 x i1> %2,
316 ret <vscale x 32 x i16> %a
319 declare <vscale x 1 x i32> @llvm.riscv.vsbc.nxv1i32.nxv1i32(
326 define <vscale x 1 x i32> @intrinsic_vsbc_vvm_nxv1i32_nxv1i32_nxv1i32(<vscale x 1 x i32> %0, <vscale x 1 x i32> %1, <vscale x 1 x i1> %2, iXLen %3) nounwind {
327 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv1i32_nxv1i32_nxv1i32:
328 ; CHECK: # %bb.0: # %entry
329 ; CHECK-NEXT: vsetvli zero, a0, e32, mf2, ta, ma
330 ; CHECK-NEXT: vsbc.vvm v8, v8, v9, v0
333 %a = call <vscale x 1 x i32> @llvm.riscv.vsbc.nxv1i32.nxv1i32(
334 <vscale x 1 x i32> undef,
335 <vscale x 1 x i32> %0,
336 <vscale x 1 x i32> %1,
337 <vscale x 1 x i1> %2,
340 ret <vscale x 1 x i32> %a
343 declare <vscale x 2 x i32> @llvm.riscv.vsbc.nxv2i32.nxv2i32(
350 define <vscale x 2 x i32> @intrinsic_vsbc_vvm_nxv2i32_nxv2i32_nxv2i32(<vscale x 2 x i32> %0, <vscale x 2 x i32> %1, <vscale x 2 x i1> %2, iXLen %3) nounwind {
351 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv2i32_nxv2i32_nxv2i32:
352 ; CHECK: # %bb.0: # %entry
353 ; CHECK-NEXT: vsetvli zero, a0, e32, m1, ta, ma
354 ; CHECK-NEXT: vsbc.vvm v8, v8, v9, v0
357 %a = call <vscale x 2 x i32> @llvm.riscv.vsbc.nxv2i32.nxv2i32(
358 <vscale x 2 x i32> undef,
359 <vscale x 2 x i32> %0,
360 <vscale x 2 x i32> %1,
361 <vscale x 2 x i1> %2,
364 ret <vscale x 2 x i32> %a
367 declare <vscale x 4 x i32> @llvm.riscv.vsbc.nxv4i32.nxv4i32(
374 define <vscale x 4 x i32> @intrinsic_vsbc_vvm_nxv4i32_nxv4i32_nxv4i32(<vscale x 4 x i32> %0, <vscale x 4 x i32> %1, <vscale x 4 x i1> %2, iXLen %3) nounwind {
375 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv4i32_nxv4i32_nxv4i32:
376 ; CHECK: # %bb.0: # %entry
377 ; CHECK-NEXT: vsetvli zero, a0, e32, m2, ta, ma
378 ; CHECK-NEXT: vsbc.vvm v8, v8, v10, v0
381 %a = call <vscale x 4 x i32> @llvm.riscv.vsbc.nxv4i32.nxv4i32(
382 <vscale x 4 x i32> undef,
383 <vscale x 4 x i32> %0,
384 <vscale x 4 x i32> %1,
385 <vscale x 4 x i1> %2,
388 ret <vscale x 4 x i32> %a
391 declare <vscale x 8 x i32> @llvm.riscv.vsbc.nxv8i32.nxv8i32(
398 define <vscale x 8 x i32> @intrinsic_vsbc_vvm_nxv8i32_nxv8i32_nxv8i32(<vscale x 8 x i32> %0, <vscale x 8 x i32> %1, <vscale x 8 x i1> %2, iXLen %3) nounwind {
399 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv8i32_nxv8i32_nxv8i32:
400 ; CHECK: # %bb.0: # %entry
401 ; CHECK-NEXT: vsetvli zero, a0, e32, m4, ta, ma
402 ; CHECK-NEXT: vsbc.vvm v8, v8, v12, v0
405 %a = call <vscale x 8 x i32> @llvm.riscv.vsbc.nxv8i32.nxv8i32(
406 <vscale x 8 x i32> undef,
407 <vscale x 8 x i32> %0,
408 <vscale x 8 x i32> %1,
409 <vscale x 8 x i1> %2,
412 ret <vscale x 8 x i32> %a
415 declare <vscale x 16 x i32> @llvm.riscv.vsbc.nxv16i32.nxv16i32(
422 define <vscale x 16 x i32> @intrinsic_vsbc_vvm_nxv16i32_nxv16i32_nxv16i32(<vscale x 16 x i32> %0, <vscale x 16 x i32> %1, <vscale x 16 x i1> %2, iXLen %3) nounwind {
423 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv16i32_nxv16i32_nxv16i32:
424 ; CHECK: # %bb.0: # %entry
425 ; CHECK-NEXT: vsetvli zero, a0, e32, m8, ta, ma
426 ; CHECK-NEXT: vsbc.vvm v8, v8, v16, v0
429 %a = call <vscale x 16 x i32> @llvm.riscv.vsbc.nxv16i32.nxv16i32(
430 <vscale x 16 x i32> undef,
431 <vscale x 16 x i32> %0,
432 <vscale x 16 x i32> %1,
433 <vscale x 16 x i1> %2,
436 ret <vscale x 16 x i32> %a
439 declare <vscale x 1 x i64> @llvm.riscv.vsbc.nxv1i64.nxv1i64(
446 define <vscale x 1 x i64> @intrinsic_vsbc_vvm_nxv1i64_nxv1i64_nxv1i64(<vscale x 1 x i64> %0, <vscale x 1 x i64> %1, <vscale x 1 x i1> %2, iXLen %3) nounwind {
447 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv1i64_nxv1i64_nxv1i64:
448 ; CHECK: # %bb.0: # %entry
449 ; CHECK-NEXT: vsetvli zero, a0, e64, m1, ta, ma
450 ; CHECK-NEXT: vsbc.vvm v8, v8, v9, v0
453 %a = call <vscale x 1 x i64> @llvm.riscv.vsbc.nxv1i64.nxv1i64(
454 <vscale x 1 x i64> undef,
455 <vscale x 1 x i64> %0,
456 <vscale x 1 x i64> %1,
457 <vscale x 1 x i1> %2,
460 ret <vscale x 1 x i64> %a
463 declare <vscale x 2 x i64> @llvm.riscv.vsbc.nxv2i64.nxv2i64(
470 define <vscale x 2 x i64> @intrinsic_vsbc_vvm_nxv2i64_nxv2i64_nxv2i64(<vscale x 2 x i64> %0, <vscale x 2 x i64> %1, <vscale x 2 x i1> %2, iXLen %3) nounwind {
471 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv2i64_nxv2i64_nxv2i64:
472 ; CHECK: # %bb.0: # %entry
473 ; CHECK-NEXT: vsetvli zero, a0, e64, m2, ta, ma
474 ; CHECK-NEXT: vsbc.vvm v8, v8, v10, v0
477 %a = call <vscale x 2 x i64> @llvm.riscv.vsbc.nxv2i64.nxv2i64(
478 <vscale x 2 x i64> undef,
479 <vscale x 2 x i64> %0,
480 <vscale x 2 x i64> %1,
481 <vscale x 2 x i1> %2,
484 ret <vscale x 2 x i64> %a
487 declare <vscale x 4 x i64> @llvm.riscv.vsbc.nxv4i64.nxv4i64(
494 define <vscale x 4 x i64> @intrinsic_vsbc_vvm_nxv4i64_nxv4i64_nxv4i64(<vscale x 4 x i64> %0, <vscale x 4 x i64> %1, <vscale x 4 x i1> %2, iXLen %3) nounwind {
495 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv4i64_nxv4i64_nxv4i64:
496 ; CHECK: # %bb.0: # %entry
497 ; CHECK-NEXT: vsetvli zero, a0, e64, m4, ta, ma
498 ; CHECK-NEXT: vsbc.vvm v8, v8, v12, v0
501 %a = call <vscale x 4 x i64> @llvm.riscv.vsbc.nxv4i64.nxv4i64(
502 <vscale x 4 x i64> undef,
503 <vscale x 4 x i64> %0,
504 <vscale x 4 x i64> %1,
505 <vscale x 4 x i1> %2,
508 ret <vscale x 4 x i64> %a
511 declare <vscale x 8 x i64> @llvm.riscv.vsbc.nxv8i64.nxv8i64(
518 define <vscale x 8 x i64> @intrinsic_vsbc_vvm_nxv8i64_nxv8i64_nxv8i64(<vscale x 8 x i64> %0, <vscale x 8 x i64> %1, <vscale x 8 x i1> %2, iXLen %3) nounwind {
519 ; CHECK-LABEL: intrinsic_vsbc_vvm_nxv8i64_nxv8i64_nxv8i64:
520 ; CHECK: # %bb.0: # %entry
521 ; CHECK-NEXT: vsetvli zero, a0, e64, m8, ta, ma
522 ; CHECK-NEXT: vsbc.vvm v8, v8, v16, v0
525 %a = call <vscale x 8 x i64> @llvm.riscv.vsbc.nxv8i64.nxv8i64(
526 <vscale x 8 x i64> undef,
527 <vscale x 8 x i64> %0,
528 <vscale x 8 x i64> %1,
529 <vscale x 8 x i1> %2,
532 ret <vscale x 8 x i64> %a
535 declare <vscale x 1 x i8> @llvm.riscv.vsbc.nxv1i8.i8(
542 define <vscale x 1 x i8> @intrinsic_vsbc_vxm_nxv1i8_nxv1i8_i8(<vscale x 1 x i8> %0, i8 %1, <vscale x 1 x i1> %2, iXLen %3) nounwind {
543 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv1i8_nxv1i8_i8:
544 ; CHECK: # %bb.0: # %entry
545 ; CHECK-NEXT: vsetvli zero, a1, e8, mf8, ta, ma
546 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
549 %a = call <vscale x 1 x i8> @llvm.riscv.vsbc.nxv1i8.i8(
550 <vscale x 1 x i8> undef,
551 <vscale x 1 x i8> %0,
553 <vscale x 1 x i1> %2,
556 ret <vscale x 1 x i8> %a
559 declare <vscale x 2 x i8> @llvm.riscv.vsbc.nxv2i8.i8(
566 define <vscale x 2 x i8> @intrinsic_vsbc_vxm_nxv2i8_nxv2i8_i8(<vscale x 2 x i8> %0, i8 %1, <vscale x 2 x i1> %2, iXLen %3) nounwind {
567 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv2i8_nxv2i8_i8:
568 ; CHECK: # %bb.0: # %entry
569 ; CHECK-NEXT: vsetvli zero, a1, e8, mf4, ta, ma
570 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
573 %a = call <vscale x 2 x i8> @llvm.riscv.vsbc.nxv2i8.i8(
574 <vscale x 2 x i8> undef,
575 <vscale x 2 x i8> %0,
577 <vscale x 2 x i1> %2,
580 ret <vscale x 2 x i8> %a
583 declare <vscale x 4 x i8> @llvm.riscv.vsbc.nxv4i8.i8(
590 define <vscale x 4 x i8> @intrinsic_vsbc_vxm_nxv4i8_nxv4i8_i8(<vscale x 4 x i8> %0, i8 %1, <vscale x 4 x i1> %2, iXLen %3) nounwind {
591 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv4i8_nxv4i8_i8:
592 ; CHECK: # %bb.0: # %entry
593 ; CHECK-NEXT: vsetvli zero, a1, e8, mf2, ta, ma
594 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
597 %a = call <vscale x 4 x i8> @llvm.riscv.vsbc.nxv4i8.i8(
598 <vscale x 4 x i8> undef,
599 <vscale x 4 x i8> %0,
601 <vscale x 4 x i1> %2,
604 ret <vscale x 4 x i8> %a
607 declare <vscale x 8 x i8> @llvm.riscv.vsbc.nxv8i8.i8(
614 define <vscale x 8 x i8> @intrinsic_vsbc_vxm_nxv8i8_nxv8i8_i8(<vscale x 8 x i8> %0, i8 %1, <vscale x 8 x i1> %2, iXLen %3) nounwind {
615 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv8i8_nxv8i8_i8:
616 ; CHECK: # %bb.0: # %entry
617 ; CHECK-NEXT: vsetvli zero, a1, e8, m1, ta, ma
618 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
621 %a = call <vscale x 8 x i8> @llvm.riscv.vsbc.nxv8i8.i8(
622 <vscale x 8 x i8> undef,
623 <vscale x 8 x i8> %0,
625 <vscale x 8 x i1> %2,
628 ret <vscale x 8 x i8> %a
631 declare <vscale x 16 x i8> @llvm.riscv.vsbc.nxv16i8.i8(
638 define <vscale x 16 x i8> @intrinsic_vsbc_vxm_nxv16i8_nxv16i8_i8(<vscale x 16 x i8> %0, i8 %1, <vscale x 16 x i1> %2, iXLen %3) nounwind {
639 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv16i8_nxv16i8_i8:
640 ; CHECK: # %bb.0: # %entry
641 ; CHECK-NEXT: vsetvli zero, a1, e8, m2, ta, ma
642 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
645 %a = call <vscale x 16 x i8> @llvm.riscv.vsbc.nxv16i8.i8(
646 <vscale x 16 x i8> undef,
647 <vscale x 16 x i8> %0,
649 <vscale x 16 x i1> %2,
652 ret <vscale x 16 x i8> %a
655 declare <vscale x 32 x i8> @llvm.riscv.vsbc.nxv32i8.i8(
662 define <vscale x 32 x i8> @intrinsic_vsbc_vxm_nxv32i8_nxv32i8_i8(<vscale x 32 x i8> %0, i8 %1, <vscale x 32 x i1> %2, iXLen %3) nounwind {
663 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv32i8_nxv32i8_i8:
664 ; CHECK: # %bb.0: # %entry
665 ; CHECK-NEXT: vsetvli zero, a1, e8, m4, ta, ma
666 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
669 %a = call <vscale x 32 x i8> @llvm.riscv.vsbc.nxv32i8.i8(
670 <vscale x 32 x i8> undef,
671 <vscale x 32 x i8> %0,
673 <vscale x 32 x i1> %2,
676 ret <vscale x 32 x i8> %a
679 declare <vscale x 64 x i8> @llvm.riscv.vsbc.nxv64i8.i8(
686 define <vscale x 64 x i8> @intrinsic_vsbc_vxm_nxv64i8_nxv64i8_i8(<vscale x 64 x i8> %0, i8 %1, <vscale x 64 x i1> %2, iXLen %3) nounwind {
687 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv64i8_nxv64i8_i8:
688 ; CHECK: # %bb.0: # %entry
689 ; CHECK-NEXT: vsetvli zero, a1, e8, m8, ta, ma
690 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
693 %a = call <vscale x 64 x i8> @llvm.riscv.vsbc.nxv64i8.i8(
694 <vscale x 64 x i8> undef,
695 <vscale x 64 x i8> %0,
697 <vscale x 64 x i1> %2,
700 ret <vscale x 64 x i8> %a
703 declare <vscale x 1 x i16> @llvm.riscv.vsbc.nxv1i16.i16(
710 define <vscale x 1 x i16> @intrinsic_vsbc_vxm_nxv1i16_nxv1i16_i16(<vscale x 1 x i16> %0, i16 %1, <vscale x 1 x i1> %2, iXLen %3) nounwind {
711 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv1i16_nxv1i16_i16:
712 ; CHECK: # %bb.0: # %entry
713 ; CHECK-NEXT: vsetvli zero, a1, e16, mf4, ta, ma
714 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
717 %a = call <vscale x 1 x i16> @llvm.riscv.vsbc.nxv1i16.i16(
718 <vscale x 1 x i16> undef,
719 <vscale x 1 x i16> %0,
721 <vscale x 1 x i1> %2,
724 ret <vscale x 1 x i16> %a
727 declare <vscale x 2 x i16> @llvm.riscv.vsbc.nxv2i16.i16(
734 define <vscale x 2 x i16> @intrinsic_vsbc_vxm_nxv2i16_nxv2i16_i16(<vscale x 2 x i16> %0, i16 %1, <vscale x 2 x i1> %2, iXLen %3) nounwind {
735 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv2i16_nxv2i16_i16:
736 ; CHECK: # %bb.0: # %entry
737 ; CHECK-NEXT: vsetvli zero, a1, e16, mf2, ta, ma
738 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
741 %a = call <vscale x 2 x i16> @llvm.riscv.vsbc.nxv2i16.i16(
742 <vscale x 2 x i16> undef,
743 <vscale x 2 x i16> %0,
745 <vscale x 2 x i1> %2,
748 ret <vscale x 2 x i16> %a
751 declare <vscale x 4 x i16> @llvm.riscv.vsbc.nxv4i16.i16(
758 define <vscale x 4 x i16> @intrinsic_vsbc_vxm_nxv4i16_nxv4i16_i16(<vscale x 4 x i16> %0, i16 %1, <vscale x 4 x i1> %2, iXLen %3) nounwind {
759 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv4i16_nxv4i16_i16:
760 ; CHECK: # %bb.0: # %entry
761 ; CHECK-NEXT: vsetvli zero, a1, e16, m1, ta, ma
762 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
765 %a = call <vscale x 4 x i16> @llvm.riscv.vsbc.nxv4i16.i16(
766 <vscale x 4 x i16> undef,
767 <vscale x 4 x i16> %0,
769 <vscale x 4 x i1> %2,
772 ret <vscale x 4 x i16> %a
775 declare <vscale x 8 x i16> @llvm.riscv.vsbc.nxv8i16.i16(
782 define <vscale x 8 x i16> @intrinsic_vsbc_vxm_nxv8i16_nxv8i16_i16(<vscale x 8 x i16> %0, i16 %1, <vscale x 8 x i1> %2, iXLen %3) nounwind {
783 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv8i16_nxv8i16_i16:
784 ; CHECK: # %bb.0: # %entry
785 ; CHECK-NEXT: vsetvli zero, a1, e16, m2, ta, ma
786 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
789 %a = call <vscale x 8 x i16> @llvm.riscv.vsbc.nxv8i16.i16(
790 <vscale x 8 x i16> undef,
791 <vscale x 8 x i16> %0,
793 <vscale x 8 x i1> %2,
796 ret <vscale x 8 x i16> %a
799 declare <vscale x 16 x i16> @llvm.riscv.vsbc.nxv16i16.i16(
806 define <vscale x 16 x i16> @intrinsic_vsbc_vxm_nxv16i16_nxv16i16_i16(<vscale x 16 x i16> %0, i16 %1, <vscale x 16 x i1> %2, iXLen %3) nounwind {
807 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv16i16_nxv16i16_i16:
808 ; CHECK: # %bb.0: # %entry
809 ; CHECK-NEXT: vsetvli zero, a1, e16, m4, ta, ma
810 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
813 %a = call <vscale x 16 x i16> @llvm.riscv.vsbc.nxv16i16.i16(
814 <vscale x 16 x i16> undef,
815 <vscale x 16 x i16> %0,
817 <vscale x 16 x i1> %2,
820 ret <vscale x 16 x i16> %a
823 declare <vscale x 32 x i16> @llvm.riscv.vsbc.nxv32i16.i16(
830 define <vscale x 32 x i16> @intrinsic_vsbc_vxm_nxv32i16_nxv32i16_i16(<vscale x 32 x i16> %0, i16 %1, <vscale x 32 x i1> %2, iXLen %3) nounwind {
831 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv32i16_nxv32i16_i16:
832 ; CHECK: # %bb.0: # %entry
833 ; CHECK-NEXT: vsetvli zero, a1, e16, m8, ta, ma
834 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
837 %a = call <vscale x 32 x i16> @llvm.riscv.vsbc.nxv32i16.i16(
838 <vscale x 32 x i16> undef,
839 <vscale x 32 x i16> %0,
841 <vscale x 32 x i1> %2,
844 ret <vscale x 32 x i16> %a
847 declare <vscale x 1 x i32> @llvm.riscv.vsbc.nxv1i32.i32(
854 define <vscale x 1 x i32> @intrinsic_vsbc_vxm_nxv1i32_nxv1i32_i32(<vscale x 1 x i32> %0, i32 %1, <vscale x 1 x i1> %2, iXLen %3) nounwind {
855 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv1i32_nxv1i32_i32:
856 ; CHECK: # %bb.0: # %entry
857 ; CHECK-NEXT: vsetvli zero, a1, e32, mf2, ta, ma
858 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
861 %a = call <vscale x 1 x i32> @llvm.riscv.vsbc.nxv1i32.i32(
862 <vscale x 1 x i32> undef,
863 <vscale x 1 x i32> %0,
865 <vscale x 1 x i1> %2,
868 ret <vscale x 1 x i32> %a
871 declare <vscale x 2 x i32> @llvm.riscv.vsbc.nxv2i32.i32(
878 define <vscale x 2 x i32> @intrinsic_vsbc_vxm_nxv2i32_nxv2i32_i32(<vscale x 2 x i32> %0, i32 %1, <vscale x 2 x i1> %2, iXLen %3) nounwind {
879 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv2i32_nxv2i32_i32:
880 ; CHECK: # %bb.0: # %entry
881 ; CHECK-NEXT: vsetvli zero, a1, e32, m1, ta, ma
882 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
885 %a = call <vscale x 2 x i32> @llvm.riscv.vsbc.nxv2i32.i32(
886 <vscale x 2 x i32> undef,
887 <vscale x 2 x i32> %0,
889 <vscale x 2 x i1> %2,
892 ret <vscale x 2 x i32> %a
895 declare <vscale x 4 x i32> @llvm.riscv.vsbc.nxv4i32.i32(
902 define <vscale x 4 x i32> @intrinsic_vsbc_vxm_nxv4i32_nxv4i32_i32(<vscale x 4 x i32> %0, i32 %1, <vscale x 4 x i1> %2, iXLen %3) nounwind {
903 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv4i32_nxv4i32_i32:
904 ; CHECK: # %bb.0: # %entry
905 ; CHECK-NEXT: vsetvli zero, a1, e32, m2, ta, ma
906 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
909 %a = call <vscale x 4 x i32> @llvm.riscv.vsbc.nxv4i32.i32(
910 <vscale x 4 x i32> undef,
911 <vscale x 4 x i32> %0,
913 <vscale x 4 x i1> %2,
916 ret <vscale x 4 x i32> %a
919 declare <vscale x 8 x i32> @llvm.riscv.vsbc.nxv8i32.i32(
926 define <vscale x 8 x i32> @intrinsic_vsbc_vxm_nxv8i32_nxv8i32_i32(<vscale x 8 x i32> %0, i32 %1, <vscale x 8 x i1> %2, iXLen %3) nounwind {
927 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv8i32_nxv8i32_i32:
928 ; CHECK: # %bb.0: # %entry
929 ; CHECK-NEXT: vsetvli zero, a1, e32, m4, ta, ma
930 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
933 %a = call <vscale x 8 x i32> @llvm.riscv.vsbc.nxv8i32.i32(
934 <vscale x 8 x i32> undef,
935 <vscale x 8 x i32> %0,
937 <vscale x 8 x i1> %2,
940 ret <vscale x 8 x i32> %a
943 declare <vscale x 16 x i32> @llvm.riscv.vsbc.nxv16i32.i32(
950 define <vscale x 16 x i32> @intrinsic_vsbc_vxm_nxv16i32_nxv16i32_i32(<vscale x 16 x i32> %0, i32 %1, <vscale x 16 x i1> %2, iXLen %3) nounwind {
951 ; CHECK-LABEL: intrinsic_vsbc_vxm_nxv16i32_nxv16i32_i32:
952 ; CHECK: # %bb.0: # %entry
953 ; CHECK-NEXT: vsetvli zero, a1, e32, m8, ta, ma
954 ; CHECK-NEXT: vsbc.vxm v8, v8, a0, v0
957 %a = call <vscale x 16 x i32> @llvm.riscv.vsbc.nxv16i32.i32(
958 <vscale x 16 x i32> undef,
959 <vscale x 16 x i32> %0,
961 <vscale x 16 x i1> %2,
964 ret <vscale x 16 x i32> %a
967 declare <vscale x 1 x i64> @llvm.riscv.vsbc.nxv1i64.i64(
974 define <vscale x 1 x i64> @intrinsic_vsbc_vxm_nxv1i64_nxv1i64_i64(<vscale x 1 x i64> %0, i64 %1, <vscale x 1 x i1> %2, iXLen %3) nounwind {
975 ; RV32-LABEL: intrinsic_vsbc_vxm_nxv1i64_nxv1i64_i64:
976 ; RV32: # %bb.0: # %entry
977 ; RV32-NEXT: addi sp, sp, -16
978 ; RV32-NEXT: sw a0, 8(sp)
979 ; RV32-NEXT: sw a1, 12(sp)
980 ; RV32-NEXT: addi a0, sp, 8
981 ; RV32-NEXT: vsetvli zero, a2, e64, m1, ta, ma
982 ; RV32-NEXT: vlse64.v v9, (a0), zero
983 ; RV32-NEXT: vsbc.vvm v8, v8, v9, v0
984 ; RV32-NEXT: addi sp, sp, 16
987 ; RV64-LABEL: intrinsic_vsbc_vxm_nxv1i64_nxv1i64_i64:
988 ; RV64: # %bb.0: # %entry
989 ; RV64-NEXT: vsetvli zero, a1, e64, m1, ta, ma
990 ; RV64-NEXT: vsbc.vxm v8, v8, a0, v0
993 %a = call <vscale x 1 x i64> @llvm.riscv.vsbc.nxv1i64.i64(
994 <vscale x 1 x i64> undef,
995 <vscale x 1 x i64> %0,
997 <vscale x 1 x i1> %2,
1000 ret <vscale x 1 x i64> %a
1003 declare <vscale x 2 x i64> @llvm.riscv.vsbc.nxv2i64.i64(
1010 define <vscale x 2 x i64> @intrinsic_vsbc_vxm_nxv2i64_nxv2i64_i64(<vscale x 2 x i64> %0, i64 %1, <vscale x 2 x i1> %2, iXLen %3) nounwind {
1011 ; RV32-LABEL: intrinsic_vsbc_vxm_nxv2i64_nxv2i64_i64:
1012 ; RV32: # %bb.0: # %entry
1013 ; RV32-NEXT: addi sp, sp, -16
1014 ; RV32-NEXT: sw a0, 8(sp)
1015 ; RV32-NEXT: sw a1, 12(sp)
1016 ; RV32-NEXT: addi a0, sp, 8
1017 ; RV32-NEXT: vsetvli zero, a2, e64, m2, ta, ma
1018 ; RV32-NEXT: vlse64.v v10, (a0), zero
1019 ; RV32-NEXT: vsbc.vvm v8, v8, v10, v0
1020 ; RV32-NEXT: addi sp, sp, 16
1023 ; RV64-LABEL: intrinsic_vsbc_vxm_nxv2i64_nxv2i64_i64:
1024 ; RV64: # %bb.0: # %entry
1025 ; RV64-NEXT: vsetvli zero, a1, e64, m2, ta, ma
1026 ; RV64-NEXT: vsbc.vxm v8, v8, a0, v0
1029 %a = call <vscale x 2 x i64> @llvm.riscv.vsbc.nxv2i64.i64(
1030 <vscale x 2 x i64> undef,
1031 <vscale x 2 x i64> %0,
1033 <vscale x 2 x i1> %2,
1036 ret <vscale x 2 x i64> %a
1039 declare <vscale x 4 x i64> @llvm.riscv.vsbc.nxv4i64.i64(
1046 define <vscale x 4 x i64> @intrinsic_vsbc_vxm_nxv4i64_nxv4i64_i64(<vscale x 4 x i64> %0, i64 %1, <vscale x 4 x i1> %2, iXLen %3) nounwind {
1047 ; RV32-LABEL: intrinsic_vsbc_vxm_nxv4i64_nxv4i64_i64:
1048 ; RV32: # %bb.0: # %entry
1049 ; RV32-NEXT: addi sp, sp, -16
1050 ; RV32-NEXT: sw a0, 8(sp)
1051 ; RV32-NEXT: sw a1, 12(sp)
1052 ; RV32-NEXT: addi a0, sp, 8
1053 ; RV32-NEXT: vsetvli zero, a2, e64, m4, ta, ma
1054 ; RV32-NEXT: vlse64.v v12, (a0), zero
1055 ; RV32-NEXT: vsbc.vvm v8, v8, v12, v0
1056 ; RV32-NEXT: addi sp, sp, 16
1059 ; RV64-LABEL: intrinsic_vsbc_vxm_nxv4i64_nxv4i64_i64:
1060 ; RV64: # %bb.0: # %entry
1061 ; RV64-NEXT: vsetvli zero, a1, e64, m4, ta, ma
1062 ; RV64-NEXT: vsbc.vxm v8, v8, a0, v0
1065 %a = call <vscale x 4 x i64> @llvm.riscv.vsbc.nxv4i64.i64(
1066 <vscale x 4 x i64> undef,
1067 <vscale x 4 x i64> %0,
1069 <vscale x 4 x i1> %2,
1072 ret <vscale x 4 x i64> %a
1075 declare <vscale x 8 x i64> @llvm.riscv.vsbc.nxv8i64.i64(
1082 define <vscale x 8 x i64> @intrinsic_vsbc_vxm_nxv8i64_nxv8i64_i64(<vscale x 8 x i64> %0, i64 %1, <vscale x 8 x i1> %2, iXLen %3) nounwind {
1083 ; RV32-LABEL: intrinsic_vsbc_vxm_nxv8i64_nxv8i64_i64:
1084 ; RV32: # %bb.0: # %entry
1085 ; RV32-NEXT: addi sp, sp, -16
1086 ; RV32-NEXT: sw a0, 8(sp)
1087 ; RV32-NEXT: sw a1, 12(sp)
1088 ; RV32-NEXT: addi a0, sp, 8
1089 ; RV32-NEXT: vsetvli zero, a2, e64, m8, ta, ma
1090 ; RV32-NEXT: vlse64.v v16, (a0), zero
1091 ; RV32-NEXT: vsbc.vvm v8, v8, v16, v0
1092 ; RV32-NEXT: addi sp, sp, 16
1095 ; RV64-LABEL: intrinsic_vsbc_vxm_nxv8i64_nxv8i64_i64:
1096 ; RV64: # %bb.0: # %entry
1097 ; RV64-NEXT: vsetvli zero, a1, e64, m8, ta, ma
1098 ; RV64-NEXT: vsbc.vxm v8, v8, a0, v0
1101 %a = call <vscale x 8 x i64> @llvm.riscv.vsbc.nxv8i64.i64(
1102 <vscale x 8 x i64> undef,
1103 <vscale x 8 x i64> %0,
1105 <vscale x 8 x i1> %2,
1108 ret <vscale x 8 x i64> %a