Home | History | Annotate | Download | only in X86
      1 ; RUN: %llc_dwarf -filetype=obj %s -o - | llvm-dwarfdump -debug-dump=info - | FileCheck %s
      2 ; Generated at -O2 from:
      3 ;   void f();
      4 ;   __attribute__((always_inline)) void g() {
      5 ;     f();
      6 ;   }
      7 ;   void h() {
      8 ;     g();
      9 ;   };
     10 ; CHECK: DW_TAG_subprogram
     11 ; CHECK:  DW_AT_abstract_origin {{.*}}"g"
     12 ; CHECK-NOT:  DW_AT_abstract_origin {{.*}}"g"
     13 ; CHECK: DW_TAG
     14 source_filename = "test.c"
     15 target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128"
     16 target triple = "x86_64-apple-macosx10.11.0"
     17 
     18 ; Function Attrs: alwaysinline nounwind ssp uwtable
     19 define void @g() #0 !dbg !7 {
     20 entry:
     21   tail call void (...) @f() #3, !dbg !10
     22   ret void, !dbg !11
     23 }
     24 
     25 declare void @f(...)
     26 
     27 ; Function Attrs: nounwind ssp uwtable
     28 define void @h() #2 !dbg !12 {
     29 entry:
     30   tail call void (...) @f() #3, !dbg !13
     31   ret void, !dbg !15
     32 }
     33 
     34 attributes #0 = { alwaysinline nounwind ssp uwtable }
     35 attributes #2 = { nounwind ssp uwtable }
     36 attributes #3 = { nounwind }
     37 
     38 !llvm.dbg.cu = !{!0}
     39 !llvm.module.flags = !{!3, !4, !5}
     40 !llvm.ident = !{!6}
     41 
     42 !0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "clang version 3.9.0 ", isOptimized: true, runtimeVersion: 0, emissionKind: FullDebug, enums: !2)
     43 !1 = !DIFile(filename: "test.c", directory: "/Volumes/Data/llvm")
     44 !2 = !{}
     45 !3 = !{i32 2, !"Dwarf Version", i32 2}
     46 !4 = !{i32 2, !"Debug Info Version", i32 3}
     47 !5 = !{i32 1, !"PIC Level", i32 2}
     48 !6 = !{!"clang version 3.9.0 "}
     49 !7 = distinct !DISubprogram(name: "g", scope: !1, file: !1, line: 2, type: !8, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: true, unit: !0, variables: !2)
     50 !8 = !DISubroutineType(types: !9)
     51 !9 = !{null}
     52 !10 = !DILocation(line: 3, column: 3, scope: !7)
     53 !11 = !DILocation(line: 4, column: 1, scope: !7)
     54 !12 = distinct !DISubprogram(name: "h", scope: !1, file: !1, line: 5, type: !8, isLocal: false, isDefinition: true, scopeLine: 5, isOptimized: true, unit: !0, variables: !2)
     55 !13 = !DILocation(line: 3, column: 3, scope: !7, inlinedAt: !14)
     56 !14 = distinct !DILocation(line: 6, column: 3, scope: !12)
     57 !15 = !DILocation(line: 7, column: 1, scope: !12)
     58