You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: llvm/test/Analysis/CostModel/RISCV/rvv-intrinsics.ll
+114Lines changed: 114 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -490,6 +490,86 @@ define void @store() {
490
490
retvoid
491
491
}
492
492
493
+
definevoid@strided_load() {
494
+
; CHECK-LABEL: 'strided_load'
495
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 5 for instruction: %t0 = call <2 x i8> @llvm.experimental.vp.strided.load.v2i8.p0.i64(ptr undef, i64 undef, <2 x i1> undef, i32 undef)
496
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 11 for instruction: %t2 = call <4 x i8> @llvm.experimental.vp.strided.load.v4i8.p0.i64(ptr undef, i64 undef, <4 x i1> undef, i32 undef)
497
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 23 for instruction: %t4 = call <8 x i8> @llvm.experimental.vp.strided.load.v8i8.p0.i64(ptr undef, i64 undef, <8 x i1> undef, i32 undef)
498
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 47 for instruction: %t6 = call <16 x i8> @llvm.experimental.vp.strided.load.v16i8.p0.i64(ptr undef, i64 undef, <16 x i1> undef, i32 undef)
499
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 5 for instruction: %t8 = call <2 x i64> @llvm.experimental.vp.strided.load.v2i64.p0.i64(ptr undef, i64 undef, <2 x i1> undef, i32 undef)
500
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 11 for instruction: %t10 = call <4 x i64> @llvm.experimental.vp.strided.load.v4i64.p0.i64(ptr undef, i64 undef, <4 x i1> undef, i32 undef)
501
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 23 for instruction: %t13 = call <8 x i64> @llvm.experimental.vp.strided.load.v8i64.p0.i64(ptr undef, i64 undef, <8 x i1> undef, i32 undef)
502
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 47 for instruction: %t15 = call <16 x i64> @llvm.experimental.vp.strided.load.v16i64.p0.i64(ptr undef, i64 undef, <16 x i1> undef, i32 undef)
503
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: %t17 = call <vscale x 2 x i8> @llvm.experimental.vp.strided.load.nxv2i8.p0.i64(ptr undef, i64 undef, <vscale x 2 x i1> undef, i32 undef)
504
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: %t19 = call <vscale x 4 x i8> @llvm.experimental.vp.strided.load.nxv4i8.p0.i64(ptr undef, i64 undef, <vscale x 4 x i1> undef, i32 undef)
505
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: %t21 = call <vscale x 8 x i8> @llvm.experimental.vp.strided.load.nxv8i8.p0.i64(ptr undef, i64 undef, <vscale x 8 x i1> undef, i32 undef)
506
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: %t23 = call <vscale x 16 x i8> @llvm.experimental.vp.strided.load.nxv16i8.p0.i64(ptr undef, i64 undef, <vscale x 16 x i1> undef, i32 undef)
507
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: %t25 = call <vscale x 2 x i64> @llvm.experimental.vp.strided.load.nxv2i64.p0.i64(ptr undef, i64 undef, <vscale x 2 x i1> undef, i32 undef)
508
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: %t27 = call <vscale x 4 x i64> @llvm.experimental.vp.strided.load.nxv4i64.p0.i64(ptr undef, i64 undef, <vscale x 4 x i1> undef, i32 undef)
509
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: %t29 = call <vscale x 8 x i64> @llvm.experimental.vp.strided.load.nxv8i64.p0.i64(ptr undef, i64 undef, <vscale x 8 x i1> undef, i32 undef)
510
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: %t31 = call <vscale x 16 x i64> @llvm.experimental.vp.strided.load.nxv16i64.p0.i64(ptr undef, i64 undef, <vscale x 16 x i1> undef, i32 undef)
511
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 0 for instruction: ret void
512
+
;
513
+
%t0 = call <2 x i8> @llvm.experimental.vp.strided.load.v2i8.i64(ptrundef, i64undef, <2 x i1> undef, i32undef)
514
+
%t2 = call <4 x i8> @llvm.experimental.vp.strided.load.v4i8.i64(ptrundef, i64undef, <4 x i1> undef, i32undef)
515
+
%t4 = call <8 x i8> @llvm.experimental.vp.strided.load.v8i8.i64(ptrundef, i64undef, <8 x i1> undef, i32undef)
516
+
%t6 = call <16 x i8> @llvm.experimental.vp.strided.load.v16i8.i64(ptrundef, i64undef, <16 x i1> undef, i32undef)
517
+
%t8 = call <2 x i64> @llvm.experimental.vp.strided.load.v2i64.i64(ptrundef, i64undef, <2 x i1> undef, i32undef)
518
+
%t10 = call <4 x i64> @llvm.experimental.vp.strided.load.v4i64.i64(ptrundef, i64undef, <4 x i1> undef, i32undef)
519
+
%t13 = call <8 x i64> @llvm.experimental.vp.strided.load.v8i64.i64(ptrundef, i64undef, <8 x i1> undef, i32undef)
520
+
%t15 = call <16 x i64> @llvm.experimental.vp.strided.load.v16i64.i64(ptrundef, i64undef, <16 x i1> undef, i32undef)
521
+
%t17 = call <vscale x 2 x i8> @llvm.experimental.vp.strided.load.nxv2i8.i64(ptrundef, i64undef, <vscale x 2 x i1> undef, i32undef)
522
+
%t19 = call <vscale x 4 x i8> @llvm.experimental.vp.strided.load.nxv4i8.i64(ptrundef, i64undef, <vscale x 4 x i1> undef, i32undef)
523
+
%t21 = call <vscale x 8 x i8> @llvm.experimental.vp.strided.load.nxv8i8.i64(ptrundef, i64undef, <vscale x 8 x i1> undef, i32undef)
524
+
%t23 = call <vscale x 16 x i8> @llvm.experimental.vp.strided.load.nxv16i8.i64(ptrundef, i64undef, <vscale x 16 x i1> undef, i32undef)
525
+
%t25 = call <vscale x 2 x i64> @llvm.experimental.vp.strided.load.nxv2i64.i64(ptrundef, i64undef, <vscale x 2 x i1> undef, i32undef)
526
+
%t27 = call <vscale x 4 x i64> @llvm.experimental.vp.strided.load.nxv4i64.i64(ptrundef, i64undef, <vscale x 4 x i1> undef, i32undef)
527
+
%t29 = call <vscale x 8 x i64> @llvm.experimental.vp.strided.load.nxv8i64.i64(ptrundef, i64undef, <vscale x 8 x i1> undef, i32undef)
528
+
%t31 = call <vscale x 16 x i64> @llvm.experimental.vp.strided.load.nxv16i64.i64(ptrundef, i64undef, <vscale x 16 x i1> undef, i32undef)
529
+
retvoid
530
+
}
531
+
532
+
definevoid@strided_store() {
533
+
; CHECK-LABEL: 'strided_store'
534
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 12 for instruction: call void @llvm.experimental.vp.strided.store.v2i8.p0.i64(<2 x i8> undef, ptr undef, i64 undef, <2 x i1> undef, i32 undef)
535
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 26 for instruction: call void @llvm.experimental.vp.strided.store.v4i8.p0.i64(<4 x i8> undef, ptr undef, i64 undef, <4 x i1> undef, i32 undef)
536
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 54 for instruction: call void @llvm.experimental.vp.strided.store.v8i8.p0.i64(<8 x i8> undef, ptr undef, i64 undef, <8 x i1> undef, i32 undef)
537
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 110 for instruction: call void @llvm.experimental.vp.strided.store.v16i8.p0.i64(<16 x i8> undef, ptr undef, i64 undef, <16 x i1> undef, i32 undef)
538
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 12 for instruction: call void @llvm.experimental.vp.strided.store.v2i64.p0.i64(<2 x i64> undef, ptr undef, i64 undef, <2 x i1> undef, i32 undef)
539
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 26 for instruction: call void @llvm.experimental.vp.strided.store.v4i64.p0.i64(<4 x i64> undef, ptr undef, i64 undef, <4 x i1> undef, i32 undef)
540
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 54 for instruction: call void @llvm.experimental.vp.strided.store.v8i64.p0.i64(<8 x i64> undef, ptr undef, i64 undef, <8 x i1> undef, i32 undef)
541
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 110 for instruction: call void @llvm.experimental.vp.strided.store.v16i64.p0.i64(<16 x i64> undef, ptr undef, i64 undef, <16 x i1> undef, i32 undef)
542
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: call void @llvm.experimental.vp.strided.store.nxv2i8.p0.i64(<vscale x 2 x i8> undef, ptr undef, i64 undef, <vscale x 2 x i1> undef, i32 undef)
543
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: call void @llvm.experimental.vp.strided.store.nxv4i8.p0.i64(<vscale x 4 x i8> undef, ptr undef, i64 undef, <vscale x 4 x i1> undef, i32 undef)
544
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: call void @llvm.experimental.vp.strided.store.nxv8i8.p0.i64(<vscale x 8 x i8> undef, ptr undef, i64 undef, <vscale x 8 x i1> undef, i32 undef)
545
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: call void @llvm.experimental.vp.strided.store.nxv16i8.p0.i64(<vscale x 16 x i8> undef, ptr undef, i64 undef, <vscale x 16 x i1> undef, i32 undef)
546
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: call void @llvm.experimental.vp.strided.store.nxv2i64.p0.i64(<vscale x 2 x i64> undef, ptr undef, i64 undef, <vscale x 2 x i1> undef, i32 undef)
547
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: call void @llvm.experimental.vp.strided.store.nxv4i64.p0.i64(<vscale x 4 x i64> undef, ptr undef, i64 undef, <vscale x 4 x i1> undef, i32 undef)
548
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: call void @llvm.experimental.vp.strided.store.nxv8i64.p0.i64(<vscale x 8 x i64> undef, ptr undef, i64 undef, <vscale x 8 x i1> undef, i32 undef)
549
+
; CHECK-NEXT: Cost Model: Invalid cost for instruction: call void @llvm.experimental.vp.strided.store.nxv16i64.p0.i64(<vscale x 16 x i64> undef, ptr undef, i64 undef, <vscale x 16 x i1> undef, i32 undef)
550
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 0 for instruction: ret void
551
+
;
552
+
callvoid@llvm.experimental.vp.strided.store.v2i8.i64(<2 x i8> undef, ptrundef, i64undef, <2 x i1> undef, i32undef)
553
+
callvoid@llvm.experimental.vp.strided.store.v4i8.i64(<4 x i8> undef, ptrundef, i64undef, <4 x i1> undef, i32undef)
554
+
callvoid@llvm.experimental.vp.strided.store.v8i8.i64(<8 x i8> undef, ptrundef, i64undef, <8 x i1> undef, i32undef)
555
+
callvoid@llvm.experimental.vp.strided.store.v16i8.i64(<16 x i8> undef, ptrundef, i64undef, <16 x i1> undef, i32undef)
556
+
callvoid@llvm.experimental.vp.strided.store.v2i64.i64(<2 x i64> undef, ptrundef, i64undef, <2 x i1> undef, i32undef)
557
+
callvoid@llvm.experimental.vp.strided.store.v4i64.i64(<4 x i64> undef, ptrundef, i64undef, <4 x i1> undef, i32undef)
558
+
callvoid@llvm.experimental.vp.strided.store.v8i64.i64(<8 x i64> undef, ptrundef, i64undef, <8 x i1> undef, i32undef)
559
+
callvoid@llvm.experimental.vp.strided.store.v16i64.i64(<16 x i64> undef, ptrundef, i64undef, <16 x i1> undef, i32undef)
560
+
callvoid@llvm.experimental.vp.strided.store.nxv2i8.i64(<vscale x 2 x i8> undef, ptrundef, i64undef, <vscale x 2 x i1> undef, i32undef)
561
+
callvoid@llvm.experimental.vp.strided.store.nxv4i8.i64(<vscale x 4 x i8> undef, ptrundef, i64undef, <vscale x 4 x i1> undef, i32undef)
562
+
callvoid@llvm.experimental.vp.strided.store.nxv8i8.i64(<vscale x 8 x i8> undef, ptrundef, i64undef, <vscale x 8 x i1> undef, i32undef)
563
+
callvoid@llvm.experimental.vp.strided.store.nxv16i8.i64(<vscale x 16 x i8> undef, ptrundef, i64undef, <vscale x 16 x i1> undef, i32undef)
564
+
callvoid@llvm.experimental.vp.strided.store.nxv2i64.i64(<vscale x 2 x i64> undef, ptrundef, i64undef, <vscale x 2 x i1> undef, i32undef)
565
+
callvoid@llvm.experimental.vp.strided.store.nxv4i64.i64(<vscale x 4 x i64> undef, ptrundef, i64undef, <vscale x 4 x i1> undef, i32undef)
566
+
callvoid@llvm.experimental.vp.strided.store.nxv8i64.i64(<vscale x 8 x i64> undef, ptrundef, i64undef, <vscale x 8 x i1> undef, i32undef)
567
+
callvoid@llvm.experimental.vp.strided.store.nxv16i64.i64(<vscale x 16 x i64> undef, ptrundef, i64undef, <vscale x 16 x i1> undef, i32undef)
568
+
retvoid
569
+
}
570
+
571
+
572
+
493
573
definevoid@reduce_add() {
494
574
; CHECK-LABEL: 'reduce_add'
495
575
; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %1 = call i8 @llvm.vp.reduce.add.v2i8(i8 undef, <2 x i8> undef, <2 x i1> undef, i32 undef)
@@ -717,6 +797,40 @@ declare void @llvm.vp.store.nxv4i64(<vscale x 4 x i64>, ptr, <vscale x 4 x i1>,
717
797
declarevoid@llvm.vp.store.nxv8i64(<vscale x 8 x i64>, ptr, <vscale x 8 x i1>, i32)
718
798
declarevoid@llvm.vp.store.nxv16i64(<vscale x 16 x i64>, ptr, <vscale x 16 x i1>, i32)
719
799
800
+
declare <2 x i8> @llvm.experimental.vp.strided.load.v2i8.i64(ptr, i64, <2 x i1>, i32)
801
+
declare <4 x i8> @llvm.experimental.vp.strided.load.v4i8.i64(ptr, i64, <4 x i1>, i32)
802
+
declare <8 x i8> @llvm.experimental.vp.strided.load.v8i8.i64(ptr, i64, <8 x i1>, i32)
803
+
declare <16 x i8> @llvm.experimental.vp.strided.load.v16i8.i64(ptr, i64, <16 x i1>, i32)
804
+
declare <2 x i64> @llvm.experimental.vp.strided.load.v2i64.i64(ptr, i64, <2 x i1>, i32)
805
+
declare <4 x i64> @llvm.experimental.vp.strided.load.v4i64.i64(ptr, i64, <4 x i1>, i32)
806
+
declare <8 x i64> @llvm.experimental.vp.strided.load.v8i64.i64(ptr, i64, <8 x i1>, i32)
807
+
declare <16 x i64> @llvm.experimental.vp.strided.load.v16i64.i64(ptr, i64, <16 x i1>, i32)
808
+
declare <vscale x 2 x i8> @llvm.experimental.vp.strided.load.nxv2i8.i64(ptr, i64, <vscale x 2 x i1>, i32)
809
+
declare <vscale x 4 x i8> @llvm.experimental.vp.strided.load.nxv4i8.i64(ptr, i64, <vscale x 4 x i1>, i32)
810
+
declare <vscale x 8 x i8> @llvm.experimental.vp.strided.load.nxv8i8.i64(ptr, i64, <vscale x 8 x i1>, i32)
811
+
declare <vscale x 16 x i8> @llvm.experimental.vp.strided.load.nxv16i8.i64(ptr, i64, <vscale x 16 x i1>, i32)
812
+
declare <vscale x 2 x i64> @llvm.experimental.vp.strided.load.nxv2i64.i64(ptr, i64, <vscale x 2 x i1>, i32)
813
+
declare <vscale x 4 x i64> @llvm.experimental.vp.strided.load.nxv4i64.i64(ptr, i64, <vscale x 4 x i1>, i32)
814
+
declare <vscale x 8 x i64> @llvm.experimental.vp.strided.load.nxv8i64.i64(ptr, i64, <vscale x 8 x i1>, i32)
815
+
declare <vscale x 16 x i64> @llvm.experimental.vp.strided.load.nxv16i64.i64(ptr, i64, <vscale x 16 x i1>, i32)
816
+
817
+
declarevoid@llvm.experimental.vp.strided.store.v2i8.i64(<2 x i8>, ptr, i64, <2 x i1>, i32)
818
+
declarevoid@llvm.experimental.vp.strided.store.v4i8.i64(<4 x i8>, ptr, i64, <4 x i1>, i32)
819
+
declarevoid@llvm.experimental.vp.strided.store.v8i8.i64(<8 x i8>, ptr, i64, <8 x i1>, i32)
820
+
declarevoid@llvm.experimental.vp.strided.store.v16i8.i64(<16 x i8>, ptr, i64, <16 x i1>, i32)
821
+
declarevoid@llvm.experimental.vp.strided.store.v2i64.i64(<2 x i64>, ptr, i64, <2 x i1>, i32)
822
+
declarevoid@llvm.experimental.vp.strided.store.v4i64.i64(<4 x i64>, ptr, i64, <4 x i1>, i32)
823
+
declarevoid@llvm.experimental.vp.strided.store.v8i64.i64(<8 x i64>, ptr, i64, <8 x i1>, i32)
824
+
declarevoid@llvm.experimental.vp.strided.store.v16i64.i64(<16 x i64>, ptr, i64, <16 x i1>, i32)
825
+
declarevoid@llvm.experimental.vp.strided.store.nxv2i8.i64(<vscale x 2 x i8>, ptr, i64, <vscale x 2 x i1>, i32)
826
+
declarevoid@llvm.experimental.vp.strided.store.nxv4i8.i64(<vscale x 4 x i8>, ptr, i64, <vscale x 4 x i1>, i32)
827
+
declarevoid@llvm.experimental.vp.strided.store.nxv8i8.i64(<vscale x 8 x i8>, ptr, i64, <vscale x 8 x i1>, i32)
828
+
declarevoid@llvm.experimental.vp.strided.store.nxv16i8.i64(<vscale x 16 x i8>, ptr, i64, <vscale x 16 x i1>, i32)
829
+
declarevoid@llvm.experimental.vp.strided.store.nxv2i64.i64(<vscale x 2 x i64>, ptr, i64, <vscale x 2 x i1>, i32)
830
+
declarevoid@llvm.experimental.vp.strided.store.nxv4i64.i64(<vscale x 4 x i64>, ptr, i64, <vscale x 4 x i1>, i32)
831
+
declarevoid@llvm.experimental.vp.strided.store.nxv8i64.i64(<vscale x 8 x i64>, ptr, i64, <vscale x 8 x i1>, i32)
832
+
declarevoid@llvm.experimental.vp.strided.store.nxv16i64.i64(<vscale x 16 x i64>, ptr, i64, <vscale x 16 x i1>, i32)
0 commit comments