File: padding-x86_64.ll

package info (click to toggle)
llvm-toolchain-16 1%3A16.0.6-15~deb12u1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 1,634,792 kB
  • sloc: cpp: 6,179,261; ansic: 1,216,205; asm: 741,319; python: 196,614; objc: 75,325; f90: 49,640; lisp: 32,396; pascal: 12,286; sh: 9,394; perl: 7,442; ml: 5,494; awk: 3,523; makefile: 2,723; javascript: 1,206; xml: 886; fortran: 581; cs: 573
file content (40 lines) | stat: -rw-r--r-- 1,545 bytes parent folder | download | duplicates (12)
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
; REQUIRES: x86_64-linux
; Checks if symbolizer can correctly symbolize address in the padding between
; functions.
; RUN: llc  -o %t.o -filetype=obj -mtriple=x86_64-pc-linux  %s
; RUN: llvm-symbolizer 0x5 --obj=%t.o | FileCheck %s --check-prefix=FOO
; RUN: llvm-symbolizer 0xd --obj=%t.o | FileCheck %s --check-prefix=PADDING
; RUN: llvm-symbolizer 0x10 --obj=%t.o | FileCheck %s --check-prefix=MAIN

;FOO: foo
;PADDING: ??
;MAIN: main

@a = global i32 1, align 4

define i32 @foo() !dbg !9 {
entry:
  %0 = load i32, ptr @a, align 4
  ret i32 %0
}

define i32 @main() !dbg !14 {
entry:
  %call = call i32 @foo(), !dbg !18
  ret i32 %call
}

!llvm.dbg.cu = !{!0}
!llvm.module.flags = !{!6, !7}

!0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "clang", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, enums: !2)
!1 = !DIFile(filename: "padding-x86_64.c", directory: "/tmp/")
!2 = !{}
!5 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed)
!6 = !{i32 2, !"Dwarf Version", i32 4}
!7 = !{i32 2, !"Debug Info Version", i32 3}
!9 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 2, type: !10, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: false, unit: !0, retainedNodes: !2)
!10 = !DISubroutineType(types: !11)
!11 = !{!5}
!14 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 6, type: !10, isLocal: false, isDefinition: true, scopeLine: 6, isOptimized: false, unit: !0, retainedNodes: !2)
!18 = !DILocation(line: 7, column: 8, scope: !14)