File: prologue-epilogue-markers.ll

package info (click to toggle)
llvm-toolchain-19 1%3A19.1.7-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,998,520 kB
  • sloc: cpp: 6,951,680; ansic: 1,486,157; asm: 913,598; python: 232,024; f90: 80,126; objc: 75,281; lisp: 37,276; pascal: 16,990; sh: 10,009; ml: 5,058; perl: 4,724; awk: 3,523; makefile: 3,167; javascript: 2,504; xml: 892; fortran: 664; cs: 573
file content (46 lines) | stat: -rw-r--r-- 2,226 bytes parent folder | download | duplicates (9)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -verify-machineinstrs < %s | FileCheck %s
; RUN: llc -mtriple=amdgcn-amd-amdhsa -mcpu=gfx900 -filetype=obj < %s | llvm-dwarfdump --debug-line - | FileCheck --check-prefix=DWARFLINE %s

; Test that the prologue end line directive is emitted after all the prologue instructions
; and also before the beginning of the epilogue instructions in a trivial function.

; Function Attrs: convergent noinline nounwind optnone mustprogress
define hidden void @_Z9base_casev() #0 !dbg !6 {
; CHECK-LABEL: _Z9base_casev:
; CHECK:       .Lfunc_begin0:
; CHECK-NEXT:    .file 0 "dir" "file.cpp"
; CHECK-NEXT:    .loc 0 5 0 ; file.cpp:5:0
; CHECK-NEXT:    .cfi_sections .debug_frame
; CHECK-NEXT:    .cfi_startproc
; CHECK-NEXT:  ; %bb.0: ; %entry
; CHECK-NEXT:    s_waitcnt vmcnt(0) expcnt(0) lgkmcnt(0)
; CHECK-NEXT:  .Ltmp0:
; CHECK-NEXT:    .loc 0 7 3 prologue_end ; file.cpp:7:3
; CHECK-NEXT:    s_setpc_b64 s[30:31]
; CHECK-NEXT:  .Ltmp1:

; DWARFLINE:		file format elf64-amdgpu
; DWARFLINE:		.debug_line contents
; DWARFLINE:		Address            Line   Column File   ISA Discriminator OpIndex Flags
; DWARFLINE:		0x0000000000000000      5      0      0   0             0       0  is_stmt
; DWARFLINE-NEXT:	0x0000000000000004      7      3      0   0             0       0  is_stmt prologue_end
; DWARFLINE-NEXT:	0x0000000000000008      7      3      0   0             0       0  is_stmt end_sequence

entry:
  ret void, !dbg !7
}

attributes #0 = { nounwind }

!llvm.dbg.cu = !{!0}
!llvm.module.flags = !{!4, !5}

!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus_11, file: !1, isOptimized: false, emissionKind: FullDebug, splitDebugInlining: false, nameTableKind: None)
!1 = !DIFile(filename: "file.cpp", directory: "dir")
!2 = !DISubroutineType(types: !3)
!3 = !{null}
!4 = !{i32 7, !"Dwarf Version", i32 5}
!5 = !{i32 2, !"Debug Info Version", i32 3}
!6 = distinct !DISubprogram(name: "base_case", linkageName: "_Z9base_casev", scope: !1, file: !1, line: 5, type: !2, scopeLine: 5, flags: DIFlagPrototyped, spFlags: DISPFlagDefinition, unit: !0)
!7 = !DILocation(line: 7, column: 3, scope: !6)