xref: /llvm-project/llvm/test/Analysis/CostModel/RISCV/rvv-load-store.ll (revision 38fffa630ee80163dc65e759392ad29798905679)
1; NOTE: Assertions have been autogenerated by utils/update_analyze_test_checks.py
2; RUN: opt -passes="print<cost-model>" 2>&1 -disable-output -mtriple=riscv64 -mattr=+v,+f,+d,+zfh,+zvfh < %s | FileCheck %s
3; RUN: opt -passes="print<cost-model>" -cost-kind=code-size 2>&1 -disable-output -mtriple=riscv64 -mattr=+v,+f,+d,+zfh,+zvfh < %s | FileCheck %s --check-prefixes=CODESIZE
4; Check that we don't crash querying costs when vectors are not enabled.
5; RUN: opt -passes="print<cost-model>" 2>&1 -disable-output -mtriple=riscv64
6
7define void @load(ptr %p) {
8; CHECK-LABEL: 'load'
9; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %1 = load i1, ptr %p, align 1
10; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %2 = load <1 x i1>, ptr %p, align 1
11; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %3 = load <2 x i1>, ptr %p, align 1
12; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %4 = load <4 x i1>, ptr %p, align 1
13; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %5 = load <8 x i1>, ptr %p, align 1
14; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %6 = load <16 x i1>, ptr %p, align 2
15; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %7 = load <32 x i1>, ptr %p, align 4
16; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %8 = load <vscale x 1 x i1>, ptr %p, align 1
17; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %9 = load <vscale x 2 x i1>, ptr %p, align 1
18; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %10 = load <vscale x 4 x i1>, ptr %p, align 1
19; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %11 = load <vscale x 8 x i1>, ptr %p, align 1
20; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %12 = load <vscale x 16 x i1>, ptr %p, align 2
21; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %13 = load <vscale x 32 x i1>, ptr %p, align 4
22; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %14 = load i8, ptr %p, align 1
23; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %15 = load <1 x i8>, ptr %p, align 1
24; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %16 = load <2 x i8>, ptr %p, align 2
25; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %17 = load <4 x i8>, ptr %p, align 4
26; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %18 = load <8 x i8>, ptr %p, align 8
27; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %19 = load <16 x i8>, ptr %p, align 16
28; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %20 = load <32 x i8>, ptr %p, align 32
29; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %21 = load <vscale x 1 x i8>, ptr %p, align 1
30; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %22 = load <vscale x 2 x i8>, ptr %p, align 2
31; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %23 = load <vscale x 4 x i8>, ptr %p, align 4
32; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %24 = load <vscale x 8 x i8>, ptr %p, align 8
33; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %25 = load <vscale x 16 x i8>, ptr %p, align 16
34; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %26 = load <vscale x 32 x i8>, ptr %p, align 32
35; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %27 = load i16, ptr %p, align 2
36; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %28 = load <1 x i16>, ptr %p, align 2
37; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %29 = load <2 x i16>, ptr %p, align 4
38; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %30 = load <4 x i16>, ptr %p, align 8
39; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %31 = load <8 x i16>, ptr %p, align 16
40; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %32 = load <16 x i16>, ptr %p, align 32
41; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %33 = load <32 x i16>, ptr %p, align 64
42; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %34 = load <vscale x 1 x i16>, ptr %p, align 2
43; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %35 = load <vscale x 2 x i16>, ptr %p, align 4
44; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %36 = load <vscale x 4 x i16>, ptr %p, align 8
45; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %37 = load <vscale x 8 x i16>, ptr %p, align 16
46; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %38 = load <vscale x 16 x i16>, ptr %p, align 32
47; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %39 = load <vscale x 32 x i16>, ptr %p, align 64
48; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %40 = load i32, ptr %p, align 4
49; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %41 = load <1 x i32>, ptr %p, align 4
50; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %42 = load <2 x i32>, ptr %p, align 8
51; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %43 = load <4 x i32>, ptr %p, align 16
52; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %44 = load <8 x i32>, ptr %p, align 32
53; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %45 = load <16 x i32>, ptr %p, align 64
54; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %46 = load <32 x i32>, ptr %p, align 128
55; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %47 = load <vscale x 1 x i32>, ptr %p, align 4
56; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %48 = load <vscale x 2 x i32>, ptr %p, align 8
57; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %49 = load <vscale x 4 x i32>, ptr %p, align 16
58; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %50 = load <vscale x 8 x i32>, ptr %p, align 32
59; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %51 = load <vscale x 16 x i32>, ptr %p, align 64
60; CHECK-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %52 = load <vscale x 32 x i32>, ptr %p, align 128
61; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %53 = load i64, ptr %p, align 8
62; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %54 = load <1 x i64>, ptr %p, align 8
63; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %55 = load <2 x i64>, ptr %p, align 16
64; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %56 = load <4 x i64>, ptr %p, align 32
65; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %57 = load <8 x i64>, ptr %p, align 64
66; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %58 = load <16 x i64>, ptr %p, align 128
67; CHECK-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %59 = load <32 x i64>, ptr %p, align 256
68; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %60 = load <vscale x 1 x i64>, ptr %p, align 8
69; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %61 = load <vscale x 2 x i64>, ptr %p, align 16
70; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %62 = load <vscale x 4 x i64>, ptr %p, align 32
71; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %63 = load <vscale x 8 x i64>, ptr %p, align 64
72; CHECK-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %64 = load <vscale x 16 x i64>, ptr %p, align 128
73; CHECK-NEXT:  Cost Model: Found an estimated cost of 32 for instruction: %65 = load <vscale x 32 x i64>, ptr %p, align 256
74; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %66 = load ptr, ptr %p, align 8
75; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %67 = load <1 x ptr>, ptr %p, align 8
76; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %68 = load <2 x ptr>, ptr %p, align 16
77; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %69 = load <4 x ptr>, ptr %p, align 32
78; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %70 = load <8 x ptr>, ptr %p, align 64
79; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %71 = load <16 x ptr>, ptr %p, align 128
80; CHECK-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %72 = load <32 x ptr>, ptr %p, align 256
81; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %73 = load <vscale x 1 x ptr>, ptr %p, align 8
82; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %74 = load <vscale x 2 x ptr>, ptr %p, align 16
83; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %75 = load <vscale x 4 x ptr>, ptr %p, align 32
84; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %76 = load <vscale x 8 x ptr>, ptr %p, align 64
85; CHECK-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: %77 = load <vscale x 16 x ptr>, ptr %p, align 128
86; CHECK-NEXT:  Cost Model: Found an estimated cost of 32 for instruction: %78 = load <vscale x 32 x ptr>, ptr %p, align 256
87; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret void
88;
89; CODESIZE-LABEL: 'load'
90; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %1 = load i1, ptr %p, align 1
91; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %2 = load <1 x i1>, ptr %p, align 1
92; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %3 = load <2 x i1>, ptr %p, align 1
93; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %4 = load <4 x i1>, ptr %p, align 1
94; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %5 = load <8 x i1>, ptr %p, align 1
95; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %6 = load <16 x i1>, ptr %p, align 2
96; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %7 = load <32 x i1>, ptr %p, align 4
97; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %8 = load <vscale x 1 x i1>, ptr %p, align 1
98; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %9 = load <vscale x 2 x i1>, ptr %p, align 1
99; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %10 = load <vscale x 4 x i1>, ptr %p, align 1
100; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %11 = load <vscale x 8 x i1>, ptr %p, align 1
101; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %12 = load <vscale x 16 x i1>, ptr %p, align 2
102; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %13 = load <vscale x 32 x i1>, ptr %p, align 4
103; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %14 = load i8, ptr %p, align 1
104; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %15 = load <1 x i8>, ptr %p, align 1
105; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %16 = load <2 x i8>, ptr %p, align 2
106; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %17 = load <4 x i8>, ptr %p, align 4
107; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %18 = load <8 x i8>, ptr %p, align 8
108; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %19 = load <16 x i8>, ptr %p, align 16
109; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %20 = load <32 x i8>, ptr %p, align 32
110; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %21 = load <vscale x 1 x i8>, ptr %p, align 1
111; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %22 = load <vscale x 2 x i8>, ptr %p, align 2
112; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %23 = load <vscale x 4 x i8>, ptr %p, align 4
113; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %24 = load <vscale x 8 x i8>, ptr %p, align 8
114; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %25 = load <vscale x 16 x i8>, ptr %p, align 16
115; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %26 = load <vscale x 32 x i8>, ptr %p, align 32
116; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %27 = load i16, ptr %p, align 2
117; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %28 = load <1 x i16>, ptr %p, align 2
118; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %29 = load <2 x i16>, ptr %p, align 4
119; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %30 = load <4 x i16>, ptr %p, align 8
120; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %31 = load <8 x i16>, ptr %p, align 16
121; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %32 = load <16 x i16>, ptr %p, align 32
122; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %33 = load <32 x i16>, ptr %p, align 64
123; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %34 = load <vscale x 1 x i16>, ptr %p, align 2
124; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %35 = load <vscale x 2 x i16>, ptr %p, align 4
125; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %36 = load <vscale x 4 x i16>, ptr %p, align 8
126; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %37 = load <vscale x 8 x i16>, ptr %p, align 16
127; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %38 = load <vscale x 16 x i16>, ptr %p, align 32
128; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %39 = load <vscale x 32 x i16>, ptr %p, align 64
129; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %40 = load i32, ptr %p, align 4
130; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %41 = load <1 x i32>, ptr %p, align 4
131; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %42 = load <2 x i32>, ptr %p, align 8
132; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %43 = load <4 x i32>, ptr %p, align 16
133; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %44 = load <8 x i32>, ptr %p, align 32
134; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %45 = load <16 x i32>, ptr %p, align 64
135; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %46 = load <32 x i32>, ptr %p, align 128
136; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %47 = load <vscale x 1 x i32>, ptr %p, align 4
137; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %48 = load <vscale x 2 x i32>, ptr %p, align 8
138; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %49 = load <vscale x 4 x i32>, ptr %p, align 16
139; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %50 = load <vscale x 8 x i32>, ptr %p, align 32
140; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %51 = load <vscale x 16 x i32>, ptr %p, align 64
141; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %52 = load <vscale x 32 x i32>, ptr %p, align 128
142; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %53 = load i64, ptr %p, align 8
143; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %54 = load <1 x i64>, ptr %p, align 8
144; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %55 = load <2 x i64>, ptr %p, align 16
145; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %56 = load <4 x i64>, ptr %p, align 32
146; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %57 = load <8 x i64>, ptr %p, align 64
147; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %58 = load <16 x i64>, ptr %p, align 128
148; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %59 = load <32 x i64>, ptr %p, align 256
149; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %60 = load <vscale x 1 x i64>, ptr %p, align 8
150; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %61 = load <vscale x 2 x i64>, ptr %p, align 16
151; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %62 = load <vscale x 4 x i64>, ptr %p, align 32
152; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %63 = load <vscale x 8 x i64>, ptr %p, align 64
153; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %64 = load <vscale x 16 x i64>, ptr %p, align 128
154; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %65 = load <vscale x 32 x i64>, ptr %p, align 256
155; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %66 = load ptr, ptr %p, align 8
156; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %67 = load <1 x ptr>, ptr %p, align 8
157; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %68 = load <2 x ptr>, ptr %p, align 16
158; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %69 = load <4 x ptr>, ptr %p, align 32
159; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %70 = load <8 x ptr>, ptr %p, align 64
160; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %71 = load <16 x ptr>, ptr %p, align 128
161; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %72 = load <32 x ptr>, ptr %p, align 256
162; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %73 = load <vscale x 1 x ptr>, ptr %p, align 8
163; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %74 = load <vscale x 2 x ptr>, ptr %p, align 16
164; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %75 = load <vscale x 4 x ptr>, ptr %p, align 32
165; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %76 = load <vscale x 8 x ptr>, ptr %p, align 64
166; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %77 = load <vscale x 16 x ptr>, ptr %p, align 128
167; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %78 = load <vscale x 32 x ptr>, ptr %p, align 256
168; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret void
169;
170  load i1, ptr %p
171  load <1 x i1>, ptr %p
172  load <2 x i1>, ptr %p
173  load <4 x i1>, ptr %p
174  load <8 x i1>, ptr %p
175  load <16 x i1>, ptr %p
176  load <32 x i1>, ptr %p
177  load <vscale x 1 x i1>, ptr %p
178  load <vscale x 2 x i1>, ptr %p
179  load <vscale x 4 x i1>, ptr %p
180  load <vscale x 8 x i1>, ptr %p
181  load <vscale x 16 x i1>, ptr %p
182  load <vscale x 32 x i1>, ptr %p
183
184  load i8, ptr %p
185  load <1 x i8>, ptr %p
186  load <2 x i8>, ptr %p
187  load <4 x i8>, ptr %p
188  load <8 x i8>, ptr %p
189  load <16 x i8>, ptr %p
190  load <32 x i8>, ptr %p
191  load <vscale x 1 x i8>, ptr %p
192  load <vscale x 2 x i8>, ptr %p
193  load <vscale x 4 x i8>, ptr %p
194  load <vscale x 8 x i8>, ptr %p
195  load <vscale x 16 x i8>, ptr %p
196  load <vscale x 32 x i8>, ptr %p
197
198  load i16, ptr %p
199  load <1 x i16>, ptr %p
200  load <2 x i16>, ptr %p
201  load <4 x i16>, ptr %p
202  load <8 x i16>, ptr %p
203  load <16 x i16>, ptr %p
204  load <32 x i16>, ptr %p
205  load <vscale x 1 x i16>, ptr %p
206  load <vscale x 2 x i16>, ptr %p
207  load <vscale x 4 x i16>, ptr %p
208  load <vscale x 8 x i16>, ptr %p
209  load <vscale x 16 x i16>, ptr %p
210  load <vscale x 32 x i16>, ptr %p
211
212
213  load i32, ptr %p
214  load <1 x i32>, ptr %p
215  load <2 x i32>, ptr %p
216  load <4 x i32>, ptr %p
217  load <8 x i32>, ptr %p
218  load <16 x i32>, ptr %p
219  load <32 x i32>, ptr %p
220  load <vscale x 1 x i32>, ptr %p
221  load <vscale x 2 x i32>, ptr %p
222  load <vscale x 4 x i32>, ptr %p
223  load <vscale x 8 x i32>, ptr %p
224  load <vscale x 16 x i32>, ptr %p
225  load <vscale x 32 x i32>, ptr %p
226
227  load i64, ptr %p
228  load <1 x i64>, ptr %p
229  load <2 x i64>, ptr %p
230  load <4 x i64>, ptr %p
231  load <8 x i64>, ptr %p
232  load <16 x i64>, ptr %p
233  load <32 x i64>, ptr %p
234  load <vscale x 1 x i64>, ptr %p
235  load <vscale x 2 x i64>, ptr %p
236  load <vscale x 4 x i64>, ptr %p
237  load <vscale x 8 x i64>, ptr %p
238  load <vscale x 16 x i64>, ptr %p
239  load <vscale x 32 x i64>, ptr %p
240
241  load ptr, ptr %p
242  load <1 x ptr>, ptr %p
243  load <2 x ptr>, ptr %p
244  load <4 x ptr>, ptr %p
245  load <8 x ptr>, ptr %p
246  load <16 x ptr>, ptr %p
247  load <32 x ptr>, ptr %p
248  load <vscale x 1 x ptr>, ptr %p
249  load <vscale x 2 x ptr>, ptr %p
250  load <vscale x 4 x ptr>, ptr %p
251  load <vscale x 8 x ptr>, ptr %p
252  load <vscale x 16 x ptr>, ptr %p
253  load <vscale x 32 x ptr>, ptr %p
254
255  ret void
256}
257
258define void @store(ptr %p) {
259; CHECK-LABEL: 'store'
260; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store i1 undef, ptr %p, align 1
261; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x i1> undef, ptr %p, align 1
262; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x i1> undef, ptr %p, align 1
263; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i1> undef, ptr %p, align 1
264; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <8 x i1> undef, ptr %p, align 1
265; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <16 x i1> undef, ptr %p, align 2
266; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <32 x i1> undef, ptr %p, align 4
267; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 1 x i1> undef, ptr %p, align 1
268; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 2 x i1> undef, ptr %p, align 1
269; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 4 x i1> undef, ptr %p, align 1
270; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 8 x i1> undef, ptr %p, align 1
271; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <vscale x 16 x i1> undef, ptr %p, align 2
272; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <vscale x 32 x i1> undef, ptr %p, align 4
273; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store i8 undef, ptr %p, align 1
274; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x i8> undef, ptr %p, align 1
275; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x i8> undef, ptr %p, align 2
276; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i8> undef, ptr %p, align 4
277; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <8 x i8> undef, ptr %p, align 8
278; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <16 x i8> undef, ptr %p, align 16
279; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <32 x i8> undef, ptr %p, align 32
280; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 1 x i8> undef, ptr %p, align 1
281; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 2 x i8> undef, ptr %p, align 2
282; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 4 x i8> undef, ptr %p, align 4
283; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 8 x i8> undef, ptr %p, align 8
284; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <vscale x 16 x i8> undef, ptr %p, align 16
285; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <vscale x 32 x i8> undef, ptr %p, align 32
286; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store i16 undef, ptr %p, align 2
287; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x i16> undef, ptr %p, align 2
288; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x i16> undef, ptr %p, align 4
289; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i16> undef, ptr %p, align 8
290; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <8 x i16> undef, ptr %p, align 16
291; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <16 x i16> undef, ptr %p, align 32
292; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <32 x i16> undef, ptr %p, align 64
293; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 1 x i16> undef, ptr %p, align 2
294; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 2 x i16> undef, ptr %p, align 4
295; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 4 x i16> undef, ptr %p, align 8
296; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <vscale x 8 x i16> undef, ptr %p, align 16
297; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <vscale x 16 x i16> undef, ptr %p, align 32
298; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: store <vscale x 32 x i16> undef, ptr %p, align 64
299; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store i32 undef, ptr %p, align 4
300; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x i32> undef, ptr %p, align 4
301; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x i32> undef, ptr %p, align 8
302; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i32> undef, ptr %p, align 16
303; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <8 x i32> undef, ptr %p, align 32
304; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <16 x i32> undef, ptr %p, align 64
305; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: store <32 x i32> undef, ptr %p, align 128
306; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 1 x i32> undef, ptr %p, align 4
307; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 2 x i32> undef, ptr %p, align 8
308; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <vscale x 4 x i32> undef, ptr %p, align 16
309; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <vscale x 8 x i32> undef, ptr %p, align 32
310; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: store <vscale x 16 x i32> undef, ptr %p, align 64
311; CHECK-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: store <vscale x 32 x i32> undef, ptr %p, align 128
312; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store i64 undef, ptr %p, align 8
313; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x i64> undef, ptr %p, align 8
314; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x i64> undef, ptr %p, align 16
315; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <4 x i64> undef, ptr %p, align 32
316; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <8 x i64> undef, ptr %p, align 64
317; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: store <16 x i64> undef, ptr %p, align 128
318; CHECK-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: store <32 x i64> undef, ptr %p, align 256
319; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 1 x i64> undef, ptr %p, align 8
320; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <vscale x 2 x i64> undef, ptr %p, align 16
321; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <vscale x 4 x i64> undef, ptr %p, align 32
322; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: store <vscale x 8 x i64> undef, ptr %p, align 64
323; CHECK-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: store <vscale x 16 x i64> undef, ptr %p, align 128
324; CHECK-NEXT:  Cost Model: Found an estimated cost of 32 for instruction: store <vscale x 32 x i64> undef, ptr %p, align 256
325; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store ptr undef, ptr %p, align 8
326; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x ptr> undef, ptr %p, align 8
327; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x ptr> undef, ptr %p, align 16
328; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <4 x ptr> undef, ptr %p, align 32
329; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <8 x ptr> undef, ptr %p, align 64
330; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: store <16 x ptr> undef, ptr %p, align 128
331; CHECK-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: store <32 x ptr> undef, ptr %p, align 256
332; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 1 x ptr> undef, ptr %p, align 8
333; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <vscale x 2 x ptr> undef, ptr %p, align 16
334; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <vscale x 4 x ptr> undef, ptr %p, align 32
335; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: store <vscale x 8 x ptr> undef, ptr %p, align 64
336; CHECK-NEXT:  Cost Model: Found an estimated cost of 16 for instruction: store <vscale x 16 x ptr> undef, ptr %p, align 128
337; CHECK-NEXT:  Cost Model: Found an estimated cost of 32 for instruction: store <vscale x 32 x ptr> undef, ptr %p, align 256
338; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret void
339;
340; CODESIZE-LABEL: 'store'
341; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store i1 undef, ptr %p, align 1
342; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x i1> undef, ptr %p, align 1
343; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x i1> undef, ptr %p, align 1
344; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i1> undef, ptr %p, align 1
345; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <8 x i1> undef, ptr %p, align 1
346; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <16 x i1> undef, ptr %p, align 2
347; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <32 x i1> undef, ptr %p, align 4
348; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 1 x i1> undef, ptr %p, align 1
349; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 2 x i1> undef, ptr %p, align 1
350; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 4 x i1> undef, ptr %p, align 1
351; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 8 x i1> undef, ptr %p, align 1
352; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 16 x i1> undef, ptr %p, align 2
353; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 32 x i1> undef, ptr %p, align 4
354; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store i8 undef, ptr %p, align 1
355; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x i8> undef, ptr %p, align 1
356; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x i8> undef, ptr %p, align 2
357; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i8> undef, ptr %p, align 4
358; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <8 x i8> undef, ptr %p, align 8
359; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <16 x i8> undef, ptr %p, align 16
360; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <32 x i8> undef, ptr %p, align 32
361; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 1 x i8> undef, ptr %p, align 1
362; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 2 x i8> undef, ptr %p, align 2
363; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 4 x i8> undef, ptr %p, align 4
364; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 8 x i8> undef, ptr %p, align 8
365; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 16 x i8> undef, ptr %p, align 16
366; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 32 x i8> undef, ptr %p, align 32
367; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store i16 undef, ptr %p, align 2
368; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x i16> undef, ptr %p, align 2
369; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x i16> undef, ptr %p, align 4
370; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i16> undef, ptr %p, align 8
371; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <8 x i16> undef, ptr %p, align 16
372; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <16 x i16> undef, ptr %p, align 32
373; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <32 x i16> undef, ptr %p, align 64
374; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 1 x i16> undef, ptr %p, align 2
375; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 2 x i16> undef, ptr %p, align 4
376; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 4 x i16> undef, ptr %p, align 8
377; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 8 x i16> undef, ptr %p, align 16
378; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 16 x i16> undef, ptr %p, align 32
379; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 32 x i16> undef, ptr %p, align 64
380; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store i32 undef, ptr %p, align 4
381; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x i32> undef, ptr %p, align 4
382; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x i32> undef, ptr %p, align 8
383; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i32> undef, ptr %p, align 16
384; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <8 x i32> undef, ptr %p, align 32
385; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <16 x i32> undef, ptr %p, align 64
386; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <32 x i32> undef, ptr %p, align 128
387; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 1 x i32> undef, ptr %p, align 4
388; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 2 x i32> undef, ptr %p, align 8
389; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 4 x i32> undef, ptr %p, align 16
390; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 8 x i32> undef, ptr %p, align 32
391; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 16 x i32> undef, ptr %p, align 64
392; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <vscale x 32 x i32> undef, ptr %p, align 128
393; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store i64 undef, ptr %p, align 8
394; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x i64> undef, ptr %p, align 8
395; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x i64> undef, ptr %p, align 16
396; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i64> undef, ptr %p, align 32
397; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <8 x i64> undef, ptr %p, align 64
398; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <16 x i64> undef, ptr %p, align 128
399; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <32 x i64> undef, ptr %p, align 256
400; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 1 x i64> undef, ptr %p, align 8
401; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 2 x i64> undef, ptr %p, align 16
402; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 4 x i64> undef, ptr %p, align 32
403; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 8 x i64> undef, ptr %p, align 64
404; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <vscale x 16 x i64> undef, ptr %p, align 128
405; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <vscale x 32 x i64> undef, ptr %p, align 256
406; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store ptr undef, ptr %p, align 8
407; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x ptr> undef, ptr %p, align 8
408; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x ptr> undef, ptr %p, align 16
409; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x ptr> undef, ptr %p, align 32
410; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <8 x ptr> undef, ptr %p, align 64
411; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <16 x ptr> undef, ptr %p, align 128
412; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <32 x ptr> undef, ptr %p, align 256
413; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 1 x ptr> undef, ptr %p, align 8
414; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 2 x ptr> undef, ptr %p, align 16
415; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 4 x ptr> undef, ptr %p, align 32
416; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <vscale x 8 x ptr> undef, ptr %p, align 64
417; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <vscale x 16 x ptr> undef, ptr %p, align 128
418; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <vscale x 32 x ptr> undef, ptr %p, align 256
419; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret void
420;
421  store i1 undef, ptr %p
422  store <1 x i1> undef, ptr %p
423  store <2 x i1> undef, ptr %p
424  store <4 x i1> undef, ptr %p
425  store <8 x i1> undef, ptr %p
426  store <16 x i1> undef, ptr %p
427  store <32 x i1> undef, ptr %p
428  store <vscale x 1 x i1> undef, ptr %p
429  store <vscale x 2 x i1> undef, ptr %p
430  store <vscale x 4 x i1> undef, ptr %p
431  store <vscale x 8 x i1> undef, ptr %p
432  store <vscale x 16 x i1> undef, ptr %p
433  store <vscale x 32 x i1> undef, ptr %p
434
435  store i8 undef, ptr %p
436  store <1 x i8> undef, ptr %p
437  store <2 x i8> undef, ptr %p
438  store <4 x i8> undef, ptr %p
439  store <8 x i8> undef, ptr %p
440  store <16 x i8> undef, ptr %p
441  store <32 x i8> undef, ptr %p
442  store <vscale x 1 x i8> undef, ptr %p
443  store <vscale x 2 x i8> undef, ptr %p
444  store <vscale x 4 x i8> undef, ptr %p
445  store <vscale x 8 x i8> undef, ptr %p
446  store <vscale x 16 x i8> undef, ptr %p
447  store <vscale x 32 x i8> undef, ptr %p
448
449  store i16 undef, ptr %p
450  store <1 x i16> undef, ptr %p
451  store <2 x i16> undef, ptr %p
452  store <4 x i16> undef, ptr %p
453  store <8 x i16> undef, ptr %p
454  store <16 x i16> undef, ptr %p
455  store <32 x i16> undef, ptr %p
456  store <vscale x 1 x i16> undef, ptr %p
457  store <vscale x 2 x i16> undef, ptr %p
458  store <vscale x 4 x i16> undef, ptr %p
459  store <vscale x 8 x i16> undef, ptr %p
460  store <vscale x 16 x i16> undef, ptr %p
461  store <vscale x 32 x i16> undef, ptr %p
462
463
464  store i32 undef, ptr %p
465  store <1 x i32> undef, ptr %p
466  store <2 x i32> undef, ptr %p
467  store <4 x i32> undef, ptr %p
468  store <8 x i32> undef, ptr %p
469  store <16 x i32> undef, ptr %p
470  store <32 x i32> undef, ptr %p
471  store <vscale x 1 x i32> undef, ptr %p
472  store <vscale x 2 x i32> undef, ptr %p
473  store <vscale x 4 x i32> undef, ptr %p
474  store <vscale x 8 x i32> undef, ptr %p
475  store <vscale x 16 x i32> undef, ptr %p
476  store <vscale x 32 x i32> undef, ptr %p
477
478  store i64 undef, ptr %p
479  store <1 x i64> undef, ptr %p
480  store <2 x i64> undef, ptr %p
481  store <4 x i64> undef, ptr %p
482  store <8 x i64> undef, ptr %p
483  store <16 x i64> undef, ptr %p
484  store <32 x i64> undef, ptr %p
485  store <vscale x 1 x i64> undef, ptr %p
486  store <vscale x 2 x i64> undef, ptr %p
487  store <vscale x 4 x i64> undef, ptr %p
488  store <vscale x 8 x i64> undef, ptr %p
489  store <vscale x 16 x i64> undef, ptr %p
490  store <vscale x 32 x i64> undef, ptr %p
491
492  store ptr undef, ptr %p
493  store <1 x ptr> undef, ptr %p
494  store <2 x ptr> undef, ptr %p
495  store <4 x ptr> undef, ptr %p
496  store <8 x ptr> undef, ptr %p
497  store <16 x ptr> undef, ptr %p
498  store <32 x ptr> undef, ptr %p
499  store <vscale x 1 x ptr> undef, ptr %p
500  store <vscale x 2 x ptr> undef, ptr %p
501  store <vscale x 4 x ptr> undef, ptr %p
502  store <vscale x 8 x ptr> undef, ptr %p
503  store <vscale x 16 x ptr> undef, ptr %p
504  store <vscale x 32 x ptr> undef, ptr %p
505
506  ret void
507}
508
509; For constants, have to account for cost of materializing the constant itself
510; This test exercises a few interesting constant patterns at VLEN=128
511define void @store_of_constant(ptr %p) {
512; CHECK-LABEL: 'store_of_constant'
513; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i32> poison, ptr %p, align 16
514; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i32> undef, ptr %p, align 16
515; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i32> zeroinitializer, ptr %p, align 16
516; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <4 x i64> zeroinitializer, ptr %p, align 32
517; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <4 x i32> splat (i32 1), ptr %p, align 16
518; CHECK-NEXT:  Cost Model: Found an estimated cost of 3 for instruction: store <4 x i64> splat (i64 1), ptr %p, align 32
519; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <4 x i32> splat (i32 4096), ptr %p, align 16
520; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 1, i32 1, i32 2, i32 1>, ptr %p, align 16
521; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 2, i32 1, i32 1, i32 1>, ptr %p, align 16
522; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 0, i32 1, i32 2, i32 3>, ptr %p, align 16
523; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 1, i32 2, i32 3, i32 4>, ptr %p, align 16
524; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 -1, i32 -2, i32 -3, i32 -4>, ptr %p, align 16
525; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 2, i32 4, i32 6, i32 8>, ptr %p, align 16
526; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 -1, i32 0, i32 2, i32 1>, ptr %p, align 16
527; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 256, i32 4096, i32 57, i32 1>, ptr %p, align 16
528; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret void
529;
530; CODESIZE-LABEL: 'store_of_constant'
531; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i32> poison, ptr %p, align 16
532; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i32> undef, ptr %p, align 16
533; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i32> zeroinitializer, ptr %p, align 16
534; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i64> zeroinitializer, ptr %p, align 32
535; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <4 x i32> splat (i32 1), ptr %p, align 16
536; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <4 x i64> splat (i64 1), ptr %p, align 32
537; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <4 x i32> splat (i32 4096), ptr %p, align 16
538; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 1, i32 1, i32 2, i32 1>, ptr %p, align 16
539; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 2, i32 1, i32 1, i32 1>, ptr %p, align 16
540; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 0, i32 1, i32 2, i32 3>, ptr %p, align 16
541; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 1, i32 2, i32 3, i32 4>, ptr %p, align 16
542; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 -1, i32 -2, i32 -3, i32 -4>, ptr %p, align 16
543; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 2, i32 4, i32 6, i32 8>, ptr %p, align 16
544; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 -1, i32 0, i32 2, i32 1>, ptr %p, align 16
545; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <4 x i32> <i32 256, i32 4096, i32 57, i32 1>, ptr %p, align 16
546; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret void
547;
548
549  ; poison and undef
550  store <4 x i32> poison, ptr %p
551  store <4 x i32> undef, ptr %p
552
553  ; Various splats
554  store <4 x i32> zeroinitializer, ptr %p
555  store <4 x i64> zeroinitializer, ptr %p
556  store <4 x i32> <i32 1, i32 1, i32 1, i32 1>, ptr %p
557  store <4 x i64> <i64 1, i64 1, i64 1, i64 1>, ptr %p
558  store <4 x i32> <i32 4096, i32 4096, i32 4096, i32 4096>, ptr %p
559
560  ; Nearly splats
561  store <4 x i32> <i32 1, i32 1, i32 2, i32 1>, ptr %p
562  store <4 x i32> <i32 2, i32 1, i32 1, i32 1>, ptr %p
563
564  ; Step vector functions
565  store <4 x i32> <i32 0, i32 1, i32 2, i32 3>, ptr %p
566  store <4 x i32> <i32 1, i32 2, i32 3, i32 4>, ptr %p
567  store <4 x i32> <i32 -1, i32 -2, i32 -3, i32 -4>, ptr %p
568  store <4 x i32> <i32 2, i32 4, i32 6, i32 8>, ptr %p
569
570  ; General case 128 bit constants
571  store <4 x i32> <i32 -1, i32 0, i32 2, i32 1>, ptr %p
572  store <4 x i32> <i32 256, i32 4096, i32 57, i32 1>, ptr %p
573
574  ret void
575}
576
577
578define void @load_oddsize_vectors(ptr %p) {
579; CHECK-LABEL: 'load_oddsize_vectors'
580; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %1 = load <1 x i1>, ptr %p, align 1
581; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %2 = load <2 x i1>, ptr %p, align 1
582; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %3 = load <3 x i1>, ptr %p, align 1
583; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %4 = load <4 x i1>, ptr %p, align 1
584; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %5 = load <5 x i1>, ptr %p, align 1
585; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %6 = load <6 x i1>, ptr %p, align 1
586; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %7 = load <7 x i1>, ptr %p, align 1
587; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %8 = load <8 x i1>, ptr %p, align 1
588; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %9 = load <9 x i1>, ptr %p, align 2
589; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %10 = load <15 x i1>, ptr %p, align 2
590; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %11 = load <16 x i1>, ptr %p, align 2
591; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %12 = load <31 x i1>, ptr %p, align 4
592; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %13 = load <32 x i1>, ptr %p, align 4
593; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %14 = load <1 x i32>, ptr %p, align 4
594; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %15 = load <2 x i32>, ptr %p, align 8
595; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %16 = load <3 x i32>, ptr %p, align 16
596; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %17 = load <4 x i32>, ptr %p, align 16
597; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %18 = load <5 x i32>, ptr %p, align 32
598; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %19 = load <6 x i32>, ptr %p, align 32
599; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %20 = load <7 x i32>, ptr %p, align 32
600; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: %21 = load <8 x i32>, ptr %p, align 32
601; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %22 = load <9 x i32>, ptr %p, align 64
602; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %23 = load <15 x i32>, ptr %p, align 64
603; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: %24 = load <16 x i32>, ptr %p, align 64
604; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %25 = load <31 x i32>, ptr %p, align 128
605; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: %26 = load <32 x i32>, ptr %p, align 128
606; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret void
607;
608; CODESIZE-LABEL: 'load_oddsize_vectors'
609; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %1 = load <1 x i1>, ptr %p, align 1
610; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %2 = load <2 x i1>, ptr %p, align 1
611; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %3 = load <3 x i1>, ptr %p, align 1
612; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %4 = load <4 x i1>, ptr %p, align 1
613; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %5 = load <5 x i1>, ptr %p, align 1
614; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %6 = load <6 x i1>, ptr %p, align 1
615; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %7 = load <7 x i1>, ptr %p, align 1
616; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %8 = load <8 x i1>, ptr %p, align 1
617; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %9 = load <9 x i1>, ptr %p, align 2
618; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %10 = load <15 x i1>, ptr %p, align 2
619; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %11 = load <16 x i1>, ptr %p, align 2
620; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %12 = load <31 x i1>, ptr %p, align 4
621; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %13 = load <32 x i1>, ptr %p, align 4
622; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %14 = load <1 x i32>, ptr %p, align 4
623; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %15 = load <2 x i32>, ptr %p, align 8
624; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %16 = load <3 x i32>, ptr %p, align 16
625; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %17 = load <4 x i32>, ptr %p, align 16
626; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %18 = load <5 x i32>, ptr %p, align 32
627; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %19 = load <6 x i32>, ptr %p, align 32
628; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %20 = load <7 x i32>, ptr %p, align 32
629; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %21 = load <8 x i32>, ptr %p, align 32
630; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %22 = load <9 x i32>, ptr %p, align 64
631; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %23 = load <15 x i32>, ptr %p, align 64
632; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %24 = load <16 x i32>, ptr %p, align 64
633; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %25 = load <31 x i32>, ptr %p, align 128
634; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: %26 = load <32 x i32>, ptr %p, align 128
635; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret void
636;
637
638  load <1 x i1>, ptr %p
639  load <2 x i1>, ptr %p
640  load <3 x i1>, ptr %p
641  load <4 x i1>, ptr %p
642  load <5 x i1>, ptr %p
643  load <6 x i1>, ptr %p
644  load <7 x i1>, ptr %p
645  load <8 x i1>, ptr %p
646  load <9 x i1>, ptr %p
647  load <15 x i1>, ptr %p
648  load <16 x i1>, ptr %p
649  load <31 x i1>, ptr %p
650  load <32 x i1>, ptr %p
651
652  load <1 x i32>, ptr %p
653  load <2 x i32>, ptr %p
654  load <3 x i32>, ptr %p
655  load <4 x i32>, ptr %p
656  load <5 x i32>, ptr %p
657  load <6 x i32>, ptr %p
658  load <7 x i32>, ptr %p
659  load <8 x i32>, ptr %p
660  load <9 x i32>, ptr %p
661  load <15 x i32>, ptr %p
662  load <16 x i32>, ptr %p
663  load <31 x i32>, ptr %p
664  load <32 x i32>, ptr %p
665
666  ret void
667}
668
669define void @store_oddsize_vectors(ptr %p) {
670; CHECK-LABEL: 'store_oddsize_vectors'
671; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x i1> undef, ptr %p, align 1
672; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x i1> undef, ptr %p, align 1
673; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <3 x i1> undef, ptr %p, align 1
674; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i1> undef, ptr %p, align 1
675; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <5 x i1> undef, ptr %p, align 1
676; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <6 x i1> undef, ptr %p, align 1
677; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <7 x i1> undef, ptr %p, align 1
678; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <8 x i1> undef, ptr %p, align 1
679; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <15 x i1> undef, ptr %p, align 2
680; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <16 x i1> undef, ptr %p, align 2
681; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <31 x i1> undef, ptr %p, align 4
682; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <32 x i1> undef, ptr %p, align 4
683; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x i32> undef, ptr %p, align 4
684; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x i32> undef, ptr %p, align 8
685; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <3 x i32> undef, ptr %p, align 16
686; CHECK-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i32> undef, ptr %p, align 16
687; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <5 x i32> undef, ptr %p, align 32
688; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <6 x i32> undef, ptr %p, align 32
689; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <7 x i32> undef, ptr %p, align 32
690; CHECK-NEXT:  Cost Model: Found an estimated cost of 2 for instruction: store <8 x i32> undef, ptr %p, align 32
691; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <15 x i32> undef, ptr %p, align 64
692; CHECK-NEXT:  Cost Model: Found an estimated cost of 4 for instruction: store <16 x i32> undef, ptr %p, align 64
693; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: store <31 x i32> undef, ptr %p, align 128
694; CHECK-NEXT:  Cost Model: Found an estimated cost of 8 for instruction: store <32 x i32> undef, ptr %p, align 128
695; CHECK-NEXT:  Cost Model: Found an estimated cost of 0 for instruction: ret void
696;
697; CODESIZE-LABEL: 'store_oddsize_vectors'
698; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x i1> undef, ptr %p, align 1
699; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x i1> undef, ptr %p, align 1
700; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <3 x i1> undef, ptr %p, align 1
701; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i1> undef, ptr %p, align 1
702; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <5 x i1> undef, ptr %p, align 1
703; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <6 x i1> undef, ptr %p, align 1
704; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <7 x i1> undef, ptr %p, align 1
705; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <8 x i1> undef, ptr %p, align 1
706; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <15 x i1> undef, ptr %p, align 2
707; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <16 x i1> undef, ptr %p, align 2
708; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <31 x i1> undef, ptr %p, align 4
709; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <32 x i1> undef, ptr %p, align 4
710; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <1 x i32> undef, ptr %p, align 4
711; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <2 x i32> undef, ptr %p, align 8
712; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <3 x i32> undef, ptr %p, align 16
713; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <4 x i32> undef, ptr %p, align 16
714; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <5 x i32> undef, ptr %p, align 32
715; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <6 x i32> undef, ptr %p, align 32
716; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <7 x i32> undef, ptr %p, align 32
717; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <8 x i32> undef, ptr %p, align 32
718; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <15 x i32> undef, ptr %p, align 64
719; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <16 x i32> undef, ptr %p, align 64
720; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <31 x i32> undef, ptr %p, align 128
721; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: store <32 x i32> undef, ptr %p, align 128
722; CODESIZE-NEXT:  Cost Model: Found an estimated cost of 1 for instruction: ret void
723;
724  store <1 x i1> undef, ptr %p
725  store <2 x i1> undef, ptr %p
726  store <3 x i1> undef, ptr %p
727  store <4 x i1> undef, ptr %p
728  store <5 x i1> undef, ptr %p
729  store <6 x i1> undef, ptr %p
730  store <7 x i1> undef, ptr %p
731  store <8 x i1> undef, ptr %p
732  store <15 x i1> undef, ptr %p
733  store <16 x i1> undef, ptr %p
734  store <31 x i1> undef, ptr %p
735  store <32 x i1> undef, ptr %p
736
737  store <1 x i32> undef, ptr %p
738  store <2 x i32> undef, ptr %p
739  store <3 x i32> undef, ptr %p
740  store <4 x i32> undef, ptr %p
741  store <5 x i32> undef, ptr %p
742  store <6 x i32> undef, ptr %p
743  store <7 x i32> undef, ptr %p
744  store <8 x i32> undef, ptr %p
745  store <15 x i32> undef, ptr %p
746  store <16 x i32> undef, ptr %p
747  store <31 x i32> undef, ptr %p
748  store <32 x i32> undef, ptr %p
749
750  ret void
751}
752