4
4
; RUN: sed 's/iXLen/i32/g' %s | llc -mtriple=riscv32 -mattr=+v,+zvbb -riscv-enable-vl-optimizer -verify-machineinstrs | FileCheck %s --check-prefixes=VLOPT
5
5
; RUN: sed 's/iXLen/i64/g' %s | llc -mtriple=riscv64 -mattr=+v,+zvbb -riscv-enable-vl-optimizer -verify-machineinstrs | FileCheck %s --check-prefixes=VLOPT
6
6
7
- ; The purpose of this test is to check the behavior of specific instructions as it relates to the VL optimizer
7
+ ; The purpose of this file is to check the behavior of specific instructions as it relates to the VL optimizer
8
8
9
9
define <vscale x 4 x i32 > @vadd_vi (<vscale x 4 x i32 > %a , iXLen %vl ) {
10
10
; NOVLOPT-LABEL: vadd_vi:
@@ -146,7 +146,7 @@ define <vscale x 4 x i32> @vrsub_vx(<vscale x 4 x i32> %a, i32 %b, iXLen %vl) {
146
146
ret <vscale x 4 x i32 > %2
147
147
}
148
148
149
- define <vscale x 4 x i64 > @vwaddu.vv (<vscale x 4 x i32 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
149
+ define <vscale x 4 x i64 > @vwaddu_vv (<vscale x 4 x i32 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
150
150
; NOVLOPT-LABEL: vwaddu.vv:
151
151
; NOVLOPT: # %bb.0:
152
152
; NOVLOPT-NEXT: vsetvli a1, zero, e32, m2, ta, ma
@@ -167,7 +167,7 @@ define <vscale x 4 x i64> @vwaddu.vv(<vscale x 4 x i32> %a, <vscale x 4 x i32> %
167
167
ret <vscale x 4 x i64 > %2
168
168
}
169
169
170
- define <vscale x 4 x i64 > @vwaddu.vx (<vscale x 4 x i32 > %a , i32 %b , iXLen %vl ) {
170
+ define <vscale x 4 x i64 > @vwaddu_vx (<vscale x 4 x i32 > %a , i32 %b , iXLen %vl ) {
171
171
; NOVLOPT-LABEL: vwaddu.vx:
172
172
; NOVLOPT: # %bb.0:
173
173
; NOVLOPT-NEXT: vsetvli a2, zero, e32, m2, ta, ma
@@ -188,7 +188,7 @@ define <vscale x 4 x i64> @vwaddu.vx(<vscale x 4 x i32> %a, i32 %b, iXLen %vl) {
188
188
ret <vscale x 4 x i64 > %2
189
189
}
190
190
191
- define <vscale x 4 x i64 > @vwsubu.vv (<vscale x 4 x i32 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
191
+ define <vscale x 4 x i64 > @vwsubu_vv (<vscale x 4 x i32 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
192
192
; NOVLOPT-LABEL: vwsubu.vv:
193
193
; NOVLOPT: # %bb.0:
194
194
; NOVLOPT-NEXT: vsetvli a1, zero, e32, m2, ta, ma
@@ -209,7 +209,7 @@ define <vscale x 4 x i64> @vwsubu.vv(<vscale x 4 x i32> %a, <vscale x 4 x i32> %
209
209
ret <vscale x 4 x i64 > %2
210
210
}
211
211
212
- define <vscale x 4 x i64 > @vwsubu.vx (<vscale x 4 x i32 > %a , i32 %b , iXLen %vl ) {
212
+ define <vscale x 4 x i64 > @vwsubu_vx (<vscale x 4 x i32 > %a , i32 %b , iXLen %vl ) {
213
213
; NOVLOPT-LABEL: vwsubu.vx:
214
214
; NOVLOPT: # %bb.0:
215
215
; NOVLOPT-NEXT: vsetvli a2, zero, e32, m2, ta, ma
@@ -230,7 +230,7 @@ define <vscale x 4 x i64> @vwsubu.vx(<vscale x 4 x i32> %a, i32 %b, iXLen %vl) {
230
230
ret <vscale x 4 x i64 > %2
231
231
}
232
232
233
- define <vscale x 4 x i64 > @vwadd.vv (<vscale x 4 x i32 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
233
+ define <vscale x 4 x i64 > @vwadd_vv (<vscale x 4 x i32 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
234
234
; NOVLOPT-LABEL: vwadd.vv:
235
235
; NOVLOPT: # %bb.0:
236
236
; NOVLOPT-NEXT: vsetvli a1, zero, e32, m2, ta, ma
@@ -251,7 +251,7 @@ define <vscale x 4 x i64> @vwadd.vv(<vscale x 4 x i32> %a, <vscale x 4 x i32> %b
251
251
ret <vscale x 4 x i64 > %2
252
252
}
253
253
254
- define <vscale x 4 x i64 > @vwadd.vx (<vscale x 4 x i32 > %a , i32 %b , iXLen %vl ) {
254
+ define <vscale x 4 x i64 > @vwadd_vx (<vscale x 4 x i32 > %a , i32 %b , iXLen %vl ) {
255
255
; NOVLOPT-LABEL: vwadd.vx:
256
256
; NOVLOPT: # %bb.0:
257
257
; NOVLOPT-NEXT: vsetvli a2, zero, e32, m2, ta, ma
@@ -272,7 +272,7 @@ define <vscale x 4 x i64> @vwadd.vx(<vscale x 4 x i32> %a, i32 %b, iXLen %vl) {
272
272
ret <vscale x 4 x i64 > %2
273
273
}
274
274
275
- define <vscale x 4 x i64 > @vwsub.vv (<vscale x 4 x i32 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
275
+ define <vscale x 4 x i64 > @vwsub_vv (<vscale x 4 x i32 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
276
276
; NOVLOPT-LABEL: vwsub.vv:
277
277
; NOVLOPT: # %bb.0:
278
278
; NOVLOPT-NEXT: vsetvli a1, zero, e32, m2, ta, ma
@@ -293,7 +293,7 @@ define <vscale x 4 x i64> @vwsub.vv(<vscale x 4 x i32> %a, <vscale x 4 x i32> %b
293
293
ret <vscale x 4 x i64 > %2
294
294
}
295
295
296
- define <vscale x 4 x i64 > @vwsub.vx (<vscale x 4 x i32 > %a , i32 %b , iXLen %vl ) {
296
+ define <vscale x 4 x i64 > @vwsub_vx (<vscale x 4 x i32 > %a , i32 %b , iXLen %vl ) {
297
297
; NOVLOPT-LABEL: vwsub.vx:
298
298
; NOVLOPT: # %bb.0:
299
299
; NOVLOPT-NEXT: vsetvli a2, zero, e32, m2, ta, ma
@@ -314,7 +314,7 @@ define <vscale x 4 x i64> @vwsub.vx(<vscale x 4 x i32> %a, i32 %b, iXLen %vl) {
314
314
ret <vscale x 4 x i64 > %2
315
315
}
316
316
317
- define <vscale x 4 x i64 > @vwaddu.wv (<vscale x 4 x i64 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
317
+ define <vscale x 4 x i64 > @vwaddu_wv (<vscale x 4 x i64 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
318
318
; NOVLOPT-LABEL: vwaddu.wv:
319
319
; NOVLOPT: # %bb.0:
320
320
; NOVLOPT-NEXT: vsetvli a1, zero, e32, m2, ta, ma
@@ -335,7 +335,7 @@ define <vscale x 4 x i64> @vwaddu.wv(<vscale x 4 x i64> %a, <vscale x 4 x i32> %
335
335
ret <vscale x 4 x i64 > %2
336
336
}
337
337
338
- define <vscale x 4 x i64 > @vwaddu.wx (<vscale x 4 x i64 > %a , i32 %b , iXLen %vl ) {
338
+ define <vscale x 4 x i64 > @vwaddu_wx (<vscale x 4 x i64 > %a , i32 %b , iXLen %vl ) {
339
339
; NOVLOPT-LABEL: vwaddu.wx:
340
340
; NOVLOPT: # %bb.0:
341
341
; NOVLOPT-NEXT: vsetvli a2, zero, e32, m2, ta, ma
@@ -356,7 +356,7 @@ define <vscale x 4 x i64> @vwaddu.wx(<vscale x 4 x i64> %a, i32 %b, iXLen %vl) {
356
356
ret <vscale x 4 x i64 > %2
357
357
}
358
358
359
- define <vscale x 4 x i64 > @vwsubu.wv (<vscale x 4 x i64 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
359
+ define <vscale x 4 x i64 > @vwsubu_wv (<vscale x 4 x i64 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
360
360
; NOVLOPT-LABEL: vwsubu.wv:
361
361
; NOVLOPT: # %bb.0:
362
362
; NOVLOPT-NEXT: vsetvli a1, zero, e32, m2, ta, ma
@@ -377,7 +377,7 @@ define <vscale x 4 x i64> @vwsubu.wv(<vscale x 4 x i64> %a, <vscale x 4 x i32> %
377
377
ret <vscale x 4 x i64 > %2
378
378
}
379
379
380
- define <vscale x 4 x i64 > @vwsubu.wx (<vscale x 4 x i64 > %a , i32 %b , iXLen %vl ) {
380
+ define <vscale x 4 x i64 > @vwsubu_wx (<vscale x 4 x i64 > %a , i32 %b , iXLen %vl ) {
381
381
; NOVLOPT-LABEL: vwsubu.wx:
382
382
; NOVLOPT: # %bb.0:
383
383
; NOVLOPT-NEXT: vsetvli a2, zero, e32, m2, ta, ma
@@ -398,7 +398,7 @@ define <vscale x 4 x i64> @vwsubu.wx(<vscale x 4 x i64> %a, i32 %b, iXLen %vl) {
398
398
ret <vscale x 4 x i64 > %2
399
399
}
400
400
401
- define <vscale x 4 x i64 > @vwadd.wv (<vscale x 4 x i64 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
401
+ define <vscale x 4 x i64 > @vwadd_wv (<vscale x 4 x i64 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
402
402
; NOVLOPT-LABEL: vwadd.wv:
403
403
; NOVLOPT: # %bb.0:
404
404
; NOVLOPT-NEXT: vsetvli a1, zero, e32, m2, ta, ma
@@ -419,7 +419,7 @@ define <vscale x 4 x i64> @vwadd.wv(<vscale x 4 x i64> %a, <vscale x 4 x i32> %b
419
419
ret <vscale x 4 x i64 > %2
420
420
}
421
421
422
- define <vscale x 4 x i64 > @vwadd.wx (<vscale x 4 x i64 > %a , i32 %b , iXLen %vl ) {
422
+ define <vscale x 4 x i64 > @vwadd_wx (<vscale x 4 x i64 > %a , i32 %b , iXLen %vl ) {
423
423
; NOVLOPT-LABEL: vwadd.wx:
424
424
; NOVLOPT: # %bb.0:
425
425
; NOVLOPT-NEXT: vsetvli a2, zero, e32, m2, ta, ma
@@ -440,7 +440,7 @@ define <vscale x 4 x i64> @vwadd.wx(<vscale x 4 x i64> %a, i32 %b, iXLen %vl) {
440
440
ret <vscale x 4 x i64 > %2
441
441
}
442
442
443
- define <vscale x 4 x i64 > @vwsub.wv (<vscale x 4 x i64 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
443
+ define <vscale x 4 x i64 > @vwsub_wv (<vscale x 4 x i64 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
444
444
; NOVLOPT-LABEL: vwsub.wv:
445
445
; NOVLOPT: # %bb.0:
446
446
; NOVLOPT-NEXT: vsetvli a1, zero, e32, m2, ta, ma
@@ -461,7 +461,7 @@ define <vscale x 4 x i64> @vwsub.wv(<vscale x 4 x i64> %a, <vscale x 4 x i32> %b
461
461
ret <vscale x 4 x i64 > %2
462
462
}
463
463
464
- define <vscale x 4 x i64 > @vwsub.wx (<vscale x 4 x i64 > %a , i32 %b , iXLen %vl ) {
464
+ define <vscale x 4 x i64 > @vwsub_wx (<vscale x 4 x i64 > %a , i32 %b , iXLen %vl ) {
465
465
; NOVLOPT-LABEL: vwsub.wx:
466
466
; NOVLOPT: # %bb.0:
467
467
; NOVLOPT-NEXT: vsetvli a2, zero, e32, m2, ta, ma
@@ -482,7 +482,7 @@ define <vscale x 4 x i64> @vwsub.wx(<vscale x 4 x i64> %a, i32 %b, iXLen %vl) {
482
482
ret <vscale x 4 x i64 > %2
483
483
}
484
484
485
- define <vscale x 4 x i32 > @vsext.vf2 (<vscale x 4 x i16 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
485
+ define <vscale x 4 x i32 > @vsext_vf2 (<vscale x 4 x i16 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
486
486
; NOVLOPT-LABEL: vsext.vf2:
487
487
; NOVLOPT: # %bb.0:
488
488
; NOVLOPT-NEXT: vsetvli a1, zero, e32, m2, ta, ma
@@ -502,7 +502,7 @@ define <vscale x 4 x i32> @vsext.vf2(<vscale x 4 x i16> %a, <vscale x 4 x i32> %
502
502
ret <vscale x 4 x i32 > %2
503
503
}
504
504
505
- define <vscale x 4 x i32 > @vsext.vf4 (<vscale x 4 x i8 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
505
+ define <vscale x 4 x i32 > @vsext_vf4 (<vscale x 4 x i8 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
506
506
; NOVLOPT-LABEL: vsext.vf4:
507
507
; NOVLOPT: # %bb.0:
508
508
; NOVLOPT-NEXT: vsetvli a1, zero, e32, m2, ta, ma
@@ -522,7 +522,7 @@ define <vscale x 4 x i32> @vsext.vf4(<vscale x 4 x i8> %a, <vscale x 4 x i32> %b
522
522
ret <vscale x 4 x i32 > %2
523
523
}
524
524
525
- define <vscale x 4 x i64 > @vsext.vf8 (<vscale x 4 x i8 > %a , <vscale x 4 x i64 > %b , iXLen %vl ) {
525
+ define <vscale x 4 x i64 > @vsext_vf8 (<vscale x 4 x i8 > %a , <vscale x 4 x i64 > %b , iXLen %vl ) {
526
526
; NOVLOPT-LABEL: vsext.vf8:
527
527
; NOVLOPT: # %bb.0:
528
528
; NOVLOPT-NEXT: vsetvli a1, zero, e64, m4, ta, ma
@@ -542,7 +542,7 @@ define <vscale x 4 x i64> @vsext.vf8(<vscale x 4 x i8> %a, <vscale x 4 x i64> %b
542
542
ret <vscale x 4 x i64 > %2
543
543
}
544
544
545
- define <vscale x 4 x i32 > @vzext.vf2 (<vscale x 4 x i16 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
545
+ define <vscale x 4 x i32 > @vzext_vf2 (<vscale x 4 x i16 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
546
546
; NOVLOPT-LABEL: vzext.vf2:
547
547
; NOVLOPT: # %bb.0:
548
548
; NOVLOPT-NEXT: vsetvli a1, zero, e32, m2, ta, ma
@@ -562,7 +562,7 @@ define <vscale x 4 x i32> @vzext.vf2(<vscale x 4 x i16> %a, <vscale x 4 x i32> %
562
562
ret <vscale x 4 x i32 > %2
563
563
}
564
564
565
- define <vscale x 4 x i32 > @vzext.vf4 (<vscale x 4 x i8 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
565
+ define <vscale x 4 x i32 > @vzext_vf4 (<vscale x 4 x i8 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
566
566
; NOVLOPT-LABEL: vzext.vf4:
567
567
; NOVLOPT: # %bb.0:
568
568
; NOVLOPT-NEXT: vsetvli a1, zero, e32, m2, ta, ma
@@ -582,7 +582,7 @@ define <vscale x 4 x i32> @vzext.vf4(<vscale x 4 x i8> %a, <vscale x 4 x i32> %b
582
582
ret <vscale x 4 x i32 > %2
583
583
}
584
584
585
- define <vscale x 4 x i64 > @vzext.vf8 (<vscale x 4 x i8 > %a , <vscale x 4 x i64 > %b , iXLen %vl ) {
585
+ define <vscale x 4 x i64 > @vzext_vf8 (<vscale x 4 x i8 > %a , <vscale x 4 x i64 > %b , iXLen %vl ) {
586
586
; NOVLOPT-LABEL: vzext.vf8:
587
587
; NOVLOPT: # %bb.0:
588
588
; NOVLOPT-NEXT: vsetvli a1, zero, e64, m4, ta, ma
@@ -846,7 +846,7 @@ define <vscale x 4 x i32> @vwmaccu_vx(<vscale x 4 x i16> %a, i16 %b, iXLen %vl)
846
846
ret <vscale x 4 x i32 > %2
847
847
}
848
848
849
- define <vscale x 4 x i32 > @vmv.v.i (<vscale x 4 x i32 > %a , i32 %x , iXLen %vl ) {
849
+ define <vscale x 4 x i32 > @vmv_v_i (<vscale x 4 x i32 > %a , i32 %x , iXLen %vl ) {
850
850
; NOVLOPT-LABEL: vmv.v.i:
851
851
; NOVLOPT: # %bb.0:
852
852
; NOVLOPT-NEXT: vsetvli a0, zero, e32, m2, ta, ma
@@ -866,7 +866,7 @@ define <vscale x 4 x i32> @vmv.v.i(<vscale x 4 x i32> %a, i32 %x, iXLen %vl) {
866
866
ret <vscale x 4 x i32 > %2
867
867
}
868
868
869
- define <vscale x 4 x i32 > @vmv.v.x (<vscale x 4 x i32 > %a , i32 %x , iXLen %vl ) {
869
+ define <vscale x 4 x i32 > @vmv_v_x (<vscale x 4 x i32 > %a , i32 %x , iXLen %vl ) {
870
870
; NOVLOPT-LABEL: vmv.v.x:
871
871
; NOVLOPT: # %bb.0:
872
872
; NOVLOPT-NEXT: vsetvli a2, zero, e32, m2, ta, ma
@@ -886,7 +886,7 @@ define <vscale x 4 x i32> @vmv.v.x(<vscale x 4 x i32> %a, i32 %x, iXLen %vl) {
886
886
ret <vscale x 4 x i32 > %2
887
887
}
888
888
889
- define <vscale x 4 x i32 > @vwsll.vi (<vscale x 4 x i16 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
889
+ define <vscale x 4 x i32 > @vwsll_vi (<vscale x 4 x i16 > %a , <vscale x 4 x i32 > %b , iXLen %vl ) {
890
890
; NOVLOPT-LABEL: vwsll.vi:
891
891
; NOVLOPT: # %bb.0:
892
892
; NOVLOPT-NEXT: vsetvli a1, zero, e16, m1, ta, ma
0 commit comments