diff options
Diffstat (limited to 'test/Linker/Inputs')
| -rw-r--r-- | test/Linker/Inputs/alias-2.ll | 7 | ||||
| -rw-r--r-- | test/Linker/Inputs/comdat-rm-dst.ll | 5 | ||||
| -rw-r--r-- | test/Linker/Inputs/comdat16.ll | 26 | ||||
| -rw-r--r-- | test/Linker/Inputs/dicompositetype-unique.ll | 6 | ||||
| -rw-r--r-- | test/Linker/Inputs/funcimport2.ll | 8 | ||||
| -rw-r--r-- | test/Linker/Inputs/funcimport_comdat.ll | 4 | ||||
| -rw-r--r-- | test/Linker/Inputs/mdlocation.ll | 28 | ||||
| -rw-r--r-- | test/Linker/Inputs/odr.ll | 8 | ||||
| -rw-r--r-- | test/Linker/Inputs/only-needed-debug-metadata.ll | 5 | ||||
| -rw-r--r-- | test/Linker/Inputs/only-needed-recurse.ll | 8 | ||||
| -rw-r--r-- | test/Linker/Inputs/pr26037.ll | 5 | ||||
| -rw-r--r-- | test/Linker/Inputs/pr27044.ll | 19 | ||||
| -rw-r--r-- | test/Linker/Inputs/replaced-function-matches-first-subprogram.ll | 5 | ||||
| -rw-r--r-- | test/Linker/Inputs/subprogram-linkonce-weak.ll | 4 | ||||
| -rw-r--r-- | test/Linker/Inputs/thinlto_funcimport_debug.ll | 5 | ||||
| -rw-r--r-- | test/Linker/Inputs/type-unique-inheritance-a.ll | 11 | ||||
| -rw-r--r-- | test/Linker/Inputs/type-unique-inheritance-b.ll | 17 | ||||
| -rw-r--r-- | test/Linker/Inputs/type-unique-simple2-a.ll | 13 | ||||
| -rw-r--r-- | test/Linker/Inputs/type-unique-simple2-b.ll | 15 |
19 files changed, 148 insertions, 51 deletions
diff --git a/test/Linker/Inputs/alias-2.ll b/test/Linker/Inputs/alias-2.ll new file mode 100644 index 000000000000..03c1d91fe6bf --- /dev/null +++ b/test/Linker/Inputs/alias-2.ll @@ -0,0 +1,7 @@ +define void @B() { + call void @A() + ret void +} + +declare void @A() + diff --git a/test/Linker/Inputs/comdat-rm-dst.ll b/test/Linker/Inputs/comdat-rm-dst.ll new file mode 100644 index 000000000000..41dccdf2c7c1 --- /dev/null +++ b/test/Linker/Inputs/comdat-rm-dst.ll @@ -0,0 +1,5 @@ +target datalayout = "e-m:w-p:32:32-i64:64-f80:32-n8:16:32-S32" +target triple = "i686-pc-windows-msvc" + +$foo = comdat largest +@foo = global i64 43, comdat diff --git a/test/Linker/Inputs/comdat16.ll b/test/Linker/Inputs/comdat16.ll new file mode 100644 index 000000000000..7644e0e1ce9b --- /dev/null +++ b/test/Linker/Inputs/comdat16.ll @@ -0,0 +1,26 @@ +$c2 = comdat any +$c1 = comdat any + +; This is only present in this file. The linker will keep $c1 from the first +; file and this will be undefined. +@will_be_undefined = global i32 1, comdat($c1) +@use = global i32* @will_be_undefined + +@v1 = weak_odr global i32 41, comdat($c2) +define weak_odr protected i32 @f1(i8* %this) comdat($c2) { +bb20: + store i8* %this, i8** null + br label %bb21 +bb21: + ret i32 41 +} + +@r21 = global i32* @v1 +@r22 = global i32(i8*)* @f1 + +@a21 = alias i32, i32* @v1 +@a22 = alias i16, bitcast (i32* @v1 to i16*) + +@a23 = alias i32(i8*), i32(i8*)* @f1 +@a24 = alias i16, bitcast (i32(i8*)* @f1 to i16*) +@a25 = alias i16, i16* @a24 diff --git a/test/Linker/Inputs/dicompositetype-unique.ll b/test/Linker/Inputs/dicompositetype-unique.ll new file mode 100644 index 000000000000..e1537b93dfec --- /dev/null +++ b/test/Linker/Inputs/dicompositetype-unique.ll @@ -0,0 +1,6 @@ +!named = !{!0, !1, !2, !3} + +!0 = !DIFile(filename: "abc", directory: "/path/to") +!1 = !DICompositeType(tag: DW_TAG_class_type, name: "T2", identifier: "T", file: !0) +!2 = !DICompositeType(tag: DW_TAG_class_type, name: "FwdTDef", identifier: "FwdT", file: !0) +!3 = !DICompositeType(tag: DW_TAG_class_type, flags: DIFlagFwdDecl, name: "BothFwdT2", identifier: "BothFwdT", file: !0) diff --git a/test/Linker/Inputs/funcimport2.ll b/test/Linker/Inputs/funcimport2.ll new file mode 100644 index 000000000000..4d0ec6c03f62 --- /dev/null +++ b/test/Linker/Inputs/funcimport2.ll @@ -0,0 +1,8 @@ +define linkonce_odr hidden void @foo() { + ret void +} + +define void @bar() { + call void @foo() + ret void +} diff --git a/test/Linker/Inputs/funcimport_comdat.ll b/test/Linker/Inputs/funcimport_comdat.ll new file mode 100644 index 000000000000..9a4b9d728d40 --- /dev/null +++ b/test/Linker/Inputs/funcimport_comdat.ll @@ -0,0 +1,4 @@ +define i32 @main() #0 { +entry: + ret i32 0 +} diff --git a/test/Linker/Inputs/mdlocation.ll b/test/Linker/Inputs/mdlocation.ll index 9c2f65d0a59a..0f6a162bdba3 100644 --- a/test/Linker/Inputs/mdlocation.ll +++ b/test/Linker/Inputs/mdlocation.ll @@ -1,9 +1,23 @@ -!named = !{!0, !1, !2, !3, !4, !5} +define void @foo1() !dbg !0 { + ret void, !dbg !3 +} -!0 = distinct !DISubprogram() ; Use this as a scope. -!1 = !DILocation(line: 3, column: 7, scope: !0) -!2 = !DILocation(line: 3, column: 7, scope: !0, inlinedAt: !1) -!3 = !DILocation(line: 3, column: 7, scope: !0, inlinedAt: !2) +!named = !{!1, !2, !3, !4, !5} + +!0 = distinct !DISubprogram(file: !7, scope: !7, line: 1, name: "foo", type: !9, unit: !6) + +!1 = !DILocation(line: 3, column: 7, scope: !10) +!2 = !DILocation(line: 3, column: 7, scope: !10, inlinedAt: !1) +!3 = !DILocation(line: 3, column: 7, scope: !10, inlinedAt: !2) ; Test distinct nodes. -!4 = distinct !DILocation(line: 3, column: 7, scope: !0) -!5 = distinct !DILocation(line: 3, column: 7, scope: !0, inlinedAt: !4) +!4 = distinct !DILocation(line: 3, column: 7, scope: !10) +!5 = distinct !DILocation(line: 3, column: 7, scope: !10, inlinedAt: !4) + +!llvm.dbg.cu = !{!6} +!6 = distinct !DICompileUnit(language: DW_LANG_C89, file: !7) +!7 = !DIFile(filename: "source.c", directory: "/dir") + +!llvm.module.flags = !{!8} +!8 = !{i32 1, !"Debug Info Version", i32 3} +!9 = !DISubroutineType(types: !{}) +!10 = distinct !DILexicalBlock(line: 3, column: 3, file: !7, scope: !0) diff --git a/test/Linker/Inputs/odr.ll b/test/Linker/Inputs/odr.ll new file mode 100644 index 000000000000..5c1d17a59511 --- /dev/null +++ b/test/Linker/Inputs/odr.ll @@ -0,0 +1,8 @@ +!llvm.dbg.cu = !{!0} +!llvm.module.flags = !{!4} + +!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !1, isOptimized: false, runtimeVersion: 0, emissionKind: NoDebug, retainedTypes: !2) +!1 = !DIFile(filename: "../../src/core/weakHashTable.cc", directory: "/Users/meister/Development/clasp/wbuild/clasp_boehm_o") +!2 = !{!3} +!3 = distinct !DICompositeType(tag: DW_TAG_class_type, file: !1, identifier: "zed") +!4 = !{i32 2, !"Debug Info Version", i32 3} diff --git a/test/Linker/Inputs/only-needed-debug-metadata.ll b/test/Linker/Inputs/only-needed-debug-metadata.ll index ec7f02f4d194..a944c8ab9321 100644 --- a/test/Linker/Inputs/only-needed-debug-metadata.ll +++ b/test/Linker/Inputs/only-needed-debug-metadata.ll @@ -12,11 +12,10 @@ define void @bar() !dbg !4 { !llvm.module.flags = !{!7, !8} !llvm.ident = !{!9} -!0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "clang version 3.8.0 (trunk 251407) (llvm/trunk 251401)", isOptimized: true, runtimeVersion: 0, emissionKind: 1, enums: !2, subprograms: !3) +!0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "clang version 3.8.0 (trunk 251407) (llvm/trunk 251401)", isOptimized: true, runtimeVersion: 0, emissionKind: FullDebug, enums: !2) !1 = !DIFile(filename: "linkused.b.c", directory: ".") !2 = !{} -!3 = !{!4} -!4 = distinct !DISubprogram(name: "bar", scope: !1, file: !1, line: 5, type: !5, isLocal: false, isDefinition: true, scopeLine: 5, isOptimized: true, variables: !2) +!4 = distinct !DISubprogram(name: "bar", scope: !1, file: !1, line: 5, type: !5, isLocal: false, isDefinition: true, scopeLine: 5, isOptimized: true, unit: !0, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/Linker/Inputs/only-needed-recurse.ll b/test/Linker/Inputs/only-needed-recurse.ll new file mode 100644 index 000000000000..423c9d53e9df --- /dev/null +++ b/test/Linker/Inputs/only-needed-recurse.ll @@ -0,0 +1,8 @@ +define void @f2() { + call void @f3() + ret void +} + +define void @f3() { + ret void +} diff --git a/test/Linker/Inputs/pr26037.ll b/test/Linker/Inputs/pr26037.ll index ed05b08089a4..a1a024f19060 100644 --- a/test/Linker/Inputs/pr26037.ll +++ b/test/Linker/Inputs/pr26037.ll @@ -9,11 +9,10 @@ entry: !llvm.module.flags = !{!8, !9} !llvm.ident = !{!10} -!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !1, producer: "clang version 3.8.0 (trunk 256934) (llvm/trunk 256936)", isOptimized: false, runtimeVersion: 0, emissionKind: 1, enums: !2, subprograms: !3) +!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !1, producer: "clang version 3.8.0 (trunk 256934) (llvm/trunk 256936)", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, enums: !2) !1 = !DIFile(filename: "main.cc", directory: "") !2 = !{} -!3 = !{!4} -!4 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: false, variables: !2) +!4 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: false, unit: !0, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{!7} !7 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/Linker/Inputs/pr27044.ll b/test/Linker/Inputs/pr27044.ll new file mode 100644 index 000000000000..c949a93243e7 --- /dev/null +++ b/test/Linker/Inputs/pr27044.ll @@ -0,0 +1,19 @@ +$foo = comdat any +$bar = comdat any + +define linkonce_odr i32 @f1() comdat($foo) { + ret i32 1 +} + +define void @f2() comdat($foo) { + call i32 @g2() + ret void +} + +define linkonce_odr i32 @g1() comdat($bar) { + ret i32 1 +} + +define linkonce_odr i32 @g2() comdat($bar) { + ret i32 1 +} diff --git a/test/Linker/Inputs/replaced-function-matches-first-subprogram.ll b/test/Linker/Inputs/replaced-function-matches-first-subprogram.ll index a817cf071078..7598ab159eb4 100644 --- a/test/Linker/Inputs/replaced-function-matches-first-subprogram.ll +++ b/test/Linker/Inputs/replaced-function-matches-first-subprogram.ll @@ -12,11 +12,10 @@ entry: !llvm.module.flags = !{!8, !9, !10} !llvm.ident = !{!11} -!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.6.0 (trunk 224193) (llvm/trunk 224197)", isOptimized: false, emissionKind: 2, file: !1, enums: !2, retainedTypes: !2, subprograms: !3, globals: !2, imports: !2) +!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.6.0 (trunk 224193) (llvm/trunk 224197)", isOptimized: false, emissionKind: LineTablesOnly, file: !1, enums: !2, retainedTypes: !2, globals: !2, imports: !2) !1 = !DIFile(filename: "t2.cpp", directory: "/Users/dexonsmith/data/llvm/staging/test/Linker/repro/d2") !2 = !{} -!3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !5, scope: !6, type: !7, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, unit: !0, scopeLine: 2, file: !5, scope: !6, type: !7, variables: !2) !5 = !DIFile(filename: "../t.h", directory: "/Users/dexonsmith/data/llvm/staging/test/Linker/repro/d2") !6 = !DIFile(filename: "../t.h", directory: "/Users/dexonsmith/data/llvm/staging/test/Linker/repro/d2") !7 = !DISubroutineType(types: !2) diff --git a/test/Linker/Inputs/subprogram-linkonce-weak.ll b/test/Linker/Inputs/subprogram-linkonce-weak.ll index 5e6627d90c97..29d06515e427 100644 --- a/test/Linker/Inputs/subprogram-linkonce-weak.ll +++ b/test/Linker/Inputs/subprogram-linkonce-weak.ll @@ -10,7 +10,7 @@ declare i32 @fastadd(i32, i32) !0 = !{i32 2, !"Debug Info Version", i32 3} !llvm.dbg.cu = !{!1} -!1 = distinct !DICompileUnit(language: DW_LANG_C99, file: !2, subprograms: !{!3}, emissionKind: 1) +!1 = distinct !DICompileUnit(language: DW_LANG_C99, file: !2, emissionKind: FullDebug) !2 = !DIFile(filename: "foo.c", directory: "/path/to/dir") -!3 = distinct !DISubprogram(file: !2, scope: !2, line: 51, name: "foo", type: !4) +!3 = distinct !DISubprogram(file: !2, scope: !2, line: 51, name: "foo", type: !4, unit: !1) !4 = !DISubroutineType(types: !{}) diff --git a/test/Linker/Inputs/thinlto_funcimport_debug.ll b/test/Linker/Inputs/thinlto_funcimport_debug.ll index 846a5ea001d5..cc76d8ae29ed 100644 --- a/test/Linker/Inputs/thinlto_funcimport_debug.ll +++ b/test/Linker/Inputs/thinlto_funcimport_debug.ll @@ -22,11 +22,10 @@ attributes #2 = { nounwind } !llvm.module.flags = !{!8, !9} !llvm.ident = !{!10} -!0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "clang version 3.8.0 (trunk 251407) (llvm/trunk 251401)", isOptimized: true, runtimeVersion: 0, emissionKind: 1, enums: !2, subprograms: !3) +!0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "clang version 3.8.0 (trunk 251407) (llvm/trunk 251401)", isOptimized: true, runtimeVersion: 0, emissionKind: FullDebug, enums: !2) !1 = !DIFile(filename: "dbg_main.c", directory: ".") !2 = !{} -!3 = !{!4} -!4 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, isOptimized: true, variables: !2) +!4 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, isOptimized: true, unit: !0, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{!7} !7 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/Linker/Inputs/type-unique-inheritance-a.ll b/test/Linker/Inputs/type-unique-inheritance-a.ll index 0a1c107580bb..15bd0383a4d8 100644 --- a/test/Linker/Inputs/type-unique-inheritance-a.ll +++ b/test/Linker/Inputs/type-unique-inheritance-a.ll @@ -66,22 +66,21 @@ attributes #1 = { nounwind readnone } !llvm.dbg.cu = !{!0} !llvm.module.flags = !{!19, !25} -!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.4 (http://llvm.org/git/clang.git f54e02f969d02d640103db73efc30c45439fceab) (http://llvm.org/git/llvm.git 284353b55896cb1babfaa7add7c0a363245342d2)", isOptimized: false, emissionKind: 0, file: !1, enums: !2, retainedTypes: !3, subprograms: !14, globals: !2, imports: !2) +!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.4 (http://llvm.org/git/clang.git f54e02f969d02d640103db73efc30c45439fceab) (http://llvm.org/git/llvm.git 284353b55896cb1babfaa7add7c0a363245342d2)", isOptimized: false, emissionKind: FullDebug, file: !1, enums: !2, retainedTypes: !3, globals: !2, imports: !2) !1 = !DIFile(filename: "foo.cpp", directory: "/Users/mren/c_testing/type_unique_air/inher") !2 = !{} !3 = !{!4, !8} !4 = !DICompositeType(tag: DW_TAG_class_type, name: "A", line: 3, size: 64, align: 32, file: !5, elements: !6, identifier: "_ZTS1A") !5 = !DIFile(filename: "./a.hpp", directory: "/Users/mren/c_testing/type_unique_air/inher") !6 = !{!7, !13} -!7 = !DIDerivedType(tag: DW_TAG_inheritance, flags: DIFlagPrivate, scope: !"_ZTS1A", baseType: !8) +!7 = !DIDerivedType(tag: DW_TAG_inheritance, flags: DIFlagPrivate, scope: !4, baseType: !8) !8 = !DICompositeType(tag: DW_TAG_class_type, name: "Base", line: 3, size: 32, align: 32, file: !9, elements: !10, identifier: "_ZTS4Base") !9 = !DIFile(filename: "./b.hpp", directory: "/Users/mren/c_testing/type_unique_air/inher") !10 = !{!11} -!11 = !DIDerivedType(tag: DW_TAG_member, name: "b", line: 4, size: 32, align: 32, flags: DIFlagPrivate, file: !9, scope: !"_ZTS4Base", baseType: !12) +!11 = !DIDerivedType(tag: DW_TAG_member, name: "b", line: 4, size: 32, align: 32, flags: DIFlagPrivate, file: !9, scope: !8, baseType: !12) !12 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!13 = !DIDerivedType(tag: DW_TAG_member, name: "x", line: 4, size: 32, align: 32, offset: 32, flags: DIFlagPrivate, file: !5, scope: !"_ZTS1A", baseType: !12) -!14 = !{!15} -!15 = distinct !DISubprogram(name: "f", linkageName: "_Z1fi", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !16, type: !17, variables: !2) +!13 = !DIDerivedType(tag: DW_TAG_member, name: "x", line: 4, size: 32, align: 32, offset: 32, flags: DIFlagPrivate, file: !5, scope: !4, baseType: !12) +!15 = distinct !DISubprogram(name: "f", linkageName: "_Z1fi", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, unit: !0, scopeLine: 5, file: !1, scope: !16, type: !17, variables: !2) !16 = !DIFile(filename: "foo.cpp", directory: "/Users/mren/c_testing/type_unique_air/inher") !17 = !DISubroutineType(types: !18) !18 = !{null, !12} diff --git a/test/Linker/Inputs/type-unique-inheritance-b.ll b/test/Linker/Inputs/type-unique-inheritance-b.ll index e87b96b9c791..fafc25a7c77e 100644 --- a/test/Linker/Inputs/type-unique-inheritance-b.ll +++ b/test/Linker/Inputs/type-unique-inheritance-b.ll @@ -40,31 +40,30 @@ attributes #3 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !llvm.dbg.cu = !{!0} !llvm.module.flags = !{!27, !38} -!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.4 (http://llvm.org/git/clang.git f54e02f969d02d640103db73efc30c45439fceab) (http://llvm.org/git/llvm.git 284353b55896cb1babfaa7add7c0a363245342d2)", isOptimized: false, emissionKind: 0, file: !1, enums: !2, retainedTypes: !3, subprograms: !19, globals: !2, imports: !2) +!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.4 (http://llvm.org/git/clang.git f54e02f969d02d640103db73efc30c45439fceab) (http://llvm.org/git/llvm.git 284353b55896cb1babfaa7add7c0a363245342d2)", isOptimized: false, emissionKind: FullDebug, file: !1, enums: !2, retainedTypes: !3, globals: !2, imports: !2) !1 = !DIFile(filename: "bar.cpp", directory: "/Users/mren/c_testing/type_unique_air/inher") !2 = !{} !3 = !{!4, !11, !15} !4 = !DICompositeType(tag: DW_TAG_class_type, name: "B", line: 7, size: 128, align: 64, file: !5, elements: !6, identifier: "_ZTS1B") !5 = !DIFile(filename: "./b.hpp", directory: "/Users/mren/c_testing/type_unique_air/inher") !6 = !{!7, !9} -!7 = !DIDerivedType(tag: DW_TAG_member, name: "bb", line: 8, size: 32, align: 32, flags: DIFlagPrivate, file: !5, scope: !"_ZTS1B", baseType: !8) +!7 = !DIDerivedType(tag: DW_TAG_member, name: "bb", line: 8, size: 32, align: 32, flags: DIFlagPrivate, file: !5, scope: !4, baseType: !8) !8 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!9 = !DIDerivedType(tag: DW_TAG_member, name: "a", line: 9, size: 64, align: 64, offset: 64, flags: DIFlagPrivate, file: !5, scope: !"_ZTS1B", baseType: !10) +!9 = !DIDerivedType(tag: DW_TAG_member, name: "a", line: 9, size: 64, align: 64, offset: 64, flags: DIFlagPrivate, file: !5, scope: !4, baseType: !10) !10 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !11) !11 = !DICompositeType(tag: DW_TAG_class_type, name: "A", line: 3, size: 64, align: 32, file: !12, elements: !13, identifier: "_ZTS1A") !12 = !DIFile(filename: "./a.hpp", directory: "/Users/mren/c_testing/type_unique_air/inher") !13 = !{!14, !18} -!14 = !DIDerivedType(tag: DW_TAG_inheritance, flags: DIFlagPrivate, scope: !"_ZTS1A", baseType: !15) +!14 = !DIDerivedType(tag: DW_TAG_inheritance, flags: DIFlagPrivate, scope: !11, baseType: !15) !15 = !DICompositeType(tag: DW_TAG_class_type, name: "Base", line: 3, size: 32, align: 32, file: !5, elements: !16, identifier: "_ZTS4Base") !16 = !{!17} -!17 = !DIDerivedType(tag: DW_TAG_member, name: "b", line: 4, size: 32, align: 32, flags: DIFlagPrivate, file: !5, scope: !"_ZTS4Base", baseType: !8) -!18 = !DIDerivedType(tag: DW_TAG_member, name: "x", line: 4, size: 32, align: 32, offset: 32, flags: DIFlagPrivate, file: !12, scope: !"_ZTS1A", baseType: !8) -!19 = !{!20, !24} -!20 = distinct !DISubprogram(name: "g", linkageName: "_Z1gi", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !21, type: !22, variables: !2) +!17 = !DIDerivedType(tag: DW_TAG_member, name: "b", line: 4, size: 32, align: 32, flags: DIFlagPrivate, file: !5, scope: !15, baseType: !8) +!18 = !DIDerivedType(tag: DW_TAG_member, name: "x", line: 4, size: 32, align: 32, offset: 32, flags: DIFlagPrivate, file: !12, scope: !11, baseType: !8) +!20 = distinct !DISubprogram(name: "g", linkageName: "_Z1gi", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, unit: !0, scopeLine: 4, file: !1, scope: !21, type: !22, variables: !2) !21 = !DIFile(filename: "bar.cpp", directory: "/Users/mren/c_testing/type_unique_air/inher") !22 = !DISubroutineType(types: !23) !23 = !{null, !8} -!24 = distinct !DISubprogram(name: "main", line: 9, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 9, file: !1, scope: !21, type: !25, variables: !2) +!24 = distinct !DISubprogram(name: "main", line: 9, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, unit: !0, scopeLine: 9, file: !1, scope: !21, type: !25, variables: !2) !25 = !DISubroutineType(types: !26) !26 = !{!8} !27 = !{i32 2, !"Dwarf Version", i32 2} diff --git a/test/Linker/Inputs/type-unique-simple2-a.ll b/test/Linker/Inputs/type-unique-simple2-a.ll index 2a52e89b6fd3..0b2b1ae6b612 100644 --- a/test/Linker/Inputs/type-unique-simple2-a.ll +++ b/test/Linker/Inputs/type-unique-simple2-a.ll @@ -63,19 +63,18 @@ attributes #1 = { nounwind readnone } !llvm.dbg.cu = !{!0} !llvm.module.flags = !{!16, !22} -!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.4 (http://llvm.org/git/clang.git 8a3f9e46cb988d2c664395b21910091e3730ae82) (http://llvm.org/git/llvm.git 4699e9549358bc77824a59114548eecc3f7c523c)", isOptimized: false, emissionKind: 0, file: !1, enums: !2, retainedTypes: !3, subprograms: !11, globals: !2, imports: !2) +!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.4 (http://llvm.org/git/clang.git 8a3f9e46cb988d2c664395b21910091e3730ae82) (http://llvm.org/git/llvm.git 4699e9549358bc77824a59114548eecc3f7c523c)", isOptimized: false, emissionKind: FullDebug, file: !1, enums: !2, retainedTypes: !3, globals: !2, imports: !2) !1 = !DIFile(filename: "foo.cpp", directory: ".") !2 = !{} !3 = !{!4} -!4 = !DICompositeType(tag: DW_TAG_structure_type, name: "Base", line: 1, size: 128, align: 64, file: !5, elements: !6, identifier: "_ZTS4Base") +!4 = !DICompositeType(tag: DW_TAG_structure_type, name: "Base", line: 1, file: !5, elements: !6, identifier: "_ZTS4Base") !5 = !DIFile(filename: "./a.hpp", directory: ".") !6 = !{!7, !9} -!7 = !DIDerivedType(tag: DW_TAG_member, name: "a", line: 2, size: 32, align: 32, file: !5, scope: !"_ZTS4Base", baseType: !8) +!7 = !DIDerivedType(tag: DW_TAG_member, name: "a", line: 2, size: 32, align: 32, file: !5, scope: !4, baseType: !8) !8 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!9 = !DIDerivedType(tag: DW_TAG_member, name: "b", line: 3, size: 64, align: 64, offset: 64, file: !5, scope: !"_ZTS4Base", baseType: !10) -!10 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !"_ZTS4Base") -!11 = !{!12} -!12 = distinct !DISubprogram(name: "f", linkageName: "_Z1fi", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !13, type: !14, variables: !2) +!9 = !DIDerivedType(tag: DW_TAG_member, name: "b", line: 3, size: 64, align: 64, offset: 64, file: !5, scope: !4, baseType: !10) +!10 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: !4) +!12 = distinct !DISubprogram(name: "f", linkageName: "_Z1fi", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, unit: !0, scopeLine: 3, file: !1, scope: !13, type: !14, variables: !2) !13 = !DIFile(filename: "foo.cpp", directory: ".") !14 = !DISubroutineType(types: !15) !15 = !{null, !8} diff --git a/test/Linker/Inputs/type-unique-simple2-b.ll b/test/Linker/Inputs/type-unique-simple2-b.ll index 7e1c6aabd9a5..f9499d8d7e24 100644 --- a/test/Linker/Inputs/type-unique-simple2-b.ll +++ b/test/Linker/Inputs/type-unique-simple2-b.ll @@ -36,23 +36,22 @@ attributes #3 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !llvm.dbg.cu = !{!0} !llvm.module.flags = !{!19, !28} -!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.4 (http://llvm.org/git/clang.git 8a3f9e46cb988d2c664395b21910091e3730ae82) (http://llvm.org/git/llvm.git 4699e9549358bc77824a59114548eecc3f7c523c)", isOptimized: false, emissionKind: 0, file: !1, enums: !2, retainedTypes: !3, subprograms: !11, globals: !2, imports: !2) +!0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.4 (http://llvm.org/git/clang.git 8a3f9e46cb988d2c664395b21910091e3730ae82) (http://llvm.org/git/llvm.git 4699e9549358bc77824a59114548eecc3f7c523c)", isOptimized: false, emissionKind: FullDebug, file: !1, enums: !2, retainedTypes: !3, globals: !2, imports: !2) !1 = !DIFile(filename: "bar.cpp", directory: ".") !2 = !{} !3 = !{!4} -!4 = !DICompositeType(tag: DW_TAG_structure_type, name: "Base", line: 1, size: 128, align: 64, file: !5, elements: !6, identifier: "_ZTS4Base") +!4 = !DICompositeType(tag: DW_TAG_structure_type, name: "Base", line: 1, file: !5, elements: !6, identifier: "_ZTS4Base") !5 = !DIFile(filename: "./a.hpp", directory: ".") !6 = !{!7, !9} -!7 = !DIDerivedType(tag: DW_TAG_member, name: "a", line: 2, size: 32, align: 32, file: !5, scope: !"_ZTS4Base", baseType: !8) +!7 = !DIDerivedType(tag: DW_TAG_member, name: "a", line: 2, size: 32, align: 32, file: !5, scope: !4, baseType: !8) !8 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!9 = !DIDerivedType(tag: DW_TAG_member, name: "b", line: 3, size: 64, align: 64, offset: 64, file: !5, scope: !"_ZTS4Base", baseType: !10) -!10 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !"_ZTS4Base") -!11 = !{!12, !16} -!12 = distinct !DISubprogram(name: "g", linkageName: "_Z1gi", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !13, type: !14, variables: !2) +!9 = !DIDerivedType(tag: DW_TAG_member, name: "b", line: 3, size: 64, align: 64, offset: 64, file: !5, scope: !4, baseType: !10) +!10 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: !4) +!12 = distinct !DISubprogram(name: "g", linkageName: "_Z1gi", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, unit: !0, scopeLine: 4, file: !1, scope: !13, type: !14, variables: !2) !13 = !DIFile(filename: "bar.cpp", directory: ".") !14 = !DISubroutineType(types: !15) !15 = !{null, !8} -!16 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !13, type: !17, variables: !2) +!16 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, unit: !0, scopeLine: 7, file: !1, scope: !13, type: !17, variables: !2) !17 = !DISubroutineType(types: !18) !18 = !{!8} !19 = !{i32 2, !"Dwarf Version", i32 2} |
