llvm/llvm/test/CodeGen/AMDGPU/copy-vgpr-clobber-spill-vgpr.mir

# NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
# RUN: llc -mtriple=amdgcn -mcpu=gfx908 -verify-machineinstrs -start-before=prologepilog %s -o - | FileCheck --check-prefix=GFX908 %s
# RUN: llc -mtriple=amdgcn -mcpu=gfx90a -verify-machineinstrs -start-before=prologepilog %s -o - | FileCheck --check-prefix=GFX90A %s

--- |

  define amdgpu_kernel void @test_spill() #0 {
  ; GFX908-LABEL: test_spill:
  ; GFX908:       ; %bb.0:
  ; GFX908-NEXT:    ; implicit-def: $agpr96_agpr97_agpr98_agpr99_agpr100_agpr101_agpr102_agpr103_agpr104_agpr105_agpr106_agpr107_agpr108_agpr109_agpr110_agpr111
  ; GFX908-NEXT:    s_waitcnt vmcnt(0) expcnt(0) lgkmcnt(0)
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a96
  ; GFX908-NEXT:    ; implicit-def: $vgpr0
  ; GFX908-NEXT:    ; implicit-def: $vgpr1
  ; GFX908-NEXT:    ; implicit-def: $vgpr2
  ; GFX908-NEXT:    ; implicit-def: $vgpr3
  ; GFX908-NEXT:    ; implicit-def: $vgpr4
  ; GFX908-NEXT:    ; implicit-def: $vgpr5
  ; GFX908-NEXT:    ; implicit-def: $vgpr6
  ; GFX908-NEXT:    ; implicit-def: $vgpr7
  ; GFX908-NEXT:    ; implicit-def: $vgpr8
  ; GFX908-NEXT:    ; implicit-def: $vgpr9
  ; GFX908-NEXT:    ; implicit-def: $vgpr10
  ; GFX908-NEXT:    ; implicit-def: $vgpr11
  ; GFX908-NEXT:    ; implicit-def: $vgpr12
  ; GFX908-NEXT:    ; implicit-def: $vgpr13
  ; GFX908-NEXT:    ; implicit-def: $vgpr14
  ; GFX908-NEXT:    ; implicit-def: $vgpr15
  ; GFX908-NEXT:    ; implicit-def: $vgpr16
  ; GFX908-NEXT:    ; implicit-def: $vgpr17
  ; GFX908-NEXT:    ; implicit-def: $vgpr18
  ; GFX908-NEXT:    ; implicit-def: $vgpr19
  ; GFX908-NEXT:    ; implicit-def: $vgpr20
  ; GFX908-NEXT:    ; implicit-def: $vgpr21
  ; GFX908-NEXT:    ; implicit-def: $vgpr22
  ; GFX908-NEXT:    ; implicit-def: $vgpr23
  ; GFX908-NEXT:    ; implicit-def: $vgpr24
  ; GFX908-NEXT:    ; implicit-def: $vgpr25
  ; GFX908-NEXT:    ; implicit-def: $vgpr26
  ; GFX908-NEXT:    ; implicit-def: $vgpr27
  ; GFX908-NEXT:    ; implicit-def: $vgpr28
  ; GFX908-NEXT:    ; implicit-def: $vgpr29
  ; GFX908-NEXT:    ; implicit-def: $vgpr30
  ; GFX908-NEXT:    ; implicit-def: $vgpr31
  ; GFX908-NEXT:    ; implicit-def: $vgpr32
  ; GFX908-NEXT:    ; implicit-def: $vgpr33
  ; GFX908-NEXT:    ; implicit-def: $vgpr34
  ; GFX908-NEXT:    ; implicit-def: $vgpr35
  ; GFX908-NEXT:    ; implicit-def: $vgpr36
  ; GFX908-NEXT:    ; implicit-def: $vgpr37
  ; GFX908-NEXT:    ; implicit-def: $vgpr38
  ; GFX908-NEXT:    ; implicit-def: $vgpr39
  ; GFX908-NEXT:    ; implicit-def: $vgpr40
  ; GFX908-NEXT:    ; implicit-def: $vgpr41
  ; GFX908-NEXT:    ; implicit-def: $vgpr42
  ; GFX908-NEXT:    ; implicit-def: $vgpr43
  ; GFX908-NEXT:    ; implicit-def: $vgpr44
  ; GFX908-NEXT:    ; implicit-def: $vgpr45
  ; GFX908-NEXT:    ; implicit-def: $vgpr46
  ; GFX908-NEXT:    ; implicit-def: $vgpr47
  ; GFX908-NEXT:    ; implicit-def: $vgpr48
  ; GFX908-NEXT:    ; implicit-def: $vgpr49
  ; GFX908-NEXT:    ; implicit-def: $vgpr50
  ; GFX908-NEXT:    ; implicit-def: $vgpr51
  ; GFX908-NEXT:    ; implicit-def: $vgpr52
  ; GFX908-NEXT:    ; implicit-def: $vgpr53
  ; GFX908-NEXT:    ; implicit-def: $vgpr54
  ; GFX908-NEXT:    ; implicit-def: $vgpr55
  ; GFX908-NEXT:    ; implicit-def: $vgpr56
  ; GFX908-NEXT:    ; implicit-def: $vgpr57
  ; GFX908-NEXT:    ; implicit-def: $vgpr58
  ; GFX908-NEXT:    ; implicit-def: $vgpr59
  ; GFX908-NEXT:    ; implicit-def: $vgpr60
  ; GFX908-NEXT:    ; implicit-def: $vgpr61
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a64, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a97
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a65, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a98
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a66, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a99
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a67, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a100
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a68, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a101
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a69, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a102
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a70, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a103
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a71, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a104
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a72, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a105
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a73, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a106
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a74, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a107
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a75, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a108
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a76, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a109
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a77, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a110
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a78, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a111
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    v_accvgpr_write_b32 a79, v63
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a96 ; Reload Reuse
  ; GFX908-NEXT:    v_accvgpr_read_b32 v62, a111 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 0
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a97 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:4 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a98 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:8 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a99 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:12 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a100 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:16 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a101 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:20 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a102 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:24 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a103 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:28 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a104 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:32 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a105 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:36 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a106 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:40 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a107 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:44 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a108 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:48 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a109 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:52 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a110 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:56 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a96 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:64 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a97 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:68 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a98 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:72 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a99 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:76 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a100 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:80 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a101 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:84 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a102 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:88 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a103 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:92 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a104 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:96 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a105 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:100 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a106 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:104 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a107 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:108 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a108 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:112 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a109 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:116 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a110 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:120 ; 4-byte Folded Spill
  ; GFX908-NEXT:    v_accvgpr_read_b32 v63, a111 ; Reload Reuse
  ; GFX908-NEXT:    s_nop 1
  ; GFX908-NEXT:    buffer_store_dword v63, off, s[0:3], s32 offset:124 ; 4-byte Folded Spill
  ; GFX908-NEXT:    s_nop 0
  ;
  ; GFX90A-LABEL: test_spill:
  ; GFX90A:       ; %bb.0:
  ; GFX90A-NEXT:    ; implicit-def: $agpr96_agpr97_agpr98_agpr99_agpr100_agpr101_agpr102_agpr103_agpr104_agpr105_agpr106_agpr107_agpr108_agpr109_agpr110_agpr111
  ; GFX90A-NEXT:    s_waitcnt vmcnt(0) expcnt(0) lgkmcnt(0)
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a64, a96
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a65, a97
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a66, a98
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a67, a99
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a68, a100
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a69, a101
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a70, a102
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a71, a103
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a72, a104
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a73, a105
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a74, a106
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a75, a107
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a76, a108
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a77, a109
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a78, a110
  ; GFX90A-NEXT:    v_accvgpr_mov_b32 a79, a111
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v77, a96 ; Reload Reuse
  ; GFX90A-NEXT:    ; implicit-def: $vgpr0
  ; GFX90A-NEXT:    ; implicit-def: $vgpr1
  ; GFX90A-NEXT:    ; implicit-def: $vgpr2
  ; GFX90A-NEXT:    ; implicit-def: $vgpr3
  ; GFX90A-NEXT:    ; implicit-def: $vgpr4
  ; GFX90A-NEXT:    ; implicit-def: $vgpr5
  ; GFX90A-NEXT:    ; implicit-def: $vgpr6
  ; GFX90A-NEXT:    ; implicit-def: $vgpr7
  ; GFX90A-NEXT:    ; implicit-def: $vgpr8
  ; GFX90A-NEXT:    ; implicit-def: $vgpr9
  ; GFX90A-NEXT:    ; implicit-def: $vgpr10
  ; GFX90A-NEXT:    ; implicit-def: $vgpr11
  ; GFX90A-NEXT:    ; implicit-def: $vgpr12
  ; GFX90A-NEXT:    ; implicit-def: $vgpr13
  ; GFX90A-NEXT:    ; implicit-def: $vgpr14
  ; GFX90A-NEXT:    ; implicit-def: $vgpr15
  ; GFX90A-NEXT:    ; implicit-def: $vgpr16
  ; GFX90A-NEXT:    ; implicit-def: $vgpr17
  ; GFX90A-NEXT:    ; implicit-def: $vgpr18
  ; GFX90A-NEXT:    ; implicit-def: $vgpr19
  ; GFX90A-NEXT:    ; implicit-def: $vgpr20
  ; GFX90A-NEXT:    ; implicit-def: $vgpr21
  ; GFX90A-NEXT:    ; implicit-def: $vgpr22
  ; GFX90A-NEXT:    ; implicit-def: $vgpr23
  ; GFX90A-NEXT:    ; implicit-def: $vgpr24
  ; GFX90A-NEXT:    ; implicit-def: $vgpr25
  ; GFX90A-NEXT:    ; implicit-def: $vgpr26
  ; GFX90A-NEXT:    ; implicit-def: $vgpr27
  ; GFX90A-NEXT:    ; implicit-def: $vgpr28
  ; GFX90A-NEXT:    ; implicit-def: $vgpr29
  ; GFX90A-NEXT:    ; implicit-def: $vgpr30
  ; GFX90A-NEXT:    ; implicit-def: $vgpr31
  ; GFX90A-NEXT:    ; implicit-def: $vgpr32
  ; GFX90A-NEXT:    ; implicit-def: $vgpr33
  ; GFX90A-NEXT:    ; implicit-def: $vgpr34
  ; GFX90A-NEXT:    ; implicit-def: $vgpr35
  ; GFX90A-NEXT:    ; implicit-def: $vgpr36
  ; GFX90A-NEXT:    ; implicit-def: $vgpr37
  ; GFX90A-NEXT:    ; implicit-def: $vgpr38
  ; GFX90A-NEXT:    ; implicit-def: $vgpr39
  ; GFX90A-NEXT:    ; implicit-def: $vgpr40
  ; GFX90A-NEXT:    ; implicit-def: $vgpr41
  ; GFX90A-NEXT:    ; implicit-def: $vgpr42
  ; GFX90A-NEXT:    ; implicit-def: $vgpr43
  ; GFX90A-NEXT:    ; implicit-def: $vgpr44
  ; GFX90A-NEXT:    ; implicit-def: $vgpr45
  ; GFX90A-NEXT:    ; implicit-def: $vgpr46
  ; GFX90A-NEXT:    ; implicit-def: $vgpr47
  ; GFX90A-NEXT:    ; implicit-def: $vgpr48
  ; GFX90A-NEXT:    ; implicit-def: $vgpr49
  ; GFX90A-NEXT:    ; implicit-def: $vgpr50
  ; GFX90A-NEXT:    ; implicit-def: $vgpr51
  ; GFX90A-NEXT:    ; implicit-def: $vgpr52
  ; GFX90A-NEXT:    ; implicit-def: $vgpr53
  ; GFX90A-NEXT:    ; implicit-def: $vgpr54
  ; GFX90A-NEXT:    ; implicit-def: $vgpr55
  ; GFX90A-NEXT:    ; implicit-def: $vgpr56
  ; GFX90A-NEXT:    ; implicit-def: $vgpr57
  ; GFX90A-NEXT:    ; implicit-def: $vgpr58
  ; GFX90A-NEXT:    ; implicit-def: $vgpr59
  ; GFX90A-NEXT:    ; implicit-def: $vgpr60
  ; GFX90A-NEXT:    ; implicit-def: $vgpr61
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v76, a97 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v75, a98 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v74, a99 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v73, a100 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v72, a101 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v71, a102 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v70, a103 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v69, a104 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v68, a105 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v67, a106 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v66, a107 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v65, a108 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v64, a109 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v63, a110 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v62, a111 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v93, a96 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v92, a97 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v91, a98 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v90, a99 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v89, a100 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v88, a101 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v87, a102 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v86, a103 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v85, a104 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v84, a105 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v83, a106 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v82, a107 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v81, a108 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v80, a109 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v79, a110 ; Reload Reuse
  ; GFX90A-NEXT:    v_accvgpr_read_b32 v78, a111 ; Reload Reuse
  ; GFX90A-NEXT:    s_nop 0
    ret void
  }

  attributes #0 = { "amdgpu-waves-per-eu"="4,4" "amdgpu-no-agpr" }

...
---
name:            test_spill
tracksRegLiveness: true
stack:
  - { id: 0, name: '', type: spill-slot, offset: 0, size: 64, alignment: 4 }
  - { id: 1, name: '', type: spill-slot, offset: 0, size: 64, alignment: 4 }

machineFunctionInfo:
  scratchRSrcReg:  $sgpr0_sgpr1_sgpr2_sgpr3
  stackPtrOffsetReg: '$sgpr32'
  hasSpilledVGPRs: true
body:             |
  bb.0:
    $agpr96_agpr97_agpr98_agpr99_agpr100_agpr101_agpr102_agpr103_agpr104_agpr105_agpr106_agpr107_agpr108_agpr109_agpr110_agpr111 = IMPLICIT_DEF
    $vgpr0 = IMPLICIT_DEF
    $vgpr1 = IMPLICIT_DEF
    $vgpr2 = IMPLICIT_DEF
    $vgpr3 = IMPLICIT_DEF
    $vgpr4 = IMPLICIT_DEF
    $vgpr5 = IMPLICIT_DEF
    $vgpr6 = IMPLICIT_DEF
    $vgpr7 = IMPLICIT_DEF
    $vgpr8 = IMPLICIT_DEF
    $vgpr9 = IMPLICIT_DEF
    $vgpr10 = IMPLICIT_DEF
    $vgpr11 = IMPLICIT_DEF
    $vgpr12 = IMPLICIT_DEF
    $vgpr13 = IMPLICIT_DEF
    $vgpr14 = IMPLICIT_DEF
    $vgpr15 = IMPLICIT_DEF
    $vgpr16 = IMPLICIT_DEF
    $vgpr17 = IMPLICIT_DEF
    $vgpr18 = IMPLICIT_DEF
    $vgpr19 = IMPLICIT_DEF
    $vgpr20 = IMPLICIT_DEF
    $vgpr21 = IMPLICIT_DEF
    $vgpr22 = IMPLICIT_DEF
    $vgpr23 = IMPLICIT_DEF
    $vgpr24 = IMPLICIT_DEF
    $vgpr25 = IMPLICIT_DEF
    $vgpr26 = IMPLICIT_DEF
    $vgpr27 = IMPLICIT_DEF
    $vgpr28 = IMPLICIT_DEF
    $vgpr29 = IMPLICIT_DEF
    $vgpr30 = IMPLICIT_DEF
    $vgpr31 = IMPLICIT_DEF
    $vgpr32 = IMPLICIT_DEF
    $vgpr33 = IMPLICIT_DEF
    $vgpr34 = IMPLICIT_DEF
    $vgpr35 = IMPLICIT_DEF
    $vgpr36 = IMPLICIT_DEF
    $vgpr37 = IMPLICIT_DEF
    $vgpr38 = IMPLICIT_DEF
    $vgpr39 = IMPLICIT_DEF
    $vgpr40 = IMPLICIT_DEF
    $vgpr41 = IMPLICIT_DEF
    $vgpr42 = IMPLICIT_DEF
    $vgpr43 = IMPLICIT_DEF
    $vgpr44 = IMPLICIT_DEF
    $vgpr45 = IMPLICIT_DEF
    $vgpr46 = IMPLICIT_DEF
    $vgpr47 = IMPLICIT_DEF
    $vgpr48 = IMPLICIT_DEF
    $vgpr49 = IMPLICIT_DEF
    $vgpr50 = IMPLICIT_DEF
    $vgpr51 = IMPLICIT_DEF
    $vgpr52 = IMPLICIT_DEF
    $vgpr53 = IMPLICIT_DEF
    $vgpr54 = IMPLICIT_DEF
    $vgpr55 = IMPLICIT_DEF
    $vgpr56 = IMPLICIT_DEF
    $vgpr57 = IMPLICIT_DEF
    $vgpr58 = IMPLICIT_DEF
    $vgpr59 = IMPLICIT_DEF
    $vgpr60 = IMPLICIT_DEF
    $vgpr61 = IMPLICIT_DEF

    $agpr64_agpr65_agpr66_agpr67_agpr68_agpr69_agpr70_agpr71_agpr72_agpr73_agpr74_agpr75_agpr76_agpr77_agpr78_agpr79 = COPY $agpr96_agpr97_agpr98_agpr99_agpr100_agpr101_agpr102_agpr103_agpr104_agpr105_agpr106_agpr107_agpr108_agpr109_agpr110_agpr111, implicit $exec
    SI_SPILL_AV512_SAVE killed $agpr96_agpr97_agpr98_agpr99_agpr100_agpr101_agpr102_agpr103_agpr104_agpr105_agpr106_agpr107_agpr108_agpr109_agpr110_agpr111, %stack.0, $sgpr32, 0, implicit $exec :: (store (s512) into %stack.0, align 4, addrspace 5)
    SI_SPILL_AV512_SAVE $agpr96_agpr97_agpr98_agpr99_agpr100_agpr101_agpr102_agpr103_agpr104_agpr105_agpr106_agpr107_agpr108_agpr109_agpr110_agpr111, %stack.1, $sgpr32, 0, implicit $exec :: (store (s512) into %stack.0, align 4, addrspace 5)
    S_NOP 0, implicit $vgpr0, implicit $vgpr1, implicit $vgpr2, implicit $vgpr3, implicit $vgpr4, implicit $vgpr5, implicit $vgpr6, implicit $vgpr7, implicit $vgpr8, implicit $vgpr9, implicit $vgpr10, implicit $vgpr11, implicit $vgpr12, implicit $vgpr13, implicit $vgpr14, implicit $vgpr15, implicit $vgpr16, implicit $vgpr17, implicit $vgpr18, implicit $vgpr19, implicit $vgpr20, implicit $vgpr21, implicit $vgpr22, implicit $vgpr23, implicit $vgpr24, implicit $vgpr25, implicit $vgpr26, implicit $vgpr27, implicit $vgpr28, implicit $vgpr29, implicit $vgpr30, implicit $vgpr31, implicit $vgpr32, implicit $vgpr33, implicit $vgpr34, implicit $vgpr35, implicit $vgpr36, implicit $vgpr37, implicit $vgpr38, implicit $vgpr39, implicit $vgpr40, implicit $vgpr41, implicit $vgpr42, implicit $vgpr43, implicit $vgpr44, implicit $vgpr45, implicit $vgpr46, implicit $vgpr47, implicit $vgpr48, implicit $vgpr49, implicit $vgpr50, implicit $vgpr51, implicit $vgpr52, implicit $vgpr53, implicit $vgpr54, implicit $vgpr55, implicit $vgpr56, implicit $vgpr57, implicit $vgpr58, implicit $vgpr59, implicit $vgpr60, implicit $vgpr61
...