brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.7 KiB · 08b7e4c Raw
45 lines · plain
1; RUN: opt < %s -passes='pseudo-probe,cgscc(inline)' -S | FileCheck %s2 3; CHECK-LABEL: @caller(4 5; This instruction did not have a !dbg metadata in the callee but get a !dbg after inlined.6; CHECK: store i32 1, {{.*}}, !dbg ![[#]]7 8; This pseudo probe came from callee without a !dbg metadata.9; CHECK-NOT:  call void @llvm.pseudoprobe({{.*}}), !dbg ![[#]]10; CHECK:  call void @llvm.pseudoprobe({{.*}})11 12@a = common global i32 0, align 413@b = common global i32 0, align 414 15; Function Attrs: nounwind uwtable16define void @callee() {17entry:18  store i32 1, ptr @a, align 419  ret void20}21 22; Function Attrs: nounwind uwtable23define void @caller() !dbg !4 {24entry:25  tail call void @callee(), !dbg !1226  ret void, !dbg !1227}28 29!llvm.dbg.cu = !{!0}30!llvm.module.flags = !{!8, !9}31!llvm.ident = !{!10}32 33!0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.5.0 (210174)", isOptimized: true, emissionKind: LineTablesOnly, file: !1, enums: !2, retainedTypes: !2, globals: !2, imports: !2)34!1 = !DIFile(filename: "test.c", directory: "/code/llvm/build0")35!2 = !{}36!4 = distinct !DISubprogram(name: "caller", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, unit: !0, scopeLine: 4, file: !1, scope: !5, type: !6, retainedNodes: !2)37!5 = !DIFile(filename: "test.c", directory: "/code/llvm/build0")38!6 = !DISubroutineType(types: !2)39!7 = distinct !DISubprogram(name: "callee2", line: 2, isLocal: true, isDefinition: true, virtualIndex: 6, isOptimized: true, unit: !0, scopeLine: 2, file: !1, scope: !5, type: !6, retainedNodes: !2)40!8 = !{i32 2, !"Dwarf Version", i32 4}41!9 = !{i32 2, !"Debug Info Version", i32 3}42!10 = !{!"clang version 3.5.0 (210174)"}43!11 = !DILocation(line: 2, scope: !7)44!12 = !DILocation(line: 4, scope: !4)45