|
| 1 | +# NOTE: Assertions have been autogenerated by utils/update_mir_test_checks.py UTC_ARGS: --version 5 |
| 2 | +# RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx1100 -run-pass livedebugvalues %s -o - -debug-only livedebugvalues 2>&1 | FileCheck %s |
| 3 | + |
| 4 | +# REQUIRES: asserts |
| 5 | + |
| 6 | +# Verify that spill tracking is disabled on amdgcn. |
| 7 | + |
| 8 | +# CHECK: Disabling InstrRefBasedLDV spill tracking for kern since target has too many potential stack slot indexes |
| 9 | + |
| 10 | +--- | |
| 11 | + define void @kern() #0 !dbg !9 { |
| 12 | + ret void, !dbg !15 |
| 13 | + } |
| 14 | + |
| 15 | + attributes #0 = { noinline nounwind optnone "target-cpu"="gfx1100" } |
| 16 | + |
| 17 | + !llvm.dbg.cu = !{!0} |
| 18 | + !llvm.module.flags = !{!2, !3, !4, !5, !6, !7} |
| 19 | + !llvm.ident = !{!8} |
| 20 | + |
| 21 | + !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus_14, file: !1, producer: "clang version 19.0.0", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, splitDebugInlining: false, nameTableKind: None) |
| 22 | + !1 = !DIFile(filename: "t.cpp", directory: "/") |
| 23 | + !2 = !{i32 1, !"amdhsa_code_object_version", i32 500} |
| 24 | + !3 = !{i32 7, !"Dwarf Version", i32 5} |
| 25 | + !4 = !{i32 2, !"Debug Info Version", i32 3} |
| 26 | + !5 = !{i32 1, !"wchar_size", i32 4} |
| 27 | + !6 = !{i32 8, !"PIC Level", i32 2} |
| 28 | + !7 = !{i32 7, !"frame-pointer", i32 2} |
| 29 | + !8 = !{!"clang version 19.0.0"} |
| 30 | + !9 = distinct !DISubprogram(name: "kern", linkageName: "kern", scope: !1, file: !1, line: 1, type: !10, scopeLine: 1, flags: DIFlagPrototyped, spFlags: DISPFlagDefinition, unit: !0, retainedNodes: !12) |
| 31 | + !10 = !DISubroutineType(types: !11) |
| 32 | + !11 = !{} |
| 33 | + !12 = !{!13} |
| 34 | + !13 = !DILocalVariable(name: "var", scope: !9, file: !1, line: 1, type: !14) |
| 35 | + !14 = !DIBasicType(name: "i32", size: 32, encoding: DW_ATE_signed) |
| 36 | + !15 = !DILocation(line: 1, column: 1, scope: !9) |
| 37 | + |
| 38 | +... |
| 39 | +--- |
| 40 | +name: kern |
| 41 | +tracksRegLiveness: true |
| 42 | +debugInstrRef: true |
| 43 | +stack: |
| 44 | + - { id: 0, name: '', type: spill-slot, offset: 0, size: 4, alignment: 4 } |
| 45 | +machineFunctionInfo: |
| 46 | + scratchRSrcReg: $sgpr0_sgpr1_sgpr2_sgpr3 |
| 47 | + stackPtrOffsetReg: '$sgpr32' |
| 48 | + hasSpilledVGPRs: true |
| 49 | +body: | |
| 50 | + bb.0: |
| 51 | + ; CHECK-LABEL: name: kern |
| 52 | + ; CHECK: frame-setup CFI_INSTRUCTION escape 0x0f, 0x09, 0x90, 0x40, 0x94, 0x04, 0x36, 0x24, 0x36, 0xe9, 0x02 |
| 53 | + ; CHECK-NEXT: frame-setup CFI_INSTRUCTION llvm_register_pair $pc_reg, $sgpr30, 32, $sgpr31, 32 |
| 54 | + ; CHECK-NEXT: frame-setup CFI_INSTRUCTION undefined $vgpr0 |
| 55 | + ; CHECK-NEXT: DBG_INSTR_REF !13, !DIExpression(DIOpArg(0, i32)), dbg-instr-ref(1, 0), debug-location !15 |
| 56 | + ; CHECK-NEXT: DBG_VALUE_LIST !13, !DIExpression(DIOpArg(0, i32)), $noreg, debug-location !15 |
| 57 | + ; CHECK-NEXT: $vgpr0 = V_MOV_B32_e32 0, implicit $exec, debug-instr-number 1, debug-location !15 |
| 58 | + ; CHECK-NEXT: DBG_VALUE_LIST !13, !DIExpression(DIOpArg(0, i32)), $vgpr0, debug-location !15 |
| 59 | + ; CHECK-NEXT: SCRATCH_STORE_DWORD_SADDR killed $vgpr0, $sgpr32, 0, 0, implicit $exec, implicit $flat_scr, debug-location !15 :: (store (s32) into %stack.0, addrspace 5) |
| 60 | + ; CHECK-NEXT: S_NOP 0, debug-location !15 |
| 61 | + ; CHECK-NEXT: $vgpr0 = SCRATCH_LOAD_DWORD_SADDR $sgpr32, 0, 0, implicit $exec, implicit $flat_scr, debug-location !15 :: (load (s32) from %stack.0, addrspace 5) |
| 62 | + ; CHECK-NEXT: S_ENDPGM 0, debug-location !15 |
| 63 | + frame-setup CFI_INSTRUCTION escape 0x0f, 0x09, 0x90, 0x40, 0x94, 0x04, 0x36, 0x24, 0x36, 0xe9, 0x02 |
| 64 | + frame-setup CFI_INSTRUCTION llvm_register_pair $pc_reg, $sgpr30, 32, $sgpr31, 32 |
| 65 | + frame-setup CFI_INSTRUCTION undefined $vgpr0 |
| 66 | + DBG_INSTR_REF !13, !DIExpression(DIOpArg(0, i32)), dbg-instr-ref(1, 0), debug-location !15 |
| 67 | + $vgpr0 = V_MOV_B32_e32 0, implicit $exec, debug-instr-number 1, debug-location !15 |
| 68 | + SCRATCH_STORE_DWORD_SADDR killed $vgpr0, $sgpr32, 0, 0, implicit $exec, implicit $flat_scr, debug-location !15 :: (store (s32) into %stack.0, addrspace 5) |
| 69 | + S_NOP 0, debug-location !15 |
| 70 | + $vgpr0 = SCRATCH_LOAD_DWORD_SADDR $sgpr32, 0, 0, implicit $exec, implicit $flat_scr, debug-location !15 :: (load (s32) from %stack.0, addrspace 5) |
| 71 | + S_ENDPGM 0, debug-location !15 |
| 72 | +
|
| 73 | +... |
0 commit comments