1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -mtriple=amdgcn-mesa-mesa3d -mcpu=fiji -O0 -run-pass=legalizer %s -o - | FileCheck %s
5 name: test_gep_global_i64_idx
8 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
10 ; CHECK-LABEL: name: test_gep_global_i64_idx
11 ; CHECK: liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
13 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p1) = COPY $vgpr0_vgpr1
14 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $vgpr2_vgpr3
15 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p1) = G_PTR_ADD [[COPY]], [[COPY1]](s64)
16 ; CHECK-NEXT: $vgpr0_vgpr1 = COPY [[PTR_ADD]](p1)
17 %0:_(p1) = COPY $vgpr0_vgpr1
18 %1:_(s64) = COPY $vgpr2_vgpr3
19 %2:_(p1) = G_PTR_ADD %0, %1
21 $vgpr0_vgpr1 = COPY %2
25 name: test_gep_flat_i64_idx
28 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
30 ; CHECK-LABEL: name: test_gep_flat_i64_idx
31 ; CHECK: liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
33 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p0) = COPY $vgpr0_vgpr1
34 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $vgpr2_vgpr3
35 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p0) = G_PTR_ADD [[COPY]], [[COPY1]](s64)
36 ; CHECK-NEXT: $vgpr0_vgpr1 = COPY [[PTR_ADD]](p0)
37 %0:_(p0) = COPY $vgpr0_vgpr1
38 %1:_(s64) = COPY $vgpr2_vgpr3
39 %2:_(p0) = G_PTR_ADD %0, %1
41 $vgpr0_vgpr1 = COPY %2
45 name: test_gep_constant_i64_idx
48 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
50 ; CHECK-LABEL: name: test_gep_constant_i64_idx
51 ; CHECK: liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
53 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p4) = COPY $vgpr0_vgpr1
54 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $vgpr2_vgpr3
55 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p4) = G_PTR_ADD [[COPY]], [[COPY1]](s64)
56 ; CHECK-NEXT: $vgpr0_vgpr1 = COPY [[PTR_ADD]](p4)
57 %0:_(p4) = COPY $vgpr0_vgpr1
58 %1:_(s64) = COPY $vgpr2_vgpr3
59 %2:_(p4) = G_PTR_ADD %0, %1
61 $vgpr0_vgpr1 = COPY %2
65 name: test_gep_local_i32_idx
68 liveins: $vgpr0, $vgpr1
70 ; CHECK-LABEL: name: test_gep_local_i32_idx
71 ; CHECK: liveins: $vgpr0, $vgpr1
73 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p3) = COPY $vgpr0
74 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $vgpr1
75 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p3) = G_PTR_ADD [[COPY]], [[COPY1]](s32)
76 ; CHECK-NEXT: $vgpr0 = COPY [[PTR_ADD]](p3)
77 %0:_(p3) = COPY $vgpr0
78 %1:_(s32) = COPY $vgpr1
79 %2:_(p3) = G_PTR_ADD %0, %1
85 name: test_gep_private_i32_idx
88 liveins: $vgpr0, $vgpr1
90 ; CHECK-LABEL: name: test_gep_private_i32_idx
91 ; CHECK: liveins: $vgpr0, $vgpr1
93 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p5) = COPY $vgpr0
94 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $vgpr1
95 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p5) = G_PTR_ADD [[COPY]], [[COPY1]](s32)
96 ; CHECK-NEXT: $vgpr0 = COPY [[PTR_ADD]](p5)
97 %0:_(p5) = COPY $vgpr0
98 %1:_(s32) = COPY $vgpr1
99 %2:_(p5) = G_PTR_ADD %0, %1
105 name: test_gep_constant32_i32_idx
108 liveins: $sgpr0, $sgpr1
110 ; CHECK-LABEL: name: test_gep_constant32_i32_idx
111 ; CHECK: liveins: $sgpr0, $sgpr1
113 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p6) = COPY $sgpr0
114 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $sgpr1
115 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p6) = G_PTR_ADD [[COPY]], [[COPY1]](s32)
116 ; CHECK-NEXT: $sgpr0 = COPY [[PTR_ADD]](p6)
117 %0:_(p6) = COPY $sgpr0
118 %1:_(s32) = COPY $sgpr1
119 %2:_(p6) = G_PTR_ADD %0, %1
125 name: test_gep_region_i32_idx
128 liveins: $vgpr0, $vgpr1
130 ; CHECK-LABEL: name: test_gep_region_i32_idx
131 ; CHECK: liveins: $vgpr0, $vgpr1
133 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p2) = COPY $vgpr0
134 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $vgpr1
135 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p2) = G_PTR_ADD [[COPY]], [[COPY1]](s32)
136 ; CHECK-NEXT: $vgpr0 = COPY [[PTR_ADD]](p2)
137 %0:_(p2) = COPY $vgpr0
138 %1:_(s32) = COPY $vgpr1
139 %2:_(p2) = G_PTR_ADD %0, %1
145 name: test_gep_p999_i64_idx
148 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
150 ; CHECK-LABEL: name: test_gep_p999_i64_idx
151 ; CHECK: liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
153 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p999) = COPY $vgpr0_vgpr1
154 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $vgpr2_vgpr3
155 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p999) = G_PTR_ADD [[COPY]], [[COPY1]](s64)
156 ; CHECK-NEXT: $vgpr0_vgpr1 = COPY [[PTR_ADD]](p999)
157 %0:_(p999) = COPY $vgpr0_vgpr1
158 %1:_(s64) = COPY $vgpr2_vgpr3
159 %2:_(p999) = G_PTR_ADD %0, %1
160 $vgpr0_vgpr1 = COPY %2
164 name: test_gep_v2p1_v2i64
167 liveins: $vgpr0_vgpr1_vgpr2_vgpr3, $vgpr4_vgpr5_vgpr6_vgpr7
169 ; CHECK-LABEL: name: test_gep_v2p1_v2i64
170 ; CHECK: liveins: $vgpr0_vgpr1_vgpr2_vgpr3, $vgpr4_vgpr5_vgpr6_vgpr7
172 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(<2 x p1>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3
173 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(<2 x s64>) = COPY $vgpr4_vgpr5_vgpr6_vgpr7
174 ; CHECK-NEXT: [[UV:%[0-9]+]]:_(p1), [[UV1:%[0-9]+]]:_(p1) = G_UNMERGE_VALUES [[COPY]](<2 x p1>)
175 ; CHECK-NEXT: [[UV2:%[0-9]+]]:_(s64), [[UV3:%[0-9]+]]:_(s64) = G_UNMERGE_VALUES [[COPY1]](<2 x s64>)
176 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p1) = G_PTR_ADD [[UV]], [[UV2]](s64)
177 ; CHECK-NEXT: [[PTR_ADD1:%[0-9]+]]:_(p1) = G_PTR_ADD [[UV1]], [[UV3]](s64)
178 ; CHECK-NEXT: [[BUILD_VECTOR:%[0-9]+]]:_(<2 x p1>) = G_BUILD_VECTOR [[PTR_ADD]](p1), [[PTR_ADD1]](p1)
179 ; CHECK-NEXT: $vgpr0_vgpr1_vgpr2_vgpr3 = COPY [[BUILD_VECTOR]](<2 x p1>)
180 %0:_(<2 x p1>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3
181 %1:_(<2 x s64>) = COPY $vgpr4_vgpr5_vgpr6_vgpr7
182 %2:_(<2 x p1>) = G_PTR_ADD %0, %1
183 $vgpr0_vgpr1_vgpr2_vgpr3 = COPY %2
187 name: test_gep_v2p3_v2s32
190 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
192 ; CHECK-LABEL: name: test_gep_v2p3_v2s32
193 ; CHECK: liveins: $vgpr0_vgpr1, $vgpr2_vgpr3
195 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(<2 x p3>) = COPY $vgpr0_vgpr1
196 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(<2 x s32>) = COPY $vgpr2_vgpr3
197 ; CHECK-NEXT: [[UV:%[0-9]+]]:_(p3), [[UV1:%[0-9]+]]:_(p3) = G_UNMERGE_VALUES [[COPY]](<2 x p3>)
198 ; CHECK-NEXT: [[UV2:%[0-9]+]]:_(s32), [[UV3:%[0-9]+]]:_(s32) = G_UNMERGE_VALUES [[COPY1]](<2 x s32>)
199 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p3) = G_PTR_ADD [[UV]], [[UV2]](s32)
200 ; CHECK-NEXT: [[PTR_ADD1:%[0-9]+]]:_(p3) = G_PTR_ADD [[UV1]], [[UV3]](s32)
201 ; CHECK-NEXT: [[BUILD_VECTOR:%[0-9]+]]:_(<2 x p3>) = G_BUILD_VECTOR [[PTR_ADD]](p3), [[PTR_ADD1]](p3)
202 ; CHECK-NEXT: $vgpr0_vgpr1 = COPY [[BUILD_VECTOR]](<2 x p3>)
203 %0:_(<2 x p3>) = COPY $vgpr0_vgpr1
204 %1:_(<2 x s32>) = COPY $vgpr2_vgpr3
205 %2:_(<2 x p3>) = G_PTR_ADD %0, %1
206 $vgpr0_vgpr1 = COPY %2
210 name: test_gep_global_s16_idx
213 liveins: $vgpr0_vgpr1, $vgpr2
215 ; CHECK-LABEL: name: test_gep_global_s16_idx
216 ; CHECK: liveins: $vgpr0_vgpr1, $vgpr2
218 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p1) = COPY $vgpr0_vgpr1
219 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $vgpr2
220 ; CHECK-NEXT: [[ANYEXT:%[0-9]+]]:_(s64) = G_ANYEXT [[COPY1]](s32)
221 ; CHECK-NEXT: [[SEXT_INREG:%[0-9]+]]:_(s64) = G_SEXT_INREG [[ANYEXT]], 16
222 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p1) = G_PTR_ADD [[COPY]], [[SEXT_INREG]](s64)
223 ; CHECK-NEXT: $vgpr0_vgpr1 = COPY [[PTR_ADD]](p1)
224 %0:_(p1) = COPY $vgpr0_vgpr1
225 %1:_(s32) = COPY $vgpr2
226 %2:_(s16) = G_TRUNC %1
227 %3:_(p1) = G_PTR_ADD %0, %2
228 $vgpr0_vgpr1 = COPY %3
232 name: test_gep_global_s32_idx
235 liveins: $vgpr0_vgpr1, $vgpr2
237 ; CHECK-LABEL: name: test_gep_global_s32_idx
238 ; CHECK: liveins: $vgpr0_vgpr1, $vgpr2
240 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p1) = COPY $vgpr0_vgpr1
241 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $vgpr2
242 ; CHECK-NEXT: [[SEXT:%[0-9]+]]:_(s64) = G_SEXT [[COPY1]](s32)
243 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p1) = G_PTR_ADD [[COPY]], [[SEXT]](s64)
244 ; CHECK-NEXT: $vgpr0_vgpr1 = COPY [[PTR_ADD]](p1)
245 %0:_(p1) = COPY $vgpr0_vgpr1
246 %1:_(s32) = COPY $vgpr2
247 %2:_(p1) = G_PTR_ADD %0, %1
248 $vgpr0_vgpr1 = COPY %2
252 name: test_gep_global_s96_idx
255 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3_vgpr4
257 ; CHECK-LABEL: name: test_gep_global_s96_idx
258 ; CHECK: liveins: $vgpr0_vgpr1, $vgpr2_vgpr3_vgpr4
260 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p1) = COPY $vgpr0_vgpr1
261 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s96) = COPY $vgpr2_vgpr3_vgpr4
262 ; CHECK-NEXT: [[TRUNC:%[0-9]+]]:_(s64) = G_TRUNC [[COPY1]](s96)
263 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p1) = G_PTR_ADD [[COPY]], [[TRUNC]](s64)
264 ; CHECK-NEXT: $vgpr0_vgpr1 = COPY [[PTR_ADD]](p1)
265 %0:_(p1) = COPY $vgpr0_vgpr1
266 %1:_(s96) = COPY $vgpr2_vgpr3_vgpr4
267 %2:_(p1) = G_PTR_ADD %0, %1
268 $vgpr0_vgpr1 = COPY %2
272 name: test_gep_local_i16_idx
275 liveins: $vgpr0, $vgpr1
277 ; CHECK-LABEL: name: test_gep_local_i16_idx
278 ; CHECK: liveins: $vgpr0, $vgpr1
280 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p3) = COPY $vgpr0
281 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s32) = COPY $vgpr1
282 ; CHECK-NEXT: [[SEXT_INREG:%[0-9]+]]:_(s32) = G_SEXT_INREG [[COPY1]], 16
283 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p3) = G_PTR_ADD [[COPY]], [[SEXT_INREG]](s32)
284 ; CHECK-NEXT: $vgpr0 = COPY [[PTR_ADD]](p3)
285 %0:_(p3) = COPY $vgpr0
286 %1:_(s32) = COPY $vgpr1
287 %2:_(s16) = G_TRUNC %1
288 %3:_(p3) = G_PTR_ADD %0, %2
293 name: test_gep_local_i64_idx
296 liveins: $vgpr0, $vgpr1_vgpr2
298 ; CHECK-LABEL: name: test_gep_local_i64_idx
299 ; CHECK: liveins: $vgpr0, $vgpr1_vgpr2
301 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(p3) = COPY $vgpr0
302 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s64) = COPY $vgpr1_vgpr2
303 ; CHECK-NEXT: [[TRUNC:%[0-9]+]]:_(s32) = G_TRUNC [[COPY1]](s64)
304 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p3) = G_PTR_ADD [[COPY]], [[TRUNC]](s32)
305 ; CHECK-NEXT: $vgpr0 = COPY [[PTR_ADD]](p3)
306 %0:_(p3) = COPY $vgpr0
307 %1:_(s64) = COPY $vgpr1_vgpr2
308 %2:_(p3) = G_PTR_ADD %0, %1
313 name: test_gep_v2p1_v2i32
316 liveins: $vgpr0_vgpr1_vgpr2_vgpr3, $vgpr4_vgpr5
318 ; CHECK-LABEL: name: test_gep_v2p1_v2i32
319 ; CHECK: liveins: $vgpr0_vgpr1_vgpr2_vgpr3, $vgpr4_vgpr5
321 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(<2 x p1>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3
322 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(<2 x s32>) = COPY $vgpr4_vgpr5
323 ; CHECK-NEXT: [[UV:%[0-9]+]]:_(p1), [[UV1:%[0-9]+]]:_(p1) = G_UNMERGE_VALUES [[COPY]](<2 x p1>)
324 ; CHECK-NEXT: [[UV2:%[0-9]+]]:_(s32), [[UV3:%[0-9]+]]:_(s32) = G_UNMERGE_VALUES [[COPY1]](<2 x s32>)
325 ; CHECK-NEXT: [[SEXT:%[0-9]+]]:_(s64) = G_SEXT [[UV2]](s32)
326 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p1) = G_PTR_ADD [[UV]], [[SEXT]](s64)
327 ; CHECK-NEXT: [[SEXT1:%[0-9]+]]:_(s64) = G_SEXT [[UV3]](s32)
328 ; CHECK-NEXT: [[PTR_ADD1:%[0-9]+]]:_(p1) = G_PTR_ADD [[UV1]], [[SEXT1]](s64)
329 ; CHECK-NEXT: [[BUILD_VECTOR:%[0-9]+]]:_(<2 x p1>) = G_BUILD_VECTOR [[PTR_ADD]](p1), [[PTR_ADD1]](p1)
330 ; CHECK-NEXT: $vgpr0_vgpr1_vgpr2_vgpr3 = COPY [[BUILD_VECTOR]](<2 x p1>)
331 %0:_(<2 x p1>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3
332 %1:_(<2 x s32>) = COPY $vgpr4_vgpr5
333 %2:_(<2 x p1>) = G_PTR_ADD %0, %1
334 $vgpr0_vgpr1_vgpr2_vgpr3 = COPY %2
338 name: test_gep_v2p1_v2i96
341 liveins: $vgpr0_vgpr1_vgpr2_vgpr3, $vgpr4_vgpr5_vgpr6, $vgpr7_vgpr8_vgpr9
343 ; CHECK-LABEL: name: test_gep_v2p1_v2i96
344 ; CHECK: liveins: $vgpr0_vgpr1_vgpr2_vgpr3, $vgpr4_vgpr5_vgpr6, $vgpr7_vgpr8_vgpr9
346 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(<2 x p1>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3
347 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(s96) = COPY $vgpr4_vgpr5_vgpr6
348 ; CHECK-NEXT: [[COPY2:%[0-9]+]]:_(s96) = COPY $vgpr7_vgpr8_vgpr9
349 ; CHECK-NEXT: [[UV:%[0-9]+]]:_(p1), [[UV1:%[0-9]+]]:_(p1) = G_UNMERGE_VALUES [[COPY]](<2 x p1>)
350 ; CHECK-NEXT: [[TRUNC:%[0-9]+]]:_(s64) = G_TRUNC [[COPY1]](s96)
351 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p1) = G_PTR_ADD [[UV]], [[TRUNC]](s64)
352 ; CHECK-NEXT: [[TRUNC1:%[0-9]+]]:_(s64) = G_TRUNC [[COPY2]](s96)
353 ; CHECK-NEXT: [[PTR_ADD1:%[0-9]+]]:_(p1) = G_PTR_ADD [[UV1]], [[TRUNC1]](s64)
354 ; CHECK-NEXT: [[BUILD_VECTOR:%[0-9]+]]:_(<2 x p1>) = G_BUILD_VECTOR [[PTR_ADD]](p1), [[PTR_ADD1]](p1)
355 ; CHECK-NEXT: $vgpr0_vgpr1_vgpr2_vgpr3 = COPY [[BUILD_VECTOR]](<2 x p1>)
356 %0:_(<2 x p1>) = COPY $vgpr0_vgpr1_vgpr2_vgpr3
357 %1:_(s96) = COPY $vgpr4_vgpr5_vgpr6
358 %2:_(s96) = COPY $vgpr7_vgpr8_vgpr9
359 %3:_(<2 x s96>) = G_BUILD_VECTOR %1, %2
360 %4:_(<2 x p1>) = G_PTR_ADD %0, %3
361 $vgpr0_vgpr1_vgpr2_vgpr3 = COPY %4
365 name: test_gep_v2p3_v2s16
368 liveins: $vgpr0_vgpr1, $vgpr2
370 ; CHECK-LABEL: name: test_gep_v2p3_v2s16
371 ; CHECK: liveins: $vgpr0_vgpr1, $vgpr2
373 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(<2 x p3>) = COPY $vgpr0_vgpr1
374 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(<2 x s16>) = COPY $vgpr2
375 ; CHECK-NEXT: [[UV:%[0-9]+]]:_(p3), [[UV1:%[0-9]+]]:_(p3) = G_UNMERGE_VALUES [[COPY]](<2 x p3>)
376 ; CHECK-NEXT: [[BITCAST:%[0-9]+]]:_(s32) = G_BITCAST [[COPY1]](<2 x s16>)
377 ; CHECK-NEXT: [[C:%[0-9]+]]:_(s32) = G_CONSTANT i32 16
378 ; CHECK-NEXT: [[LSHR:%[0-9]+]]:_(s32) = G_LSHR [[BITCAST]], [[C]](s32)
379 ; CHECK-NEXT: [[SEXT_INREG:%[0-9]+]]:_(s32) = G_SEXT_INREG [[BITCAST]], 16
380 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p3) = G_PTR_ADD [[UV]], [[SEXT_INREG]](s32)
381 ; CHECK-NEXT: [[SEXT_INREG1:%[0-9]+]]:_(s32) = G_SEXT_INREG [[LSHR]], 16
382 ; CHECK-NEXT: [[PTR_ADD1:%[0-9]+]]:_(p3) = G_PTR_ADD [[UV1]], [[SEXT_INREG1]](s32)
383 ; CHECK-NEXT: [[BUILD_VECTOR:%[0-9]+]]:_(<2 x p3>) = G_BUILD_VECTOR [[PTR_ADD]](p3), [[PTR_ADD1]](p3)
384 ; CHECK-NEXT: $vgpr0_vgpr1 = COPY [[BUILD_VECTOR]](<2 x p3>)
385 %0:_(<2 x p3>) = COPY $vgpr0_vgpr1
386 %1:_(<2 x s16>) = COPY $vgpr2
387 %2:_(<2 x p3>) = G_PTR_ADD %0, %1
388 $vgpr0_vgpr1 = COPY %2
392 name: test_gep_v2p3_v2s64
395 liveins: $vgpr0_vgpr1, $vgpr2_vgpr3_vgpr4_vgpr5
397 ; CHECK-LABEL: name: test_gep_v2p3_v2s64
398 ; CHECK: liveins: $vgpr0_vgpr1, $vgpr2_vgpr3_vgpr4_vgpr5
400 ; CHECK-NEXT: [[COPY:%[0-9]+]]:_(<2 x p3>) = COPY $vgpr0_vgpr1
401 ; CHECK-NEXT: [[COPY1:%[0-9]+]]:_(<2 x s64>) = COPY $vgpr2_vgpr3_vgpr4_vgpr5
402 ; CHECK-NEXT: [[UV:%[0-9]+]]:_(p3), [[UV1:%[0-9]+]]:_(p3) = G_UNMERGE_VALUES [[COPY]](<2 x p3>)
403 ; CHECK-NEXT: [[UV2:%[0-9]+]]:_(s64), [[UV3:%[0-9]+]]:_(s64) = G_UNMERGE_VALUES [[COPY1]](<2 x s64>)
404 ; CHECK-NEXT: [[TRUNC:%[0-9]+]]:_(s32) = G_TRUNC [[UV2]](s64)
405 ; CHECK-NEXT: [[PTR_ADD:%[0-9]+]]:_(p3) = G_PTR_ADD [[UV]], [[TRUNC]](s32)
406 ; CHECK-NEXT: [[TRUNC1:%[0-9]+]]:_(s32) = G_TRUNC [[UV3]](s64)
407 ; CHECK-NEXT: [[PTR_ADD1:%[0-9]+]]:_(p3) = G_PTR_ADD [[UV1]], [[TRUNC1]](s32)
408 ; CHECK-NEXT: [[BUILD_VECTOR:%[0-9]+]]:_(<2 x p3>) = G_BUILD_VECTOR [[PTR_ADD]](p3), [[PTR_ADD1]](p3)
409 ; CHECK-NEXT: $vgpr0_vgpr1 = COPY [[BUILD_VECTOR]](<2 x p3>)
410 %0:_(<2 x p3>) = COPY $vgpr0_vgpr1
411 %1:_(<2 x s64>) = COPY $vgpr2_vgpr3_vgpr4_vgpr5
412 %2:_(<2 x p3>) = G_PTR_ADD %0, %1
413 $vgpr0_vgpr1 = COPY %2