brintos

brintos / llvm-project-archived public Read only

0
0
Text · 2.2 KiB · acbbc99 Raw
56 lines · plain
1; XFAIL: target={{.*}}-aix{{.*}}2; Tests the mangling escape prefix gets stripped from the linkage name.3;4; RUN: %llc_dwarf -accel-tables=Dwarf -dwarf-linkage-names=All -filetype=obj -o %t < %s5;6; RUN: llvm-dwarfdump -debug-info -debug-names %t | FileCheck %s7; RUN: llvm-dwarfdump -debug-names -verify %t | FileCheck --check-prefix=VERIFY %s8 9; CHECK: .debug_info contents:10; CHECK: DW_AT_linkage_name	("bar")11; CHECK: .debug_names contents:12; CHECK: String: {{.*}} "bar"13 14; VERIFY: No errors.15 16; Input generated from the following C++ code using17; clang -g -S -emit-llvm -target aarch64-apple-macos18 19; void foo() asm("bar");20; void foo() {}21; 22; void g() { foo(); }23 24define void @"\01bar"() !dbg !9 {25entry:26  ret void, !dbg !1327}28 29define void @_Z1gv() !dbg !14 {30entry:31  call void @"\01bar"(), !dbg !1532  ret void, !dbg !1633}34 35!llvm.dbg.cu = !{!0}36!llvm.module.flags = !{!2, !3, !4, !5, !6, !7}37!llvm.ident = !{!8}38 39!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus_14, file: !1, producer: "clang version 21.0.0git", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, splitDebugInlining: false, nameTableKind: Apple, sysroot: "/")40!1 = !DIFile(filename: "asm.cpp", directory: "/tmp", checksumkind: CSK_MD5, checksum: "d053f9249cc5548d446ceb58411ad625")41!2 = !{i32 7, !"Dwarf Version", i32 5}42!3 = !{i32 2, !"Debug Info Version", i32 3}43!4 = !{i32 1, !"wchar_size", i32 4}44!5 = !{i32 8, !"PIC Level", i32 2}45!6 = !{i32 7, !"uwtable", i32 1}46!7 = !{i32 7, !"frame-pointer", i32 1}47!8 = !{!"clang version 21.0.0git"}48!9 = distinct !DISubprogram(name: "foo", linkageName: "\01bar", scope: !10, file: !10, line: 2, type: !11, scopeLine: 2, flags: DIFlagPrototyped, spFlags: DISPFlagDefinition, unit: !0)49!10 = !DIFile(filename: "asm.cpp", directory: "/tmp", checksumkind: CSK_MD5, checksum: "d053f9249cc5548d446ceb58411ad625")50!11 = !DISubroutineType(types: !12)51!12 = !{null}52!13 = !DILocation(line: 2, column: 13, scope: !9)53!14 = distinct !DISubprogram(name: "g", linkageName: "_Z1gv", scope: !10, file: !10, line: 4, type: !11, scopeLine: 4, flags: DIFlagPrototyped, spFlags: DISPFlagDefinition, unit: !0)54!15 = !DILocation(line: 4, column: 12, scope: !14)55!16 = !DILocation(line: 4, column: 19, scope: !14)56