1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -mtriple=riscv32 -mattr=+v -run-pass=legalizer %s -o - | FileCheck %s
3 # RUN: llc -mtriple=riscv64 -mattr=+v -run-pass=legalizer %s -o - | FileCheck %s
6 name: implicitdef_nxv1i1
8 tracksRegLiveness: true
11 ; CHECK-LABEL: name: implicitdef_nxv1i1
12 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 1 x s1>) = G_IMPLICIT_DEF
13 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 1 x s1>)
14 ; CHECK-NEXT: PseudoRET implicit $v8
15 %0:_(<vscale x 1 x s1>) = G_IMPLICIT_DEF
16 $v8 = COPY %0(<vscale x 1 x s1>)
17 PseudoRET implicit $v8
20 name: implicitdef_nxv2i1
22 tracksRegLiveness: true
25 ; CHECK-LABEL: name: implicitdef_nxv2i1
26 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 2 x s1>) = G_IMPLICIT_DEF
27 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 2 x s1>)
28 ; CHECK-NEXT: PseudoRET implicit $v8
29 %0:_(<vscale x 2 x s1>) = G_IMPLICIT_DEF
30 $v8 = COPY %0(<vscale x 2 x s1>)
31 PseudoRET implicit $v8
34 name: implicitdef_nxv4i1
36 tracksRegLiveness: true
39 ; CHECK-LABEL: name: implicitdef_nxv4i1
40 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 4 x s1>) = G_IMPLICIT_DEF
41 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 4 x s1>)
42 ; CHECK-NEXT: PseudoRET implicit $v8
43 %0:_(<vscale x 4 x s1>) = G_IMPLICIT_DEF
44 $v8 = COPY %0(<vscale x 4 x s1>)
45 PseudoRET implicit $v8
48 name: implicitdef_nxv8i1
50 tracksRegLiveness: true
53 ; CHECK-LABEL: name: implicitdef_nxv8i1
54 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 8 x s1>) = G_IMPLICIT_DEF
55 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 8 x s1>)
56 ; CHECK-NEXT: PseudoRET implicit $v8
57 %0:_(<vscale x 8 x s1>) = G_IMPLICIT_DEF
58 $v8 = COPY %0(<vscale x 8 x s1>)
59 PseudoRET implicit $v8
62 name: implicitdef_nxv16i1
64 tracksRegLiveness: true
67 ; CHECK-LABEL: name: implicitdef_nxv16i1
68 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 16 x s1>) = G_IMPLICIT_DEF
69 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 16 x s1>)
70 ; CHECK-NEXT: PseudoRET implicit $v8
71 %0:_(<vscale x 16 x s1>) = G_IMPLICIT_DEF
72 $v8 = COPY %0(<vscale x 16 x s1>)
73 PseudoRET implicit $v8
76 name: implicitdef_nxv32i1
78 tracksRegLiveness: true
81 ; CHECK-LABEL: name: implicitdef_nxv32i1
82 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 32 x s1>) = G_IMPLICIT_DEF
83 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 32 x s1>)
84 ; CHECK-NEXT: PseudoRET implicit $v8
85 %0:_(<vscale x 32 x s1>) = G_IMPLICIT_DEF
86 $v8 = COPY %0(<vscale x 32 x s1>)
87 PseudoRET implicit $v8
90 name: implicitdef_nxv64i1
92 tracksRegLiveness: true
95 ; CHECK-LABEL: name: implicitdef_nxv64i1
96 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 64 x s1>) = G_IMPLICIT_DEF
97 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 64 x s1>)
98 ; CHECK-NEXT: PseudoRET implicit $v8
99 %0:_(<vscale x 64 x s1>) = G_IMPLICIT_DEF
100 $v8 = COPY %0(<vscale x 64 x s1>)
101 PseudoRET implicit $v8
104 name: implicitdef_nxv1i8
106 tracksRegLiveness: true
109 ; CHECK-LABEL: name: implicitdef_nxv1i8
110 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 1 x s8>) = G_IMPLICIT_DEF
111 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 1 x s8>)
112 ; CHECK-NEXT: PseudoRET implicit $v8
113 %0:_(<vscale x 1 x s8>) = G_IMPLICIT_DEF
114 $v8 = COPY %0(<vscale x 1 x s8>)
115 PseudoRET implicit $v8
118 name: implicitdef_nxv2i8
120 tracksRegLiveness: true
123 ; CHECK-LABEL: name: implicitdef_nxv2i8
124 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 2 x s8>) = G_IMPLICIT_DEF
125 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 2 x s8>)
126 ; CHECK-NEXT: PseudoRET implicit $v8
127 %0:_(<vscale x 2 x s8>) = G_IMPLICIT_DEF
128 $v8 = COPY %0(<vscale x 2 x s8>)
129 PseudoRET implicit $v8
132 name: implicitdef_nxv4i8
134 tracksRegLiveness: true
137 ; CHECK-LABEL: name: implicitdef_nxv4i8
138 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 4 x s8>) = G_IMPLICIT_DEF
139 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 4 x s8>)
140 ; CHECK-NEXT: PseudoRET implicit $v8
141 %0:_(<vscale x 4 x s8>) = G_IMPLICIT_DEF
142 $v8 = COPY %0(<vscale x 4 x s8>)
143 PseudoRET implicit $v8
146 name: implicitdef_nxv8i8
148 tracksRegLiveness: true
151 ; CHECK-LABEL: name: implicitdef_nxv8i8
152 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 8 x s8>) = G_IMPLICIT_DEF
153 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 8 x s8>)
154 ; CHECK-NEXT: PseudoRET implicit $v8
155 %0:_(<vscale x 8 x s8>) = G_IMPLICIT_DEF
156 $v8 = COPY %0(<vscale x 8 x s8>)
157 PseudoRET implicit $v8
160 name: implicitdef_nxv16i8
162 tracksRegLiveness: true
165 ; CHECK-LABEL: name: implicitdef_nxv16i8
166 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 16 x s8>) = G_IMPLICIT_DEF
167 ; CHECK-NEXT: $v8m2 = COPY [[DEF]](<vscale x 16 x s8>)
168 ; CHECK-NEXT: PseudoRET implicit $v8m2
169 %0:_(<vscale x 16 x s8>) = G_IMPLICIT_DEF
170 $v8m2 = COPY %0(<vscale x 16 x s8>)
171 PseudoRET implicit $v8m2
174 name: implicitdef_nxv32i8
176 tracksRegLiveness: true
179 ; CHECK-LABEL: name: implicitdef_nxv32i8
180 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 32 x s8>) = G_IMPLICIT_DEF
181 ; CHECK-NEXT: $v8m4 = COPY [[DEF]](<vscale x 32 x s8>)
182 ; CHECK-NEXT: PseudoRET implicit $v8m4
183 %0:_(<vscale x 32 x s8>) = G_IMPLICIT_DEF
184 $v8m4 = COPY %0(<vscale x 32 x s8>)
185 PseudoRET implicit $v8m4
188 name: implicitdef_nxv64i8
190 tracksRegLiveness: true
193 ; CHECK-LABEL: name: implicitdef_nxv64i8
194 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 64 x s8>) = G_IMPLICIT_DEF
195 ; CHECK-NEXT: $v8m8 = COPY [[DEF]](<vscale x 64 x s8>)
196 ; CHECK-NEXT: PseudoRET implicit $v8m8
197 %0:_(<vscale x 64 x s8>) = G_IMPLICIT_DEF
198 $v8m8 = COPY %0(<vscale x 64 x s8>)
199 PseudoRET implicit $v8m8
202 name: implicitdef_nxv1i16
204 tracksRegLiveness: true
207 ; CHECK-LABEL: name: implicitdef_nxv1i16
208 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 1 x s16>) = G_IMPLICIT_DEF
209 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 1 x s16>)
210 ; CHECK-NEXT: PseudoRET implicit $v8
211 %0:_(<vscale x 1 x s16>) = G_IMPLICIT_DEF
212 $v8 = COPY %0(<vscale x 1 x s16>)
213 PseudoRET implicit $v8
216 name: implicitdef_nxv2i16
218 tracksRegLiveness: true
221 ; CHECK-LABEL: name: implicitdef_nxv2i16
222 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 2 x s16>) = G_IMPLICIT_DEF
223 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 2 x s16>)
224 ; CHECK-NEXT: PseudoRET implicit $v8
225 %0:_(<vscale x 2 x s16>) = G_IMPLICIT_DEF
226 $v8 = COPY %0(<vscale x 2 x s16>)
227 PseudoRET implicit $v8
230 name: implicitdef_nxv4i16
232 tracksRegLiveness: true
235 ; CHECK-LABEL: name: implicitdef_nxv4i16
236 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 4 x s16>) = G_IMPLICIT_DEF
237 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 4 x s16>)
238 ; CHECK-NEXT: PseudoRET implicit $v8
239 %0:_(<vscale x 4 x s16>) = G_IMPLICIT_DEF
240 $v8 = COPY %0(<vscale x 4 x s16>)
241 PseudoRET implicit $v8
244 name: implicitdef_nxv8i16
246 tracksRegLiveness: true
249 ; CHECK-LABEL: name: implicitdef_nxv8i16
250 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 8 x s16>) = G_IMPLICIT_DEF
251 ; CHECK-NEXT: $v8m2 = COPY [[DEF]](<vscale x 8 x s16>)
252 ; CHECK-NEXT: PseudoRET implicit $v8m2
253 %0:_(<vscale x 8 x s16>) = G_IMPLICIT_DEF
254 $v8m2 = COPY %0(<vscale x 8 x s16>)
255 PseudoRET implicit $v8m2
258 name: implicitdef_nxv16i16
260 tracksRegLiveness: true
263 ; CHECK-LABEL: name: implicitdef_nxv16i16
264 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 16 x s16>) = G_IMPLICIT_DEF
265 ; CHECK-NEXT: $v8m4 = COPY [[DEF]](<vscale x 16 x s16>)
266 ; CHECK-NEXT: PseudoRET implicit $v8m4
267 %0:_(<vscale x 16 x s16>) = G_IMPLICIT_DEF
268 $v8m4 = COPY %0(<vscale x 16 x s16>)
269 PseudoRET implicit $v8m4
272 name: implicitdef_nxv32i16
274 tracksRegLiveness: true
277 ; CHECK-LABEL: name: implicitdef_nxv32i16
278 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 32 x s16>) = G_IMPLICIT_DEF
279 ; CHECK-NEXT: $v8m8 = COPY [[DEF]](<vscale x 32 x s16>)
280 ; CHECK-NEXT: PseudoRET implicit $v8m8
281 %0:_(<vscale x 32 x s16>) = G_IMPLICIT_DEF
282 $v8m8 = COPY %0(<vscale x 32 x s16>)
283 PseudoRET implicit $v8m8
286 name: implicitdef_nxv1i32
288 tracksRegLiveness: true
291 ; CHECK-LABEL: name: implicitdef_nxv1i32
292 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 1 x s32>) = G_IMPLICIT_DEF
293 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 1 x s32>)
294 ; CHECK-NEXT: PseudoRET implicit $v8
295 %0:_(<vscale x 1 x s32>) = G_IMPLICIT_DEF
296 $v8 = COPY %0(<vscale x 1 x s32>)
297 PseudoRET implicit $v8
300 name: implicitdef_nxv2i32
302 tracksRegLiveness: true
305 ; CHECK-LABEL: name: implicitdef_nxv2i32
306 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 2 x s32>) = G_IMPLICIT_DEF
307 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 2 x s32>)
308 ; CHECK-NEXT: PseudoRET implicit $v8
309 %0:_(<vscale x 2 x s32>) = G_IMPLICIT_DEF
310 $v8 = COPY %0(<vscale x 2 x s32>)
311 PseudoRET implicit $v8
314 name: implicitdef_nxv4i32
316 tracksRegLiveness: true
319 ; CHECK-LABEL: name: implicitdef_nxv4i32
320 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 4 x s32>) = G_IMPLICIT_DEF
321 ; CHECK-NEXT: $v8m2 = COPY [[DEF]](<vscale x 4 x s32>)
322 ; CHECK-NEXT: PseudoRET implicit $v8m2
323 %0:_(<vscale x 4 x s32>) = G_IMPLICIT_DEF
324 $v8m2 = COPY %0(<vscale x 4 x s32>)
325 PseudoRET implicit $v8m2
328 name: implicitdef_nxv8i32
330 tracksRegLiveness: true
333 ; CHECK-LABEL: name: implicitdef_nxv8i32
334 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 8 x s32>) = G_IMPLICIT_DEF
335 ; CHECK-NEXT: $v8m4 = COPY [[DEF]](<vscale x 8 x s32>)
336 ; CHECK-NEXT: PseudoRET implicit $v8m4
337 %0:_(<vscale x 8 x s32>) = G_IMPLICIT_DEF
338 $v8m4 = COPY %0(<vscale x 8 x s32>)
339 PseudoRET implicit $v8m4
342 name: implicitdef_nxv16i32
344 tracksRegLiveness: true
347 ; CHECK-LABEL: name: implicitdef_nxv16i32
348 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 16 x s32>) = G_IMPLICIT_DEF
349 ; CHECK-NEXT: $v8m8 = COPY [[DEF]](<vscale x 16 x s32>)
350 ; CHECK-NEXT: PseudoRET implicit $v8m8
351 %0:_(<vscale x 16 x s32>) = G_IMPLICIT_DEF
352 $v8m8 = COPY %0(<vscale x 16 x s32>)
353 PseudoRET implicit $v8m8
356 name: implicitdef_nxv1i64
358 tracksRegLiveness: true
361 ; CHECK-LABEL: name: implicitdef_nxv1i64
362 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 1 x s64>) = G_IMPLICIT_DEF
363 ; CHECK-NEXT: $v8 = COPY [[DEF]](<vscale x 1 x s64>)
364 ; CHECK-NEXT: PseudoRET implicit $v8
365 %0:_(<vscale x 1 x s64>) = G_IMPLICIT_DEF
366 $v8 = COPY %0(<vscale x 1 x s64>)
367 PseudoRET implicit $v8
370 name: implicitdef_nxv2i64
372 tracksRegLiveness: true
375 ; CHECK-LABEL: name: implicitdef_nxv2i64
376 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 2 x s64>) = G_IMPLICIT_DEF
377 ; CHECK-NEXT: $v8m2 = COPY [[DEF]](<vscale x 2 x s64>)
378 ; CHECK-NEXT: PseudoRET implicit $v8m2
379 %0:_(<vscale x 2 x s64>) = G_IMPLICIT_DEF
380 $v8m2 = COPY %0(<vscale x 2 x s64>)
381 PseudoRET implicit $v8m2
384 name: implicitdef_nxv4i64
386 tracksRegLiveness: true
389 ; CHECK-LABEL: name: implicitdef_nxv4i64
390 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 4 x s64>) = G_IMPLICIT_DEF
391 ; CHECK-NEXT: $v8m4 = COPY [[DEF]](<vscale x 4 x s64>)
392 ; CHECK-NEXT: PseudoRET implicit $v8m4
393 %0:_(<vscale x 4 x s64>) = G_IMPLICIT_DEF
394 $v8m4 = COPY %0(<vscale x 4 x s64>)
395 PseudoRET implicit $v8m4
398 name: implicitdef_nxv8i64
400 tracksRegLiveness: true
403 ; CHECK-LABEL: name: implicitdef_nxv8i64
404 ; CHECK: [[DEF:%[0-9]+]]:_(<vscale x 8 x s64>) = G_IMPLICIT_DEF
405 ; CHECK-NEXT: $v8m8 = COPY [[DEF]](<vscale x 8 x s64>)
406 ; CHECK-NEXT: PseudoRET implicit $v8m8
407 %0:_(<vscale x 8 x s64>) = G_IMPLICIT_DEF
408 $v8m8 = COPY %0(<vscale x 8 x s64>)
409 PseudoRET implicit $v8m8