brintos

brintos / llvm-project-archived public Read only

0
0
Text · 3.0 KiB · 8eafd65 Raw
62 lines · plain
1; RUN: llc -mtriple=x86_64-macosx %s -o %t -filetype=obj2; RUN: llvm-dwarfdump -v -debug-info %t | FileCheck %s3 4; CHECK: DW_TAG_subprogram [9] *5; CHECK-NOT: DW_AT_{{(MIPS_)?}}linkage_name6; CHECK: DW_AT_specification7 8source_filename = "test/DebugInfo/X86/linkage-name.ll"9 10%class.A = type { i8 }11 12@a = global %class.A zeroinitializer, align 1, !dbg !013 14; Function Attrs: nounwind ssp uwtable15define i32 @_ZN1A1aEi(ptr %this, i32 %b) #0 align 2 !dbg !14 {16entry:17  %this.addr = alloca ptr, align 818  %b.addr = alloca i32, align 419  store ptr %this, ptr %this.addr, align 820  call void @llvm.dbg.declare(metadata ptr %this.addr, metadata !15, metadata !17), !dbg !1821  store i32 %b, ptr %b.addr, align 422  call void @llvm.dbg.declare(metadata ptr %b.addr, metadata !19, metadata !17), !dbg !2023  %this1 = load ptr, ptr %this.addr24  %0 = load i32, ptr %b.addr, align 4, !dbg !2125  ret i32 %0, !dbg !2126}27 28; Function Attrs: nounwind readnone29 30declare void @llvm.dbg.declare(metadata, metadata, metadata) #131 32attributes #0 = { nounwind ssp uwtable }33attributes #1 = { nounwind readnone }34 35!llvm.dbg.cu = !{!10}36!llvm.module.flags = !{!13}37 38!0 = !DIGlobalVariableExpression(var: !1, expr: !DIExpression())39!1 = !DIGlobalVariable(name: "a", scope: null, file: !2, line: 9, type: !3, isLocal: false, isDefinition: true)40!2 = !DIFile(filename: "foo.cpp", directory: "/Users/echristo")41!3 = !DICompositeType(tag: DW_TAG_class_type, name: "A", file: !2, line: 1, size: 8, align: 8, elements: !4)42!4 = !{!5}43!5 = !DISubprogram(name: "a", linkageName: "_ZN1A1aEi", scope: !3, file: !2, line: 2, type: !6, isLocal: false, isDefinition: false, virtualIndex: 6, flags: DIFlagPrivate | DIFlagPrototyped, isOptimized: false)44!6 = !DISubroutineType(types: !7)45!7 = !{!8, !9, !8}46!8 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed)47!9 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: !3, size: 64, align: 64, flags: DIFlagArtificial)48!10 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !2, producer: "clang version 3.1 (trunk 152691) (llvm/trunk 152692)", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, enums: !11, retainedTypes: !11, globals: !12, imports: !11)49!11 = !{}50!12 = !{!0}51!13 = !{i32 1, !"Debug Info Version", i32 3}52!14 = distinct !DISubprogram(name: "a", linkageName: "_ZN1A1aEi", scope: null, file: !2, line: 5, type: !6, isLocal: false, isDefinition: true, scopeLine: 5, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, unit: !10, declaration: !5)53!15 = !DILocalVariable(name: "this", arg: 1, scope: !14, file: !2, line: 5, type: !16, flags: DIFlagArtificial)54!16 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: !3, size: 64, align: 64)55!17 = !DIExpression()56!18 = !DILocation(line: 5, column: 8, scope: !14)57!19 = !DILocalVariable(name: "b", arg: 2, scope: !14, file: !2, line: 5, type: !8)58!20 = !DILocation(line: 5, column: 14, scope: !14)59!21 = !DILocation(line: 6, column: 4, scope: !22)60!22 = distinct !DILexicalBlock(scope: !14, file: !2, line: 5, column: 17)61 62