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/shuffle-reverse.ll
+12Lines changed: 12 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -9,6 +9,10 @@
9
9
definevoid@reverse() {
10
10
;
11
11
; CHECK-LABEL: 'reverse'
12
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %v2i1 = shufflevector <2 x i1> undef, <2 x i1> undef, <2 x i32> <i32 1, i32 0>
13
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %v4i1 = shufflevector <4 x i1> undef, <4 x i1> undef, <4 x i32> <i32 3, i32 2, i32 1, i32 0>
14
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %v8i1 = shufflevector <8 x i1> undef, <8 x i1> undef, <8 x i32> <i32 7, i32 6, i32 5, i32 4, i32 3, i32 2, i32 1, i32 0>
15
+
; CHECK-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %v16i1 = shufflevector <16 x i1> undef, <16 x i1> undef, <16 x i32> <i32 15, i32 14, i32 13, i32 12, i32 11, i32 10, i32 9, i32 8, i32 7, i32 6, i32 5, i32 4, i32 3, i32 2, i32 1, i32 0>
12
16
; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %v2i8 = shufflevector <2 x i8> undef, <2 x i8> undef, <2 x i32> <i32 1, i32 0>
13
17
; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %v4i8 = shufflevector <4 x i8> undef, <4 x i8> undef, <4 x i32> <i32 3, i32 2, i32 1, i32 0>
14
18
; CHECK-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %v8i8 = shufflevector <8 x i8> undef, <8 x i8> undef, <8 x i32> <i32 7, i32 6, i32 5, i32 4, i32 3, i32 2, i32 1, i32 0>
@@ -34,6 +38,10 @@ define void @reverse() {
34
38
; CHECK-NEXT: Cost Model: Found an estimated cost of 0 for instruction: ret void
35
39
;
36
40
; SIZE-LABEL: 'reverse'
41
+
; SIZE-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %v2i1 = shufflevector <2 x i1> undef, <2 x i1> undef, <2 x i32> <i32 1, i32 0>
42
+
; SIZE-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %v4i1 = shufflevector <4 x i1> undef, <4 x i1> undef, <4 x i32> <i32 3, i32 2, i32 1, i32 0>
43
+
; SIZE-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %v8i1 = shufflevector <8 x i1> undef, <8 x i1> undef, <8 x i32> <i32 7, i32 6, i32 5, i32 4, i32 3, i32 2, i32 1, i32 0>
44
+
; SIZE-NEXT: Cost Model: Found an estimated cost of 6 for instruction: %v16i1 = shufflevector <16 x i1> undef, <16 x i1> undef, <16 x i32> <i32 15, i32 14, i32 13, i32 12, i32 11, i32 10, i32 9, i32 8, i32 7, i32 6, i32 5, i32 4, i32 3, i32 2, i32 1, i32 0>
37
45
; SIZE-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %v2i8 = shufflevector <2 x i8> undef, <2 x i8> undef, <2 x i32> <i32 1, i32 0>
38
46
; SIZE-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %v4i8 = shufflevector <4 x i8> undef, <4 x i8> undef, <4 x i32> <i32 3, i32 2, i32 1, i32 0>
39
47
; SIZE-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %v8i8 = shufflevector <8 x i8> undef, <8 x i8> undef, <8 x i32> <i32 7, i32 6, i32 5, i32 4, i32 3, i32 2, i32 1, i32 0>
@@ -58,6 +66,10 @@ define void @reverse() {
58
66
; SIZE-NEXT: Cost Model: Found an estimated cost of 3 for instruction: %v4f64 = shufflevector <4 x double> undef, <4 x double> undef, <4 x i32> <i32 3, i32 2, i32 1, i32 0>
59
67
; SIZE-NEXT: Cost Model: Found an estimated cost of 1 for instruction: ret void
60
68
;
69
+
%v2i1 = shufflevector <2 x i1> undef, <2 x i1> undef, <2 x i32> <i321, i320>
70
+
%v4i1 = shufflevector <4 x i1> undef, <4 x i1> undef, <4 x i32> <i323, i322, i321, i320>
71
+
%v8i1 = shufflevector <8 x i1> undef, <8 x i1> undef, <8 x i32> <i327, i326, i325, i324, i323, i322, i321, i320>
72
+
%v16i1 = shufflevector <16 x i1> undef, <16 x i1> undef, <16 x i32> <i3215, i3214, i3213, i3212, i3211, i3210, i329, i328, i327, i326, i325, i324, i323, i322, i321, i320>
61
73
%v2i8 = shufflevector <2 x i8> undef, <2 x i8> undef, <2 x i32> <i321, i320>
62
74
%v4i8 = shufflevector <4 x i8> undef, <4 x i8> undef, <4 x i32> <i323, i322, i321, i320>
63
75
%v8i8 = shufflevector <8 x i8> undef, <8 x i8> undef, <8 x i32> <i327, i326, i325, i324, i323, i322, i321, i320>
0 commit comments