1 # NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py
2 # RUN: llc -march=amdgcn -mcpu=tahiti -run-pass=instruction-select -verify-machineinstrs -global-isel-abort=0 -o - %s | FileCheck -check-prefix=GFX6 %s
3 # RUN: llc -march=amdgcn -mcpu=gfx900 -run-pass=instruction-select -verify-machineinstrs -global-isel-abort=0 -o - %s | FileCheck -check-prefix=GFX9 %s
7 name: load_private_s32_from_4
10 tracksRegLiveness: true
12 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
13 scratchWaveOffsetReg: $sgpr4
14 stackPtrOffsetReg: $sgpr32
20 ; GFX6-LABEL: name: load_private_s32_from_4
21 ; GFX6: liveins: $vgpr0
22 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
23 ; GFX6: [[BUFFER_LOAD_DWORD_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_DWORD_OFFEN [[COPY]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 4, addrspace 5)
24 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_DWORD_OFFEN]]
25 ; GFX9-LABEL: name: load_private_s32_from_4
26 ; GFX9: liveins: $vgpr0
27 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
28 ; GFX9: [[BUFFER_LOAD_DWORD_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_DWORD_OFFEN [[COPY]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 4, addrspace 5)
29 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_DWORD_OFFEN]]
30 %0:vgpr(p5) = COPY $vgpr0
31 %1:vgpr(s32) = G_LOAD %0 :: (load 4, align 4, addrspace 5)
38 name: load_private_s32_from_2
41 tracksRegLiveness: true
43 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
44 scratchWaveOffsetReg: $sgpr4
45 stackPtrOffsetReg: $sgpr32
51 ; GFX6-LABEL: name: load_private_s32_from_2
52 ; GFX6: liveins: $vgpr0
53 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
54 ; GFX6: [[BUFFER_LOAD_USHORT_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_USHORT_OFFEN [[COPY]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 2, addrspace 5)
55 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_USHORT_OFFEN]]
56 ; GFX9-LABEL: name: load_private_s32_from_2
57 ; GFX9: liveins: $vgpr0
58 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
59 ; GFX9: [[BUFFER_LOAD_USHORT_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_USHORT_OFFEN [[COPY]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 2, addrspace 5)
60 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_USHORT_OFFEN]]
61 %0:vgpr(p5) = COPY $vgpr0
62 %1:vgpr(s32) = G_LOAD %0 :: (load 2, align 2, addrspace 5)
69 name: load_private_s32_from_1
72 tracksRegLiveness: true
74 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
75 scratchWaveOffsetReg: $sgpr4
76 stackPtrOffsetReg: $sgpr32
82 ; GFX6-LABEL: name: load_private_s32_from_1
83 ; GFX6: liveins: $vgpr0
84 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
85 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[COPY]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
86 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
87 ; GFX9-LABEL: name: load_private_s32_from_1
88 ; GFX9: liveins: $vgpr0
89 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
90 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[COPY]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
91 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
92 %0:vgpr(p5) = COPY $vgpr0
93 %1:vgpr(s32) = G_LOAD %0 :: (load 1, align 1, addrspace 5)
100 name: load_private_p3_from_4
102 regBankSelected: true
103 tracksRegLiveness: true
109 ; GFX6-LABEL: name: load_private_p3_from_4
110 ; GFX6: liveins: $vgpr0
111 ; GFX6: [[COPY:%[0-9]+]]:vgpr(p5) = COPY $vgpr0
112 ; GFX6: [[LOAD:%[0-9]+]]:vgpr_32(p3) = G_LOAD [[COPY]](p5) :: (load 4, addrspace 5)
113 ; GFX6: $vgpr0 = COPY [[LOAD]](p3)
114 ; GFX9-LABEL: name: load_private_p3_from_4
115 ; GFX9: liveins: $vgpr0
116 ; GFX9: [[COPY:%[0-9]+]]:vgpr(p5) = COPY $vgpr0
117 ; GFX9: [[LOAD:%[0-9]+]]:vgpr_32(p3) = G_LOAD [[COPY]](p5) :: (load 4, addrspace 5)
118 ; GFX9: $vgpr0 = COPY [[LOAD]](p3)
119 %0:vgpr(p5) = COPY $vgpr0
120 %1:vgpr(p3) = G_LOAD %0 :: (load 4, align 4, addrspace 5)
127 name: load_private_p5_from_4
129 regBankSelected: true
130 tracksRegLiveness: true
132 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
133 scratchWaveOffsetReg: $sgpr4
134 stackPtrOffsetReg: $sgpr32
140 ; GFX6-LABEL: name: load_private_p5_from_4
141 ; GFX6: liveins: $vgpr0
142 ; GFX6: [[COPY:%[0-9]+]]:vgpr(p5) = COPY $vgpr0
143 ; GFX6: [[LOAD:%[0-9]+]]:vgpr_32(p5) = G_LOAD [[COPY]](p5) :: (load 4, addrspace 5)
144 ; GFX6: $vgpr0 = COPY [[LOAD]](p5)
145 ; GFX9-LABEL: name: load_private_p5_from_4
146 ; GFX9: liveins: $vgpr0
147 ; GFX9: [[COPY:%[0-9]+]]:vgpr(p5) = COPY $vgpr0
148 ; GFX9: [[LOAD:%[0-9]+]]:vgpr_32(p5) = G_LOAD [[COPY]](p5) :: (load 4, addrspace 5)
149 ; GFX9: $vgpr0 = COPY [[LOAD]](p5)
150 %0:vgpr(p5) = COPY $vgpr0
151 %1:vgpr(p5) = G_LOAD %0 :: (load 4, align 4, addrspace 5)
158 name: load_private_v2s16
160 regBankSelected: true
161 tracksRegLiveness: true
163 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
164 scratchWaveOffsetReg: $sgpr4
165 stackPtrOffsetReg: $sgpr32
171 ; GFX6-LABEL: name: load_private_v2s16
172 ; GFX6: liveins: $vgpr0
173 ; GFX6: [[COPY:%[0-9]+]]:vgpr(p5) = COPY $vgpr0
174 ; GFX6: [[LOAD:%[0-9]+]]:vgpr_32(<2 x s16>) = G_LOAD [[COPY]](p5) :: (load 4, addrspace 5)
175 ; GFX6: $vgpr0 = COPY [[LOAD]](<2 x s16>)
176 ; GFX9-LABEL: name: load_private_v2s16
177 ; GFX9: liveins: $vgpr0
178 ; GFX9: [[COPY:%[0-9]+]]:vgpr(p5) = COPY $vgpr0
179 ; GFX9: [[LOAD:%[0-9]+]]:vgpr_32(<2 x s16>) = G_LOAD [[COPY]](p5) :: (load 4, addrspace 5)
180 ; GFX9: $vgpr0 = COPY [[LOAD]](<2 x s16>)
181 %0:vgpr(p5) = COPY $vgpr0
182 %1:vgpr(<2 x s16>) = G_LOAD %0 :: (load 4, align 4, addrspace 5)
187 ################################################################################
188 ### Stress addressing modes
189 ################################################################################
193 name: load_private_s32_from_1_gep_2047
195 regBankSelected: true
196 tracksRegLiveness: true
198 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
199 scratchWaveOffsetReg: $sgpr4
200 stackPtrOffsetReg: $sgpr32
206 ; GFX6-LABEL: name: load_private_s32_from_1_gep_2047
207 ; GFX6: liveins: $vgpr0
208 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
209 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 2047, implicit $exec
210 ; GFX6: %2:vgpr_32, dead %4:sreg_64_xexec = V_ADD_I32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
211 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN %2, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
212 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
213 ; GFX9-LABEL: name: load_private_s32_from_1_gep_2047
214 ; GFX9: liveins: $vgpr0
215 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
216 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[COPY]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 2047, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
217 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
218 %0:vgpr(p5) = COPY $vgpr0
219 %1:vgpr(s32) = G_CONSTANT i32 2047
220 %2:vgpr(p5) = G_GEP %0, %1
221 %3:vgpr(s32) = G_LOAD %2 :: (load 1, align 1, addrspace 5)
228 name: load_private_s32_from_1_gep_2047_known_bits
230 regBankSelected: true
231 tracksRegLiveness: true
233 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
234 scratchWaveOffsetReg: $sgpr4
235 stackPtrOffsetReg: $sgpr32
241 ; GFX6-LABEL: name: load_private_s32_from_1_gep_2047_known_bits
242 ; GFX6: liveins: $vgpr0
243 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
244 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 2147483647, implicit $exec
245 ; GFX6: [[V_AND_B32_e64_:%[0-9]+]]:vgpr_32 = V_AND_B32_e64 [[COPY]], [[V_MOV_B32_e32_]], implicit $exec
246 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[V_AND_B32_e64_]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 2047, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
247 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
248 ; GFX9-LABEL: name: load_private_s32_from_1_gep_2047_known_bits
249 ; GFX9: liveins: $vgpr0
250 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
251 ; GFX9: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 2147483647, implicit $exec
252 ; GFX9: [[V_AND_B32_e64_:%[0-9]+]]:vgpr_32 = V_AND_B32_e64 [[COPY]], [[V_MOV_B32_e32_]], implicit $exec
253 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[V_AND_B32_e64_]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 2047, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
254 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
255 %0:vgpr(s32) = COPY $vgpr0
256 %1:vgpr(s32) = G_CONSTANT i32 2147483647
257 %2:vgpr(s32) = G_AND %0, %1
258 %3:vgpr(p5) = G_INTTOPTR %2
259 %4:vgpr(s32) = G_CONSTANT i32 2047
260 %5:vgpr(p5) = G_GEP %3, %4
261 %6:vgpr(s32) = G_LOAD %5 :: (load 1, align 1, addrspace 5)
268 name: load_private_s32_from_1_gep_2048
270 regBankSelected: true
271 tracksRegLiveness: true
273 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
274 scratchWaveOffsetReg: $sgpr4
275 stackPtrOffsetReg: $sgpr32
281 ; GFX6-LABEL: name: load_private_s32_from_1_gep_2048
282 ; GFX6: liveins: $vgpr0
283 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
284 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 2048, implicit $exec
285 ; GFX6: %2:vgpr_32, dead %4:sreg_64_xexec = V_ADD_I32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
286 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN %2, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
287 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
288 ; GFX9-LABEL: name: load_private_s32_from_1_gep_2048
289 ; GFX9: liveins: $vgpr0
290 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
291 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[COPY]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 2048, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
292 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
293 %0:vgpr(p5) = COPY $vgpr0
294 %1:vgpr(s32) = G_CONSTANT i32 2048
295 %2:vgpr(p5) = G_GEP %0, %1
296 %3:vgpr(s32) = G_LOAD %2 :: (load 1, align 1, addrspace 5)
303 name: load_private_s32_from_1_gep_m2047
305 regBankSelected: true
306 tracksRegLiveness: true
308 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
309 scratchWaveOffsetReg: $sgpr4
310 stackPtrOffsetReg: $sgpr32
316 ; GFX6-LABEL: name: load_private_s32_from_1_gep_m2047
317 ; GFX6: liveins: $vgpr0
318 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
319 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4294965249, implicit $exec
320 ; GFX6: %2:vgpr_32, dead %4:sreg_64_xexec = V_ADD_I32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
321 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN %2, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
322 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
323 ; GFX9-LABEL: name: load_private_s32_from_1_gep_m2047
324 ; GFX9: liveins: $vgpr0
325 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
326 ; GFX9: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4294965249, implicit $exec
327 ; GFX9: [[V_ADD_U32_e64_:%[0-9]+]]:vgpr_32 = V_ADD_U32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
328 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[V_ADD_U32_e64_]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
329 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
330 %0:vgpr(p5) = COPY $vgpr0
331 %1:vgpr(s32) = G_CONSTANT i32 -2047
332 %2:vgpr(p5) = G_GEP %0, %1
333 %3:vgpr(s32) = G_LOAD %2 :: (load 1, align 1, addrspace 5)
340 name: load_private_s32_from_1_gep_m2048
342 regBankSelected: true
343 tracksRegLiveness: true
345 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
346 scratchWaveOffsetReg: $sgpr4
347 stackPtrOffsetReg: $sgpr32
353 ; GFX6-LABEL: name: load_private_s32_from_1_gep_m2048
354 ; GFX6: liveins: $vgpr0
355 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
356 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4294965248, implicit $exec
357 ; GFX6: %2:vgpr_32, dead %4:sreg_64_xexec = V_ADD_I32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
358 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN %2, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
359 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
360 ; GFX9-LABEL: name: load_private_s32_from_1_gep_m2048
361 ; GFX9: liveins: $vgpr0
362 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
363 ; GFX9: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4294965248, implicit $exec
364 ; GFX9: [[V_ADD_U32_e64_:%[0-9]+]]:vgpr_32 = V_ADD_U32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
365 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[V_ADD_U32_e64_]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
366 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
367 %0:vgpr(p5) = COPY $vgpr0
368 %1:vgpr(s32) = G_CONSTANT i32 -2048
369 %2:vgpr(p5) = G_GEP %0, %1
370 %3:vgpr(s32) = G_LOAD %2 :: (load 1, align 1, addrspace 5)
377 name: load_private_s32_from_1_gep_4095
379 regBankSelected: true
380 tracksRegLiveness: true
382 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
383 scratchWaveOffsetReg: $sgpr4
384 stackPtrOffsetReg: $sgpr32
390 ; GFX6-LABEL: name: load_private_s32_from_1_gep_4095
391 ; GFX6: liveins: $vgpr0
392 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
393 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4095, implicit $exec
394 ; GFX6: %2:vgpr_32, dead %4:sreg_64_xexec = V_ADD_I32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
395 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN %2, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
396 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
397 ; GFX9-LABEL: name: load_private_s32_from_1_gep_4095
398 ; GFX9: liveins: $vgpr0
399 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
400 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[COPY]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 4095, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
401 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
402 %0:vgpr(p5) = COPY $vgpr0
403 %1:vgpr(s32) = G_CONSTANT i32 4095
404 %2:vgpr(p5) = G_GEP %0, %1
405 %3:vgpr(s32) = G_LOAD %2 :: (load 1, align 1, addrspace 5)
412 name: load_private_s32_from_1_gep_4096
414 regBankSelected: true
415 tracksRegLiveness: true
417 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
418 scratchWaveOffsetReg: $sgpr4
419 stackPtrOffsetReg: $sgpr32
425 ; GFX6-LABEL: name: load_private_s32_from_1_gep_4096
426 ; GFX6: liveins: $vgpr0
427 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
428 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4096, implicit $exec
429 ; GFX6: %2:vgpr_32, dead %4:sreg_64_xexec = V_ADD_I32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
430 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN %2, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
431 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
432 ; GFX9-LABEL: name: load_private_s32_from_1_gep_4096
433 ; GFX9: liveins: $vgpr0
434 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
435 ; GFX9: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4096, implicit $exec
436 ; GFX9: [[V_ADD_U32_e64_:%[0-9]+]]:vgpr_32 = V_ADD_U32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
437 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[V_ADD_U32_e64_]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
438 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
439 %0:vgpr(p5) = COPY $vgpr0
440 %1:vgpr(s32) = G_CONSTANT i32 4096
441 %2:vgpr(p5) = G_GEP %0, %1
442 %3:vgpr(s32) = G_LOAD %2 :: (load 1, align 1, addrspace 5)
449 name: load_private_s32_from_1_gep_m4095
451 regBankSelected: true
452 tracksRegLiveness: true
454 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
455 scratchWaveOffsetReg: $sgpr4
456 stackPtrOffsetReg: $sgpr32
462 ; GFX6-LABEL: name: load_private_s32_from_1_gep_m4095
463 ; GFX6: liveins: $vgpr0
464 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
465 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4294963201, implicit $exec
466 ; GFX6: %2:vgpr_32, dead %4:sreg_64_xexec = V_ADD_I32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
467 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN %2, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
468 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
469 ; GFX9-LABEL: name: load_private_s32_from_1_gep_m4095
470 ; GFX9: liveins: $vgpr0
471 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
472 ; GFX9: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4294963201, implicit $exec
473 ; GFX9: [[V_ADD_U32_e64_:%[0-9]+]]:vgpr_32 = V_ADD_U32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
474 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[V_ADD_U32_e64_]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
475 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
476 %0:vgpr(p5) = COPY $vgpr0
477 %1:vgpr(s32) = G_CONSTANT i32 -4095
478 %2:vgpr(p5) = G_GEP %0, %1
479 %3:vgpr(s32) = G_LOAD %2 :: (load 1, align 1, addrspace 5)
486 name: load_private_s32_from_1_gep_m4096
488 regBankSelected: true
489 tracksRegLiveness: true
491 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
492 scratchWaveOffsetReg: $sgpr4
493 stackPtrOffsetReg: $sgpr32
499 ; GFX6-LABEL: name: load_private_s32_from_1_gep_m4096
500 ; GFX6: liveins: $vgpr0
501 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
502 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4294963200, implicit $exec
503 ; GFX6: %2:vgpr_32, dead %4:sreg_64_xexec = V_ADD_I32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
504 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN %2, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
505 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
506 ; GFX9-LABEL: name: load_private_s32_from_1_gep_m4096
507 ; GFX9: liveins: $vgpr0
508 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
509 ; GFX9: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4294963200, implicit $exec
510 ; GFX9: [[V_ADD_U32_e64_:%[0-9]+]]:vgpr_32 = V_ADD_U32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
511 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[V_ADD_U32_e64_]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
512 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
513 %0:vgpr(p5) = COPY $vgpr0
514 %1:vgpr(s32) = G_CONSTANT i32 -4096
515 %2:vgpr(p5) = G_GEP %0, %1
516 %3:vgpr(s32) = G_LOAD %2 :: (load 1, align 1, addrspace 5)
523 name: load_private_s32_from_1_gep_8191
525 regBankSelected: true
526 tracksRegLiveness: true
528 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
529 scratchWaveOffsetReg: $sgpr4
530 stackPtrOffsetReg: $sgpr32
536 ; GFX6-LABEL: name: load_private_s32_from_1_gep_8191
537 ; GFX6: liveins: $vgpr0
538 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
539 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 8191, implicit $exec
540 ; GFX6: %2:vgpr_32, dead %4:sreg_64_xexec = V_ADD_I32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
541 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN %2, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
542 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
543 ; GFX9-LABEL: name: load_private_s32_from_1_gep_8191
544 ; GFX9: liveins: $vgpr0
545 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
546 ; GFX9: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 8191, implicit $exec
547 ; GFX9: [[V_ADD_U32_e64_:%[0-9]+]]:vgpr_32 = V_ADD_U32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
548 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[V_ADD_U32_e64_]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
549 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
550 %0:vgpr(p5) = COPY $vgpr0
551 %1:vgpr(s32) = G_CONSTANT i32 8191
552 %2:vgpr(p5) = G_GEP %0, %1
553 %3:vgpr(s32) = G_LOAD %2 :: (load 1, align 1, addrspace 5)
560 name: load_private_s32_from_1_gep_8192
562 regBankSelected: true
563 tracksRegLiveness: true
565 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
566 scratchWaveOffsetReg: $sgpr4
567 stackPtrOffsetReg: $sgpr32
573 ; GFX6-LABEL: name: load_private_s32_from_1_gep_8192
574 ; GFX6: liveins: $vgpr0
575 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
576 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 8192, implicit $exec
577 ; GFX6: %2:vgpr_32, dead %4:sreg_64_xexec = V_ADD_I32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
578 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN %2, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
579 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
580 ; GFX9-LABEL: name: load_private_s32_from_1_gep_8192
581 ; GFX9: liveins: $vgpr0
582 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
583 ; GFX9: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 8192, implicit $exec
584 ; GFX9: [[V_ADD_U32_e64_:%[0-9]+]]:vgpr_32 = V_ADD_U32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
585 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[V_ADD_U32_e64_]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
586 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
587 %0:vgpr(p5) = COPY $vgpr0
588 %1:vgpr(s32) = G_CONSTANT i32 8192
589 %2:vgpr(p5) = G_GEP %0, %1
590 %3:vgpr(s32) = G_LOAD %2 :: (load 1, align 1, addrspace 5)
597 name: load_private_s32_from_1_gep_m8191
599 regBankSelected: true
600 tracksRegLiveness: true
602 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
603 scratchWaveOffsetReg: $sgpr4
604 stackPtrOffsetReg: $sgpr32
610 ; GFX6-LABEL: name: load_private_s32_from_1_gep_m8191
611 ; GFX6: liveins: $vgpr0
612 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
613 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4294959105, implicit $exec
614 ; GFX6: %2:vgpr_32, dead %4:sreg_64_xexec = V_ADD_I32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
615 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN %2, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
616 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
617 ; GFX9-LABEL: name: load_private_s32_from_1_gep_m8191
618 ; GFX9: liveins: $vgpr0
619 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
620 ; GFX9: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4294959105, implicit $exec
621 ; GFX9: [[V_ADD_U32_e64_:%[0-9]+]]:vgpr_32 = V_ADD_U32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
622 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[V_ADD_U32_e64_]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
623 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
624 %0:vgpr(p5) = COPY $vgpr0
625 %1:vgpr(s32) = G_CONSTANT i32 -8191
626 %2:vgpr(p5) = G_GEP %0, %1
627 %3:vgpr(s32) = G_LOAD %2 :: (load 1, align 1, addrspace 5)
634 name: load_private_s32_from_1_gep_m8192
636 regBankSelected: true
637 tracksRegLiveness: true
639 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
640 scratchWaveOffsetReg: $sgpr4
641 stackPtrOffsetReg: $sgpr32
647 ; GFX6-LABEL: name: load_private_s32_from_1_gep_m8192
648 ; GFX6: liveins: $vgpr0
649 ; GFX6: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
650 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4294959104, implicit $exec
651 ; GFX6: %2:vgpr_32, dead %4:sreg_64_xexec = V_ADD_I32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
652 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN %2, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
653 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
654 ; GFX9-LABEL: name: load_private_s32_from_1_gep_m8192
655 ; GFX9: liveins: $vgpr0
656 ; GFX9: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
657 ; GFX9: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4294959104, implicit $exec
658 ; GFX9: [[V_ADD_U32_e64_:%[0-9]+]]:vgpr_32 = V_ADD_U32_e64 [[COPY]], [[V_MOV_B32_e32_]], 0, implicit $exec
659 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[V_ADD_U32_e64_]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
660 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
661 %0:vgpr(p5) = COPY $vgpr0
662 %1:vgpr(s32) = G_CONSTANT i32 -8192
663 %2:vgpr(p5) = G_GEP %0, %1
664 %3:vgpr(s32) = G_LOAD %2 :: (load 1, align 1, addrspace 5)
671 name: load_private_s32_from_4_constant_0
673 regBankSelected: true
674 tracksRegLiveness: true
676 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
677 scratchWaveOffsetReg: $sgpr4
678 stackPtrOffsetReg: $sgpr32
683 ; GFX6-LABEL: name: load_private_s32_from_4_constant_0
684 ; GFX6: [[BUFFER_LOAD_DWORD_OFFSET:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_DWORD_OFFSET $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 4, addrspace 5)
685 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_DWORD_OFFSET]]
686 ; GFX9-LABEL: name: load_private_s32_from_4_constant_0
687 ; GFX9: [[BUFFER_LOAD_DWORD_OFFSET:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_DWORD_OFFSET $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 4, addrspace 5)
688 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_DWORD_OFFSET]]
689 %0:vgpr(p5) = G_CONSTANT i32 0
690 %1:vgpr(s32) = G_LOAD %0 :: (load 4, align 4, addrspace 5)
697 name: load_private_s32_from_4_constant_sgpr_16
699 regBankSelected: true
700 tracksRegLiveness: true
702 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
703 scratchWaveOffsetReg: $sgpr4
704 stackPtrOffsetReg: $sgpr32
709 ; GFX6-LABEL: name: load_private_s32_from_4_constant_sgpr_16
710 ; GFX6: [[BUFFER_LOAD_DWORD_OFFSET:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_DWORD_OFFSET $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 16, 0, 0, 0, 0, 0, implicit $exec :: (load 4, addrspace 5)
711 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_DWORD_OFFSET]]
712 ; GFX9-LABEL: name: load_private_s32_from_4_constant_sgpr_16
713 ; GFX9: [[BUFFER_LOAD_DWORD_OFFSET:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_DWORD_OFFSET $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 16, 0, 0, 0, 0, 0, implicit $exec :: (load 4, addrspace 5)
714 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_DWORD_OFFSET]]
715 %0:sgpr(p5) = G_CONSTANT i32 16
716 %1:vgpr(s32) = G_LOAD %0 :: (load 4, align 4, addrspace 5)
723 name: load_private_s32_from_1_constant_4095
725 regBankSelected: true
726 tracksRegLiveness: true
728 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
729 scratchWaveOffsetReg: $sgpr4
730 stackPtrOffsetReg: $sgpr32
735 ; GFX6-LABEL: name: load_private_s32_from_1_constant_4095
736 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFSET:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFSET $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 4095, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
737 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFSET]]
738 ; GFX9-LABEL: name: load_private_s32_from_1_constant_4095
739 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFSET:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFSET $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 4095, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
740 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFSET]]
741 %0:vgpr(p5) = G_CONSTANT i32 4095
742 %1:vgpr(s32) = G_LOAD %0 :: (load 1, align 1, addrspace 5)
749 name: load_private_s32_from_1_constant_4096
751 regBankSelected: true
752 tracksRegLiveness: true
754 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
755 scratchWaveOffsetReg: $sgpr4
756 stackPtrOffsetReg: $sgpr32
761 ; GFX6-LABEL: name: load_private_s32_from_1_constant_4096
762 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4096, implicit $exec
763 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[V_MOV_B32_e32_]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
764 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
765 ; GFX9-LABEL: name: load_private_s32_from_1_constant_4096
766 ; GFX9: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4096, implicit $exec
767 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[V_MOV_B32_e32_]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
768 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
769 %0:vgpr(p5) = G_CONSTANT i32 4096
770 %1:vgpr(s32) = G_LOAD %0 :: (load 1, align 1, addrspace 5)
777 name: load_private_s32_from_fi
779 regBankSelected: true
780 tracksRegLiveness: true
782 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
783 scratchWaveOffsetReg: $sgpr4
784 stackPtrOffsetReg: $sgpr32
786 - { id: 0, size: 4, alignment: 4 }
791 ; GFX6-LABEL: name: load_private_s32_from_fi
792 ; GFX6: [[BUFFER_LOAD_DWORD_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_DWORD_OFFEN %stack.0, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr32, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 4, addrspace 5)
793 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_DWORD_OFFEN]]
794 ; GFX9-LABEL: name: load_private_s32_from_fi
795 ; GFX9: [[BUFFER_LOAD_DWORD_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_DWORD_OFFEN %stack.0, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr32, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 4, addrspace 5)
796 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_DWORD_OFFEN]]
797 %0:vgpr(p5) = G_FRAME_INDEX %stack.0
798 %1:vgpr(s32) = G_LOAD %0 :: (load 4, align 4, addrspace 5)
805 name: load_private_s32_from_1_fi_offset_4095
807 regBankSelected: true
808 tracksRegLiveness: true
810 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
811 scratchWaveOffsetReg: $sgpr4
812 stackPtrOffsetReg: $sgpr32
814 - { id: 0, size: 4096, alignment: 4 }
819 ; GFX6-LABEL: name: load_private_s32_from_1_fi_offset_4095
820 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 %stack.0, implicit $exec
821 ; GFX6: [[V_MOV_B32_e32_1:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4095, implicit $exec
822 ; GFX6: %2:vgpr_32, dead %4:sreg_64_xexec = V_ADD_I32_e64 [[V_MOV_B32_e32_]], [[V_MOV_B32_e32_1]], 0, implicit $exec
823 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN %2, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
824 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
825 ; GFX9-LABEL: name: load_private_s32_from_1_fi_offset_4095
826 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN %stack.0, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr32, 4095, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
827 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
828 %0:vgpr(p5) = G_FRAME_INDEX %stack.0
829 %1:vgpr(s32) = G_CONSTANT i32 4095
830 %2:vgpr(p5) = G_GEP %0, %1
831 %3:vgpr(s32) = G_LOAD %2 :: (load 1, align 1, addrspace 5)
838 name: load_private_s32_from_1_fi_offset_4096
840 regBankSelected: true
841 tracksRegLiveness: true
843 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
844 scratchWaveOffsetReg: $sgpr4
845 stackPtrOffsetReg: $sgpr32
847 - { id: 0, size: 8192, alignment: 4 }
852 ; GFX6-LABEL: name: load_private_s32_from_1_fi_offset_4096
853 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 %stack.0, implicit $exec
854 ; GFX6: [[V_MOV_B32_e32_1:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4096, implicit $exec
855 ; GFX6: %2:vgpr_32, dead %4:sreg_64_xexec = V_ADD_I32_e64 [[V_MOV_B32_e32_]], [[V_MOV_B32_e32_1]], 0, implicit $exec
856 ; GFX6: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN %2, $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
857 ; GFX6: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
858 ; GFX9-LABEL: name: load_private_s32_from_1_fi_offset_4096
859 ; GFX9: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 %stack.0, implicit $exec
860 ; GFX9: [[V_MOV_B32_e32_1:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4096, implicit $exec
861 ; GFX9: [[V_ADD_U32_e64_:%[0-9]+]]:vgpr_32 = V_ADD_U32_e64 [[V_MOV_B32_e32_]], [[V_MOV_B32_e32_1]], 0, implicit $exec
862 ; GFX9: [[BUFFER_LOAD_UBYTE_OFFEN:%[0-9]+]]:vgpr_32 = BUFFER_LOAD_UBYTE_OFFEN [[V_ADD_U32_e64_]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr4, 0, 0, 0, 0, 0, 0, implicit $exec :: (load 1, addrspace 5)
863 ; GFX9: $vgpr0 = COPY [[BUFFER_LOAD_UBYTE_OFFEN]]
864 %0:vgpr(p5) = G_FRAME_INDEX %stack.0
865 %1:vgpr(s32) = G_CONSTANT i32 4096
866 %2:vgpr(p5) = G_GEP %0, %1
867 %3:vgpr(s32) = G_LOAD %2 :: (load 1, align 1, addrspace 5)