|
| 1 | +; RUN: llc -split-dwarf-file=foo.dwo %s -filetype=obj -o - | llvm-dwarfdump -debug-info - | FileCheck %s |
| 2 | + |
| 3 | +; CHECK: .debug_info contents: |
| 4 | +; CHECK: DW_TAG_subprogram |
| 5 | +; CHECK: caller_func |
| 6 | +; CHECK: DW_TAG_inlined_subroutine |
| 7 | +; CHECK: inlined_func |
| 8 | + |
| 9 | +; CHECK: .debug_info.dwo contents |
| 10 | +; CHECK: DW_TAG_subprogram |
| 11 | +; CHECK: caller_func |
| 12 | +; CHECK: DW_TAG_inlined_subroutine |
| 13 | +; CHECK: inlined_func |
| 14 | + |
| 15 | +target triple = "x86_64-unknown-linux-gnu" |
| 16 | + |
| 17 | +define void @caller_func() !dbg !9 { |
| 18 | +entry: |
| 19 | + ret void, !dbg !13 |
| 20 | +} |
| 21 | + |
| 22 | +!llvm.dbg.cu = !{!0, !3} |
| 23 | +!llvm.module.flags = !{!5, !6} |
| 24 | + |
| 25 | +!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !1, producer: "clang trunk", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, splitDebugInlining: false) |
| 26 | +!1 = !DIFile(filename: "a.cpp", directory: "/tmp") |
| 27 | +!3 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !4, producer: "clang trunk", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, splitDebugInlining: true) |
| 28 | +!4 = !DIFile(filename: "b.cpp", directory: "/tmp") |
| 29 | +!5 = !{i32 2, !"Dwarf Version", i32 4} |
| 30 | +!6 = !{i32 2, !"Debug Info Version", i32 3} |
| 31 | +!9 = distinct !DISubprogram(name: "caller_func", scope: !4, file: !4, line: 2, type: !10, isLocal: false, isDefinition: true, scopeLine: 2, unit: !3) |
| 32 | +!10 = !DISubroutineType(types: !11) |
| 33 | +!11 = !{null} |
| 34 | +!12 = distinct !DISubprogram(name: "inlined_func", scope: !1, file: !1, line: 1, type: !10, isLocal: false, isDefinition: true, scopeLine: 1, unit: !0) |
| 35 | +!13 = !DILocation(line: 1, column: 5, scope: !12, inlinedAt: !14) |
| 36 | +!14 = distinct !DILocation(line: 3, column: 3, scope: !9) |
0 commit comments