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 -O0 -march=amdgcn -mcpu=tahiti -run-pass=instruction-select -verify-machineinstrs -global-isel-abort=0 -o - %s | FileCheck -check-prefix=GFX6 %s
4 # RUN: llc -march=amdgcn -mcpu=gfx900 -run-pass=instruction-select -verify-machineinstrs -global-isel-abort=0 -o - %s | FileCheck -check-prefix=GFX9 %s
5 # RUN: llc -march=amdgcn -mcpu=gfx1010 -mattr=-wavefrontsize32,+wavefrontsize64 -run-pass=instruction-select -verify-machineinstrs -global-isel-abort=0 -o - %s | FileCheck -check-prefix=GFX9 %s
6 # RUN: llc -march=amdgcn -mcpu=gfx1100 -run-pass=instruction-select -verify-machineinstrs -global-isel-abort=0 -o - %s | FileCheck -check-prefix=GFX11 %s
10 name: function_store_private_s32_to_4
13 tracksRegLiveness: true
15 isEntryFunction: false
16 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
17 stackPtrOffsetReg: $sgpr32
21 liveins: $vgpr0, $vgpr1
23 ; GFX6-LABEL: name: function_store_private_s32_to_4
24 ; GFX6: liveins: $vgpr0, $vgpr1
26 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
27 ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
28 ; GFX6-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s32), addrspace 5)
29 ; GFX9-LABEL: name: function_store_private_s32_to_4
30 ; GFX9: liveins: $vgpr0, $vgpr1
32 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
33 ; GFX9-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
34 ; GFX9-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s32), addrspace 5)
35 ; GFX11-LABEL: name: function_store_private_s32_to_4
36 ; GFX11: liveins: $vgpr0, $vgpr1
38 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
39 ; GFX11-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
40 ; GFX11-NEXT: SCRATCH_STORE_DWORD [[COPY]], [[COPY1]], 0, 0, implicit $exec, implicit $flat_scr :: (store (s32), addrspace 5)
41 %0:vgpr(s32) = COPY $vgpr0
42 %1:vgpr(p5) = COPY $vgpr1
43 G_STORE %0, %1 :: (store (s32), align 4, addrspace 5)
49 name: function_store_private_s32_to_2
52 tracksRegLiveness: true
54 isEntryFunction: false
55 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
56 stackPtrOffsetReg: $sgpr32
60 liveins: $vgpr0, $vgpr1
62 ; GFX6-LABEL: name: function_store_private_s32_to_2
63 ; GFX6: liveins: $vgpr0, $vgpr1
65 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
66 ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
67 ; GFX6-NEXT: BUFFER_STORE_SHORT_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s16), addrspace 5)
68 ; GFX9-LABEL: name: function_store_private_s32_to_2
69 ; GFX9: liveins: $vgpr0, $vgpr1
71 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
72 ; GFX9-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
73 ; GFX9-NEXT: BUFFER_STORE_SHORT_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s16), addrspace 5)
74 ; GFX11-LABEL: name: function_store_private_s32_to_2
75 ; GFX11: liveins: $vgpr0, $vgpr1
77 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
78 ; GFX11-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
79 ; GFX11-NEXT: SCRATCH_STORE_SHORT [[COPY]], [[COPY1]], 0, 0, implicit $exec, implicit $flat_scr :: (store (s16), addrspace 5)
80 %0:vgpr(s32) = COPY $vgpr0
81 %1:vgpr(p5) = COPY $vgpr1
82 G_STORE %0, %1 :: (store (s16), align 2, addrspace 5)
88 name: function_store_private_s32_to_1
91 tracksRegLiveness: true
93 isEntryFunction: false
94 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
95 stackPtrOffsetReg: $sgpr32
99 liveins: $vgpr0, $vgpr1
101 ; GFX6-LABEL: name: function_store_private_s32_to_1
102 ; GFX6: liveins: $vgpr0, $vgpr1
104 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
105 ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
106 ; GFX6-NEXT: BUFFER_STORE_BYTE_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s8), addrspace 5)
107 ; GFX9-LABEL: name: function_store_private_s32_to_1
108 ; GFX9: liveins: $vgpr0, $vgpr1
110 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
111 ; GFX9-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
112 ; GFX9-NEXT: BUFFER_STORE_BYTE_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s8), addrspace 5)
113 ; GFX11-LABEL: name: function_store_private_s32_to_1
114 ; GFX11: liveins: $vgpr0, $vgpr1
116 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
117 ; GFX11-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
118 ; GFX11-NEXT: SCRATCH_STORE_BYTE [[COPY]], [[COPY1]], 0, 0, implicit $exec, implicit $flat_scr :: (store (s8), addrspace 5)
119 %0:vgpr(s32) = COPY $vgpr0
120 %1:vgpr(p5) = COPY $vgpr1
121 G_STORE %0, %1 :: (store (s8), align 1, addrspace 5)
127 name: function_store_private_v2s16
129 regBankSelected: true
130 tracksRegLiveness: true
132 isEntryFunction: false
133 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
134 stackPtrOffsetReg: $sgpr32
138 liveins: $vgpr0, $vgpr1
140 ; GFX6-LABEL: name: function_store_private_v2s16
141 ; GFX6: liveins: $vgpr0, $vgpr1
143 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
144 ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
145 ; GFX6-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (<2 x s16>), addrspace 5)
146 ; GFX9-LABEL: name: function_store_private_v2s16
147 ; GFX9: liveins: $vgpr0, $vgpr1
149 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
150 ; GFX9-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
151 ; GFX9-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (<2 x s16>), addrspace 5)
152 ; GFX11-LABEL: name: function_store_private_v2s16
153 ; GFX11: liveins: $vgpr0, $vgpr1
155 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
156 ; GFX11-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
157 ; GFX11-NEXT: SCRATCH_STORE_DWORD [[COPY]], [[COPY1]], 0, 0, implicit $exec, implicit $flat_scr :: (store (<2 x s16>), addrspace 5)
158 %0:vgpr(<2 x s16>) = COPY $vgpr0
159 %1:vgpr(p5) = COPY $vgpr1
160 G_STORE %0, %1 :: (store (<2 x s16>), align 4, addrspace 5)
166 name: function_store_private_p3
168 regBankSelected: true
169 tracksRegLiveness: true
171 isEntryFunction: false
172 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
173 stackPtrOffsetReg: $sgpr32
177 liveins: $vgpr0, $vgpr1
179 ; GFX6-LABEL: name: function_store_private_p3
180 ; GFX6: liveins: $vgpr0, $vgpr1
182 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
183 ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
184 ; GFX6-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (p3), addrspace 5)
185 ; GFX9-LABEL: name: function_store_private_p3
186 ; GFX9: liveins: $vgpr0, $vgpr1
188 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
189 ; GFX9-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
190 ; GFX9-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (p3), addrspace 5)
191 ; GFX11-LABEL: name: function_store_private_p3
192 ; GFX11: liveins: $vgpr0, $vgpr1
194 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
195 ; GFX11-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
196 ; GFX11-NEXT: SCRATCH_STORE_DWORD [[COPY]], [[COPY1]], 0, 0, implicit $exec, implicit $flat_scr :: (store (p3), addrspace 5)
197 %0:vgpr(p3) = COPY $vgpr0
198 %1:vgpr(p5) = COPY $vgpr1
199 G_STORE %0, %1 :: (store (p3), align 4, addrspace 5)
205 name: function_store_private_p5
207 regBankSelected: true
208 tracksRegLiveness: true
210 isEntryFunction: false
211 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
212 stackPtrOffsetReg: $sgpr32
216 liveins: $vgpr0, $vgpr1
218 ; GFX6-LABEL: name: function_store_private_p5
219 ; GFX6: liveins: $vgpr0, $vgpr1
221 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
222 ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
223 ; GFX6-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (p5), addrspace 5)
224 ; GFX9-LABEL: name: function_store_private_p5
225 ; GFX9: liveins: $vgpr0, $vgpr1
227 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
228 ; GFX9-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
229 ; GFX9-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (p5), addrspace 5)
230 ; GFX11-LABEL: name: function_store_private_p5
231 ; GFX11: liveins: $vgpr0, $vgpr1
233 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
234 ; GFX11-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
235 ; GFX11-NEXT: SCRATCH_STORE_DWORD [[COPY]], [[COPY1]], 0, 0, implicit $exec, implicit $flat_scr :: (store (p5), addrspace 5)
236 %0:vgpr(p5) = COPY $vgpr0
237 %1:vgpr(p5) = COPY $vgpr1
238 G_STORE %0, %1 :: (store (p5), align 4, addrspace 5)
244 name: function_store_private_s32_to_1_fi_offset_4095
246 regBankSelected: true
247 tracksRegLiveness: true
249 isEntryFunction: false
250 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
251 stackPtrOffsetReg: $sgpr32
253 - { id: 0, size: 4096, alignment: 4 }
258 ; GFX6-LABEL: name: function_store_private_s32_to_1_fi_offset_4095
259 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
260 ; GFX6-NEXT: BUFFER_STORE_BYTE_OFFEN [[V_MOV_B32_e32_]], %stack.0, $sgpr0_sgpr1_sgpr2_sgpr3, 0, 4095, 0, 0, implicit $exec :: (store (s8), addrspace 5)
261 ; GFX9-LABEL: name: function_store_private_s32_to_1_fi_offset_4095
262 ; GFX9: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
263 ; GFX9-NEXT: BUFFER_STORE_BYTE_OFFEN [[V_MOV_B32_e32_]], %stack.0, $sgpr0_sgpr1_sgpr2_sgpr3, 0, 4095, 0, 0, implicit $exec :: (store (s8), addrspace 5)
264 ; GFX11-LABEL: name: function_store_private_s32_to_1_fi_offset_4095
265 ; GFX11: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
266 ; GFX11-NEXT: SCRATCH_STORE_BYTE_SADDR [[V_MOV_B32_e32_]], %stack.0, 4095, 0, implicit $exec, implicit $flat_scr :: (store (s8), addrspace 5)
267 %0:vgpr(p5) = G_FRAME_INDEX %stack.0
268 %1:vgpr(s32) = G_CONSTANT i32 4095
269 %2:vgpr(p5) = G_PTR_ADD %0, %1
270 %3:vgpr(s32) = G_CONSTANT i32 0
271 G_STORE %3, %2 :: (store (s8), align 1, addrspace 5)
277 name: function_store_private_s32_to_1_constant_4095
279 regBankSelected: true
280 tracksRegLiveness: true
282 isEntryFunction: false
283 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
284 stackPtrOffsetReg: $sgpr32
286 - { id: 0, size: 4096, alignment: 4 }
291 ; GFX6-LABEL: name: function_store_private_s32_to_1_constant_4095
292 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
293 ; GFX6-NEXT: BUFFER_STORE_BYTE_OFFSET [[V_MOV_B32_e32_]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 4095, 0, 0, implicit $exec :: (store (s8), addrspace 5)
294 ; GFX9-LABEL: name: function_store_private_s32_to_1_constant_4095
295 ; GFX9: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
296 ; GFX9-NEXT: BUFFER_STORE_BYTE_OFFSET [[V_MOV_B32_e32_]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 4095, 0, 0, implicit $exec :: (store (s8), addrspace 5)
297 ; GFX11-LABEL: name: function_store_private_s32_to_1_constant_4095
298 ; GFX11: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4095, implicit $exec
299 ; GFX11-NEXT: [[V_MOV_B32_e32_1:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
300 ; GFX11-NEXT: SCRATCH_STORE_BYTE [[V_MOV_B32_e32_1]], [[V_MOV_B32_e32_]], 0, 0, implicit $exec, implicit $flat_scr :: (store (s8), addrspace 5)
301 %0:vgpr(p5) = G_CONSTANT i32 4095
302 %1:vgpr(s32) = G_CONSTANT i32 0
303 G_STORE %1, %0 :: (store (s8), align 1, addrspace 5)
309 name: function_store_private_s32_to_1_constant_4096
311 regBankSelected: true
312 tracksRegLiveness: true
314 isEntryFunction: false
315 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
316 stackPtrOffsetReg: $sgpr32
318 - { id: 0, size: 4096, alignment: 4 }
323 ; GFX6-LABEL: name: function_store_private_s32_to_1_constant_4096
324 ; GFX6: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
325 ; GFX6-NEXT: [[V_MOV_B32_e32_1:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4096, implicit $exec
326 ; GFX6-NEXT: BUFFER_STORE_BYTE_OFFEN [[V_MOV_B32_e32_]], [[V_MOV_B32_e32_1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s8), addrspace 5)
327 ; GFX9-LABEL: name: function_store_private_s32_to_1_constant_4096
328 ; GFX9: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
329 ; GFX9-NEXT: [[V_MOV_B32_e32_1:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4096, implicit $exec
330 ; GFX9-NEXT: BUFFER_STORE_BYTE_OFFEN [[V_MOV_B32_e32_]], [[V_MOV_B32_e32_1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s8), addrspace 5)
331 ; GFX11-LABEL: name: function_store_private_s32_to_1_constant_4096
332 ; GFX11: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4096, implicit $exec
333 ; GFX11-NEXT: [[V_MOV_B32_e32_1:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
334 ; GFX11-NEXT: SCRATCH_STORE_BYTE [[V_MOV_B32_e32_1]], [[V_MOV_B32_e32_]], 0, 0, implicit $exec, implicit $flat_scr :: (store (s8), addrspace 5)
335 %0:vgpr(p5) = G_CONSTANT i32 4096
336 %1:vgpr(s32) = G_CONSTANT i32 0
337 G_STORE %1, %0 :: (store (s8), align 1, addrspace 5)
343 name: kernel_store_private_s32_to_4
345 regBankSelected: true
346 tracksRegLiveness: true
348 isEntryFunction: true
349 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
353 liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
355 ; GFX6-LABEL: name: kernel_store_private_s32_to_4
356 ; GFX6: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
358 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
359 ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
360 ; GFX6-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s32), addrspace 5)
361 ; GFX9-LABEL: name: kernel_store_private_s32_to_4
362 ; GFX9: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
364 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
365 ; GFX9-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
366 ; GFX9-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s32), addrspace 5)
367 ; GFX11-LABEL: name: kernel_store_private_s32_to_4
368 ; GFX11: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
370 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
371 ; GFX11-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
372 ; GFX11-NEXT: SCRATCH_STORE_DWORD [[COPY]], [[COPY1]], 0, 0, implicit $exec, implicit $flat_scr :: (store (s32), addrspace 5)
373 %0:vgpr(s32) = COPY $vgpr0
374 %1:vgpr(p5) = COPY $vgpr1
375 G_STORE %0, %1 :: (store (s32), align 4, addrspace 5)
381 name: kernel_store_private_s32_to_2
383 regBankSelected: true
384 tracksRegLiveness: true
386 isEntryFunction: true
387 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
391 liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
393 ; GFX6-LABEL: name: kernel_store_private_s32_to_2
394 ; GFX6: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
396 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
397 ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
398 ; GFX6-NEXT: BUFFER_STORE_SHORT_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s16), addrspace 5)
399 ; GFX9-LABEL: name: kernel_store_private_s32_to_2
400 ; GFX9: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
402 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
403 ; GFX9-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
404 ; GFX9-NEXT: BUFFER_STORE_SHORT_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s16), addrspace 5)
405 ; GFX11-LABEL: name: kernel_store_private_s32_to_2
406 ; GFX11: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
408 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
409 ; GFX11-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
410 ; GFX11-NEXT: SCRATCH_STORE_SHORT [[COPY]], [[COPY1]], 0, 0, implicit $exec, implicit $flat_scr :: (store (s16), addrspace 5)
411 %0:vgpr(s32) = COPY $vgpr0
412 %1:vgpr(p5) = COPY $vgpr1
413 G_STORE %0, %1 :: (store (s16), align 2, addrspace 5)
419 name: kernel_store_private_s32_to_1
421 regBankSelected: true
422 tracksRegLiveness: true
424 isEntryFunction: true
425 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
429 liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
431 ; GFX6-LABEL: name: kernel_store_private_s32_to_1
432 ; GFX6: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
434 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
435 ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
436 ; GFX6-NEXT: BUFFER_STORE_BYTE_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s8), addrspace 5)
437 ; GFX9-LABEL: name: kernel_store_private_s32_to_1
438 ; GFX9: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
440 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
441 ; GFX9-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
442 ; GFX9-NEXT: BUFFER_STORE_BYTE_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s8), addrspace 5)
443 ; GFX11-LABEL: name: kernel_store_private_s32_to_1
444 ; GFX11: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
446 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
447 ; GFX11-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
448 ; GFX11-NEXT: SCRATCH_STORE_BYTE [[COPY]], [[COPY1]], 0, 0, implicit $exec, implicit $flat_scr :: (store (s8), addrspace 5)
449 %0:vgpr(s32) = COPY $vgpr0
450 %1:vgpr(p5) = COPY $vgpr1
451 G_STORE %0, %1 :: (store (s8), align 1, addrspace 5)
457 name: kernel_store_private_v2s16
459 regBankSelected: true
460 tracksRegLiveness: true
462 isEntryFunction: true
463 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
467 liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
470 ; GFX6-LABEL: name: kernel_store_private_v2s16
471 ; GFX6: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
473 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
474 ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
475 ; GFX6-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (<2 x s16>), addrspace 5)
476 ; GFX9-LABEL: name: kernel_store_private_v2s16
477 ; GFX9: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
479 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
480 ; GFX9-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
481 ; GFX9-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (<2 x s16>), addrspace 5)
482 ; GFX11-LABEL: name: kernel_store_private_v2s16
483 ; GFX11: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
485 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
486 ; GFX11-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
487 ; GFX11-NEXT: SCRATCH_STORE_DWORD [[COPY]], [[COPY1]], 0, 0, implicit $exec, implicit $flat_scr :: (store (<2 x s16>), addrspace 5)
488 %0:vgpr(<2 x s16>) = COPY $vgpr0
489 %1:vgpr(p5) = COPY $vgpr1
490 G_STORE %0, %1 :: (store (<2 x s16>), align 4, addrspace 5)
496 name: kernel_store_private_p3
498 regBankSelected: true
499 tracksRegLiveness: true
501 isEntryFunction: true
502 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
506 liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
508 ; GFX6-LABEL: name: kernel_store_private_p3
509 ; GFX6: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
511 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
512 ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
513 ; GFX6-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (p3), addrspace 5)
514 ; GFX9-LABEL: name: kernel_store_private_p3
515 ; GFX9: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
517 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
518 ; GFX9-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
519 ; GFX9-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (p3), addrspace 5)
520 ; GFX11-LABEL: name: kernel_store_private_p3
521 ; GFX11: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
523 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
524 ; GFX11-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
525 ; GFX11-NEXT: SCRATCH_STORE_DWORD [[COPY]], [[COPY1]], 0, 0, implicit $exec, implicit $flat_scr :: (store (p3), addrspace 5)
526 %0:vgpr(p3) = COPY $vgpr0
527 %1:vgpr(p5) = COPY $vgpr1
528 G_STORE %0, %1 :: (store (p3), align 4, addrspace 5)
534 name: kernel_store_private_p5
536 regBankSelected: true
537 tracksRegLiveness: true
539 isEntryFunction: true
540 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
544 liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
546 ; GFX6-LABEL: name: kernel_store_private_p5
547 ; GFX6: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
549 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
550 ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
551 ; GFX6-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (p5), addrspace 5)
552 ; GFX9-LABEL: name: kernel_store_private_p5
553 ; GFX9: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
555 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
556 ; GFX9-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
557 ; GFX9-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[COPY1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (p5), addrspace 5)
558 ; GFX11-LABEL: name: kernel_store_private_p5
559 ; GFX11: liveins: $vgpr0, $vgpr1, $sgpr0_sgpr1_sgpr2_sgpr3
561 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
562 ; GFX11-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY $vgpr1
563 ; GFX11-NEXT: SCRATCH_STORE_DWORD [[COPY]], [[COPY1]], 0, 0, implicit $exec, implicit $flat_scr :: (store (p5), addrspace 5)
564 %0:vgpr(p5) = COPY $vgpr0
565 %1:vgpr(p5) = COPY $vgpr1
566 G_STORE %0, %1 :: (store (p5), align 4, addrspace 5)
572 name: kernel_store_private_s32_to_1_fi_offset_4095
574 regBankSelected: true
575 tracksRegLiveness: true
577 isEntryFunction: true
578 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
580 - { id: 0, size: 4096, alignment: 4 }
584 liveins: $sgpr0_sgpr1_sgpr2_sgpr3
586 ; GFX6-LABEL: name: kernel_store_private_s32_to_1_fi_offset_4095
587 ; GFX6: liveins: $sgpr0_sgpr1_sgpr2_sgpr3
589 ; GFX6-NEXT: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
590 ; GFX6-NEXT: BUFFER_STORE_BYTE_OFFEN [[V_MOV_B32_e32_]], %stack.0, $sgpr0_sgpr1_sgpr2_sgpr3, 0, 4095, 0, 0, implicit $exec :: (store (s8), addrspace 5)
591 ; GFX9-LABEL: name: kernel_store_private_s32_to_1_fi_offset_4095
592 ; GFX9: liveins: $sgpr0_sgpr1_sgpr2_sgpr3
594 ; GFX9-NEXT: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
595 ; GFX9-NEXT: BUFFER_STORE_BYTE_OFFEN [[V_MOV_B32_e32_]], %stack.0, $sgpr0_sgpr1_sgpr2_sgpr3, 0, 4095, 0, 0, implicit $exec :: (store (s8), addrspace 5)
596 ; GFX11-LABEL: name: kernel_store_private_s32_to_1_fi_offset_4095
597 ; GFX11: liveins: $sgpr0_sgpr1_sgpr2_sgpr3
599 ; GFX11-NEXT: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
600 ; GFX11-NEXT: SCRATCH_STORE_BYTE_SADDR [[V_MOV_B32_e32_]], %stack.0, 4095, 0, implicit $exec, implicit $flat_scr :: (store (s8), addrspace 5)
601 %0:vgpr(p5) = G_FRAME_INDEX %stack.0
602 %1:vgpr(s32) = G_CONSTANT i32 4095
603 %2:vgpr(p5) = G_PTR_ADD %0, %1
604 %3:vgpr(s32) = G_CONSTANT i32 0
605 G_STORE %3, %2 :: (store (s8), align 1, addrspace 5)
611 name: kernel_store_private_s32_to_1_constant_4095
613 regBankSelected: true
614 tracksRegLiveness: true
616 isEntryFunction: true
617 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
619 - { id: 0, size: 4096, alignment: 4 }
623 liveins: $sgpr0_sgpr1_sgpr2_sgpr3
625 ; GFX6-LABEL: name: kernel_store_private_s32_to_1_constant_4095
626 ; GFX6: liveins: $sgpr0_sgpr1_sgpr2_sgpr3
628 ; GFX6-NEXT: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
629 ; GFX6-NEXT: BUFFER_STORE_BYTE_OFFSET [[V_MOV_B32_e32_]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 4095, 0, 0, implicit $exec :: (store (s8), addrspace 5)
630 ; GFX9-LABEL: name: kernel_store_private_s32_to_1_constant_4095
631 ; GFX9: liveins: $sgpr0_sgpr1_sgpr2_sgpr3
633 ; GFX9-NEXT: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
634 ; GFX9-NEXT: BUFFER_STORE_BYTE_OFFSET [[V_MOV_B32_e32_]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 4095, 0, 0, implicit $exec :: (store (s8), addrspace 5)
635 ; GFX11-LABEL: name: kernel_store_private_s32_to_1_constant_4095
636 ; GFX11: liveins: $sgpr0_sgpr1_sgpr2_sgpr3
638 ; GFX11-NEXT: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4095, implicit $exec
639 ; GFX11-NEXT: [[V_MOV_B32_e32_1:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
640 ; GFX11-NEXT: SCRATCH_STORE_BYTE [[V_MOV_B32_e32_1]], [[V_MOV_B32_e32_]], 0, 0, implicit $exec, implicit $flat_scr :: (store (s8), addrspace 5)
641 %0:vgpr(p5) = G_CONSTANT i32 4095
642 %1:vgpr(s32) = G_CONSTANT i32 0
643 G_STORE %1, %0 :: (store (s8), align 1, addrspace 5)
649 name: kernel_store_private_s32_to_1_constant_4096
651 regBankSelected: true
652 tracksRegLiveness: true
654 isEntryFunction: true
655 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
657 - { id: 0, size: 4096, alignment: 4 }
661 liveins: $sgpr0_sgpr1_sgpr2_sgpr3
663 ; GFX6-LABEL: name: kernel_store_private_s32_to_1_constant_4096
664 ; GFX6: liveins: $sgpr0_sgpr1_sgpr2_sgpr3
666 ; GFX6-NEXT: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
667 ; GFX6-NEXT: [[V_MOV_B32_e32_1:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4096, implicit $exec
668 ; GFX6-NEXT: BUFFER_STORE_BYTE_OFFEN [[V_MOV_B32_e32_]], [[V_MOV_B32_e32_1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s8), addrspace 5)
669 ; GFX9-LABEL: name: kernel_store_private_s32_to_1_constant_4096
670 ; GFX9: liveins: $sgpr0_sgpr1_sgpr2_sgpr3
672 ; GFX9-NEXT: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
673 ; GFX9-NEXT: [[V_MOV_B32_e32_1:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4096, implicit $exec
674 ; GFX9-NEXT: BUFFER_STORE_BYTE_OFFEN [[V_MOV_B32_e32_]], [[V_MOV_B32_e32_1]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s8), addrspace 5)
675 ; GFX11-LABEL: name: kernel_store_private_s32_to_1_constant_4096
676 ; GFX11: liveins: $sgpr0_sgpr1_sgpr2_sgpr3
678 ; GFX11-NEXT: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4096, implicit $exec
679 ; GFX11-NEXT: [[V_MOV_B32_e32_1:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 0, implicit $exec
680 ; GFX11-NEXT: SCRATCH_STORE_BYTE [[V_MOV_B32_e32_1]], [[V_MOV_B32_e32_]], 0, 0, implicit $exec, implicit $flat_scr :: (store (s8), addrspace 5)
681 %0:vgpr(p5) = G_CONSTANT i32 4096
682 %1:vgpr(s32) = G_CONSTANT i32 0
683 G_STORE %1, %0 :: (store (s8), align 1, addrspace 5)
688 name: function_store_private_s32_to_4_wave_address
690 regBankSelected: true
691 tracksRegLiveness: true
693 isEntryFunction: false
694 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
695 stackPtrOffsetReg: $sgpr32
699 liveins: $vgpr0, $vgpr1
701 ; GFX6-LABEL: name: function_store_private_s32_to_4_wave_address
702 ; GFX6: liveins: $vgpr0, $vgpr1
704 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
705 ; GFX6-NEXT: BUFFER_STORE_DWORD_OFFSET [[COPY]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr32, 0, 0, 0, implicit $exec :: (store (s32), addrspace 5)
706 ; GFX9-LABEL: name: function_store_private_s32_to_4_wave_address
707 ; GFX9: liveins: $vgpr0, $vgpr1
709 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
710 ; GFX9-NEXT: BUFFER_STORE_DWORD_OFFSET [[COPY]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr32, 0, 0, 0, implicit $exec :: (store (s32), addrspace 5)
711 ; GFX11-LABEL: name: function_store_private_s32_to_4_wave_address
712 ; GFX11: liveins: $vgpr0, $vgpr1
714 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
715 ; GFX11-NEXT: [[V_LSHRREV_B32_e64_:%[0-9]+]]:vgpr_32 = V_LSHRREV_B32_e64 5, $sgpr32, implicit $exec
716 ; GFX11-NEXT: SCRATCH_STORE_DWORD [[COPY]], [[V_LSHRREV_B32_e64_]], 0, 0, implicit $exec, implicit $flat_scr :: (store (s32), addrspace 5)
717 %0:vgpr(s32) = COPY $vgpr0
718 %1:vgpr(p5) = G_AMDGPU_WAVE_ADDRESS $sgpr32
719 G_STORE %0, %1 :: (store (s32), align 4, addrspace 5)
723 # Has regbank copy of constant
725 name: function_store_private_s32_to_4_wave_address_offset_copy_constant_4095
727 regBankSelected: true
728 tracksRegLiveness: true
730 isEntryFunction: false
731 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
732 stackPtrOffsetReg: $sgpr32
736 liveins: $vgpr0, $vgpr1
738 ; GFX6-LABEL: name: function_store_private_s32_to_4_wave_address_offset_copy_constant_4095
739 ; GFX6: liveins: $vgpr0, $vgpr1
741 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
742 ; GFX6-NEXT: BUFFER_STORE_DWORD_OFFSET [[COPY]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr32, 4095, 0, 0, implicit $exec :: (store (s32), addrspace 5)
743 ; GFX9-LABEL: name: function_store_private_s32_to_4_wave_address_offset_copy_constant_4095
744 ; GFX9: liveins: $vgpr0, $vgpr1
746 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
747 ; GFX9-NEXT: BUFFER_STORE_DWORD_OFFSET [[COPY]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr32, 4095, 0, 0, implicit $exec :: (store (s32), addrspace 5)
748 ; GFX11-LABEL: name: function_store_private_s32_to_4_wave_address_offset_copy_constant_4095
749 ; GFX11: liveins: $vgpr0, $vgpr1
751 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
752 ; GFX11-NEXT: [[V_LSHRREV_B32_e64_:%[0-9]+]]:vgpr_32 = V_LSHRREV_B32_e64 5, $sgpr32, implicit $exec
753 ; GFX11-NEXT: [[S_MOV_B32_:%[0-9]+]]:sreg_32 = S_MOV_B32 4095
754 ; GFX11-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY [[S_MOV_B32_]]
755 ; GFX11-NEXT: [[V_ADD_U32_e64_:%[0-9]+]]:vgpr_32 = V_ADD_U32_e64 [[V_LSHRREV_B32_e64_]], [[COPY1]], 0, implicit $exec
756 ; GFX11-NEXT: SCRATCH_STORE_DWORD [[COPY]], [[V_ADD_U32_e64_]], 0, 0, implicit $exec, implicit $flat_scr :: (store (s32), addrspace 5)
757 %0:vgpr(s32) = COPY $vgpr0
758 %1:vgpr(p5) = G_AMDGPU_WAVE_ADDRESS $sgpr32
759 %2:sgpr(s32) = G_CONSTANT i32 4095
760 %3:vgpr(s32) = COPY %2
761 %4:vgpr(p5) = G_PTR_ADD %1, %3
762 G_STORE %0, %4 :: (store (s32), align 4, addrspace 5)
767 name: function_store_private_s32_to_4_wave_address_offset_4095
769 regBankSelected: true
770 tracksRegLiveness: true
772 isEntryFunction: false
773 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
774 stackPtrOffsetReg: $sgpr32
778 liveins: $vgpr0, $vgpr1
780 ; GFX6-LABEL: name: function_store_private_s32_to_4_wave_address_offset_4095
781 ; GFX6: liveins: $vgpr0, $vgpr1
783 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
784 ; GFX6-NEXT: BUFFER_STORE_DWORD_OFFSET [[COPY]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr32, 4095, 0, 0, implicit $exec :: (store (s32), addrspace 5)
786 ; GFX9-LABEL: name: function_store_private_s32_to_4_wave_address_offset_4095
787 ; GFX9: liveins: $vgpr0, $vgpr1
789 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
790 ; GFX9-NEXT: BUFFER_STORE_DWORD_OFFSET [[COPY]], $sgpr0_sgpr1_sgpr2_sgpr3, $sgpr32, 4095, 0, 0, implicit $exec :: (store (s32), addrspace 5)
792 ; GFX11-LABEL: name: function_store_private_s32_to_4_wave_address_offset_4095
793 ; GFX11: liveins: $vgpr0, $vgpr1
795 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
796 ; GFX11-NEXT: [[V_LSHRREV_B32_e64_:%[0-9]+]]:vgpr_32 = V_LSHRREV_B32_e64 5, $sgpr32, implicit $exec
797 ; GFX11-NEXT: [[V_MOV_B32_e32_:%[0-9]+]]:vgpr_32 = V_MOV_B32_e32 4095, implicit $exec
798 ; GFX11-NEXT: [[V_ADD_U32_e64_:%[0-9]+]]:vgpr_32 = V_ADD_U32_e64 [[V_LSHRREV_B32_e64_]], [[V_MOV_B32_e32_]], 0, implicit $exec
799 ; GFX11-NEXT: SCRATCH_STORE_DWORD [[COPY]], [[V_ADD_U32_e64_]], 0, 0, implicit $exec, implicit $flat_scr :: (store (s32), addrspace 5)
800 %0:vgpr(s32) = COPY $vgpr0
801 %1:vgpr(p5) = G_AMDGPU_WAVE_ADDRESS $sgpr32
802 %2:vgpr(s32) = G_CONSTANT i32 4095
803 %3:vgpr(p5) = G_PTR_ADD %1, %2
804 G_STORE %0, %3 :: (store (s32), align 4, addrspace 5)
809 name: function_store_private_s32_to_4_wave_address_offset_copy_constant_4096
811 regBankSelected: true
812 tracksRegLiveness: true
814 isEntryFunction: false
815 scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3
816 stackPtrOffsetReg: $sgpr32
820 liveins: $vgpr0, $vgpr1
822 ; GFX6-LABEL: name: function_store_private_s32_to_4_wave_address_offset_copy_constant_4096
823 ; GFX6: liveins: $vgpr0, $vgpr1
825 ; GFX6-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
826 ; GFX6-NEXT: [[V_LSHRREV_B32_e64_:%[0-9]+]]:vgpr_32 = V_LSHRREV_B32_e64 6, $sgpr32, implicit $exec
827 ; GFX6-NEXT: [[S_MOV_B32_:%[0-9]+]]:sreg_32 = S_MOV_B32 4096
828 ; GFX6-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY [[S_MOV_B32_]]
829 ; GFX6-NEXT: [[V_ADD_CO_U32_e64_:%[0-9]+]]:vgpr_32, dead [[V_ADD_CO_U32_e64_1:%[0-9]+]]:sreg_64_xexec = V_ADD_CO_U32_e64 [[V_LSHRREV_B32_e64_]], [[COPY1]], 0, implicit $exec
830 ; GFX6-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[V_ADD_CO_U32_e64_]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s32), addrspace 5)
832 ; GFX9-LABEL: name: function_store_private_s32_to_4_wave_address_offset_copy_constant_4096
833 ; GFX9: liveins: $vgpr0, $vgpr1
835 ; GFX9-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
836 ; GFX9-NEXT: [[V_LSHRREV_B32_e64_:%[0-9]+]]:vgpr_32 = V_LSHRREV_B32_e64 6, $sgpr32, implicit $exec
837 ; GFX9-NEXT: [[S_MOV_B32_:%[0-9]+]]:sreg_32 = S_MOV_B32 4096
838 ; GFX9-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY [[S_MOV_B32_]]
839 ; GFX9-NEXT: [[V_ADD_U32_e64_:%[0-9]+]]:vgpr_32 = V_ADD_U32_e64 [[V_LSHRREV_B32_e64_]], [[COPY1]], 0, implicit $exec
840 ; GFX9-NEXT: BUFFER_STORE_DWORD_OFFEN [[COPY]], [[V_ADD_U32_e64_]], $sgpr0_sgpr1_sgpr2_sgpr3, 0, 0, 0, 0, implicit $exec :: (store (s32), addrspace 5)
841 ; GFX11-LABEL: name: function_store_private_s32_to_4_wave_address_offset_copy_constant_4096
842 ; GFX11: liveins: $vgpr0, $vgpr1
844 ; GFX11-NEXT: [[COPY:%[0-9]+]]:vgpr_32 = COPY $vgpr0
845 ; GFX11-NEXT: [[V_LSHRREV_B32_e64_:%[0-9]+]]:vgpr_32 = V_LSHRREV_B32_e64 5, $sgpr32, implicit $exec
846 ; GFX11-NEXT: [[S_MOV_B32_:%[0-9]+]]:sreg_32 = S_MOV_B32 4096
847 ; GFX11-NEXT: [[COPY1:%[0-9]+]]:vgpr_32 = COPY [[S_MOV_B32_]]
848 ; GFX11-NEXT: [[V_ADD_U32_e64_:%[0-9]+]]:vgpr_32 = V_ADD_U32_e64 [[V_LSHRREV_B32_e64_]], [[COPY1]], 0, implicit $exec
849 ; GFX11-NEXT: SCRATCH_STORE_DWORD [[COPY]], [[V_ADD_U32_e64_]], 0, 0, implicit $exec, implicit $flat_scr :: (store (s32), addrspace 5)
850 %0:vgpr(s32) = COPY $vgpr0
851 %1:vgpr(p5) = G_AMDGPU_WAVE_ADDRESS $sgpr32
852 %2:sgpr(s32) = G_CONSTANT i32 4096
853 %3:vgpr(s32) = COPY %2
854 %4:vgpr(p5) = G_PTR_ADD %1, %3
855 G_STORE %0, %4 :: (store (s32), align 4, addrspace 5)