diff options
author | Peter Collingbourne <peter@pcc.me.uk> | 2015-11-05 22:03:56 +0000 |
---|---|---|
committer | Peter Collingbourne <peter@pcc.me.uk> | 2015-11-05 22:03:56 +0000 |
commit | 5f220beefcb655de6aae7c80b456fd4e5cb76ac0 (patch) | |
tree | d478c6bd28ca4a860f194ccd49ec67aa8f6b062e /test | |
parent | cc5dc01d7f7b6acdc7160fe30fda00e3b1b48687 (diff) |
DI: Reverse direction of subprogram -> function edge.
Previously, subprograms contained a metadata reference to the function they
described. Because most clients need to get or set a subprogram for a given
function rather than the other way around, this created unneeded inefficiency.
For example, many passes needed to call the function llvm::makeSubprogramMap()
to build a mapping from functions to subprograms, and the IR linker needed to
fix up function references in a way that caused quadratic complexity in the IR
linking phase of LTO.
This change reverses the direction of the edge by storing the subprogram as
function-level metadata and removing DISubprogram's function field.
Since this is an IR change, a bitcode upgrade has been provided.
Fixes PR23367. An upgrade script for textual IR for out-of-tree clients is
attached to the PR.
Differential Revision: http://reviews.llvm.org/D14265
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@252219 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
370 files changed, 1143 insertions, 1125 deletions
diff --git a/test/Assembler/2010-02-05-FunctionLocalMetadataBecomesNull.ll b/test/Assembler/2010-02-05-FunctionLocalMetadataBecomesNull.ll index 2bee76dea4e..0a2462610ac 100644 --- a/test/Assembler/2010-02-05-FunctionLocalMetadataBecomesNull.ll +++ b/test/Assembler/2010-02-05-FunctionLocalMetadataBecomesNull.ll @@ -10,7 +10,7 @@ target triple = "x86_64-apple-darwin10.2" @TestArrayPtr = global %struct.test* getelementptr inbounds ([10 x %struct.test], [10 x %struct.test]* @TestArray, i64 0, i64 3) ; <%struct.test**> [#uses=1] @TestArray = common global [10 x %struct.test] zeroinitializer, align 32 ; <[10 x %struct.test]*> [#uses=2] -define i32 @main() nounwind readonly { +define i32 @main() nounwind readonly !dbg !1 { %diff1 = alloca i64 ; <i64*> [#uses=2] ; CHECK: call void @llvm.dbg.value(metadata i64 72, call void @llvm.dbg.declare(metadata i64* %diff1, metadata !0, metadata !DIExpression()), !dbg !DILocation(scope: !1) @@ -27,7 +27,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !7 = !{!1} !6 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 (trunk 131941)", isOptimized: true, emissionKind: 0, file: !8, enums: !9, retainedTypes: !9, subprograms: !7) !0 = !DILocalVariable(name: "c", line: 2, scope: !1, file: !2, type: !5) -!1 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !8, scope: !2, type: !3, function: i32 ()* @main) +!1 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !8, scope: !2, type: !3) !2 = !DIFile(filename: "/d/j/debug-test.c", directory: "/Volumes/Data/b") !3 = !DISubroutineType(types: !4) !4 = !{!5} diff --git a/test/Assembler/disubprogram.ll b/test/Assembler/disubprogram.ll index e5f7963d6e9..af60f52eb21 100644 --- a/test/Assembler/disubprogram.ll +++ b/test/Assembler/disubprogram.ll @@ -1,7 +1,10 @@ ; RUN: llvm-as < %s | llvm-dis | llvm-as | llvm-dis | FileCheck %s ; RUN: verify-uselistorder %s -declare void @_Z3foov() +; CHECK: define void @_Z3foov() !dbg !9 +define void @_Z3foov() !dbg !9 { + ret void +} ; CHECK: !named = !{!0, !1, !2, !3, !4, !5, !6, !7, !8, !9} !named = !{!0, !1, !2, !3, !4, !5, !6, !7, !8, !9} @@ -20,10 +23,13 @@ declare void @_Z3foov() ; CHECK: !8 = !DISubprogram(scope: null, isLocal: false, isDefinition: false, isOptimized: false) !8 = !DISubprogram(isDefinition: false) -; CHECK: !9 = distinct !DISubprogram(name: "foo", linkageName: "_Zfoov", scope: !1, file: !2, line: 7, type: !3, isLocal: true, isDefinition: true, scopeLine: 8, containingType: !4, virtuality: DW_VIRTUALITY_pure_virtual, virtualIndex: 10, flags: DIFlagPrototyped, isOptimized: true, function: void ()* @_Z3foov, templateParams: !5, declaration: !8, variables: !6) +; CHECK: !9 = distinct !DISubprogram(name: "foo", linkageName: "_Zfoov", scope: !1, file: !2, line: 7, type: !3, isLocal: true, isDefinition: true, scopeLine: 8, containingType: !4, virtuality: DW_VIRTUALITY_pure_virtual, virtualIndex: 10, flags: DIFlagPrototyped, isOptimized: true, templateParams: !5, declaration: !8, variables: !6) !9 = distinct !DISubprogram(name: "foo", linkageName: "_Zfoov", scope: !1, file: !2, line: 7, type: !3, isLocal: true, isDefinition: true, scopeLine: 8, containingType: !4, virtuality: DW_VIRTUALITY_pure_virtual, virtualIndex: 10, - flags: DIFlagPrototyped, isOptimized: true, function: void ()* @_Z3foov, + flags: DIFlagPrototyped, isOptimized: true, templateParams: !5, declaration: !8, variables: !6) + +!10 = !{i32 1, !"Debug Info Version", i32 3} +!llvm.module.flags = !{!10} diff --git a/test/Assembler/drop-debug-info.ll b/test/Assembler/drop-debug-info.ll index c4338c41532..13e0c32718e 100644 --- a/test/Assembler/drop-debug-info.ll +++ b/test/Assembler/drop-debug-info.ll @@ -2,7 +2,7 @@ ; RUN: llvm-dis < %t.bc | FileCheck %s ; RUN: verify-uselistorder < %t.bc -define i32 @main() { +define i32 @main() !dbg !4 { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval @@ -16,7 +16,7 @@ entry: !1 = !DIFile(filename: "../llvm/tools/clang/test/CodeGen/debug-info-version.c", directory: "/Users/manmanren/llvm_gmail/release") !2 = !{i32 0} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "../llvm/tools/clang/test/CodeGen/debug-info-version.c", directory: "/Users/manmanren/llvm_gmail/release") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/Bitcode/upgrade-subprogram.ll b/test/Bitcode/upgrade-subprogram.ll new file mode 100644 index 00000000000..8d5c000a148 --- /dev/null +++ b/test/Bitcode/upgrade-subprogram.ll @@ -0,0 +1,17 @@ +; RUN: llvm-dis < %s.bc | FileCheck %s +; RUN: verify-uselistorder < %s.bc + +; CHECK: define void @foo() !dbg [[SP:![0-9]+]] +define void @foo() { + ret void +} + +!llvm.module.flags = !{!0} +!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) +!2 = !DIFile(filename: "foo.c", directory: "/path/to/dir") +; CHECK: [[SP]] = distinct !DISubprogram +!3 = distinct !DISubprogram(file: !2, scope: !2, line: 51, name: "foo", function: void ()* @foo, type: !4) +!4 = !DISubroutineType(types: !{}) diff --git a/test/Bitcode/upgrade-subprogram.ll.bc b/test/Bitcode/upgrade-subprogram.ll.bc Binary files differnew file mode 100644 index 00000000000..cfab5a2c76a --- /dev/null +++ b/test/Bitcode/upgrade-subprogram.ll.bc diff --git a/test/CodeGen/AArch64/aarch64-2014-08-11-MachineCombinerCrash.ll b/test/CodeGen/AArch64/aarch64-2014-08-11-MachineCombinerCrash.ll index 6d3abc8e4f4..5eb455f3a22 100644 --- a/test/CodeGen/AArch64/aarch64-2014-08-11-MachineCombinerCrash.ll +++ b/test/CodeGen/AArch64/aarch64-2014-08-11-MachineCombinerCrash.ll @@ -3,7 +3,7 @@ ; Bug 20598 -define void @test() #0 { +define void @test() #0 !dbg !4 { entry: br label %for.body, !dbg !39 @@ -48,7 +48,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "test.c", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "", line: 140, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 141, file: !1, scope: !1, type: !6, function: void ()* @test, variables: !12) +!4 = distinct !DISubprogram(name: "", line: 140, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 141, file: !1, scope: !1, type: !6, variables: !12) !6 = !DISubroutineType(types: !7) !7 = !{null, !8} !8 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !9) diff --git a/test/CodeGen/AMDGPU/llvm.dbg.value.ll b/test/CodeGen/AMDGPU/llvm.dbg.value.ll index dad47620bac..a54c48b25f8 100644 --- a/test/CodeGen/AMDGPU/llvm.dbg.value.ll +++ b/test/CodeGen/AMDGPU/llvm.dbg.value.ll @@ -5,7 +5,7 @@ ; CHECK: DEBUG_VALUE: test_debug_value:globalptr_arg <- SGPR0_SGPR1 ; CHECK: buffer_store_dword ; CHECK: s_endpgm -define void @test_debug_value(i32 addrspace(1)* nocapture %globalptr_arg) #0 { +define void @test_debug_value(i32 addrspace(1)* nocapture %globalptr_arg) #0 !dbg !4 { entry: tail call void @llvm.dbg.value(metadata i32 addrspace(1)* %globalptr_arg, i64 0, metadata !10, metadata !13), !dbg !14 store i32 123, i32 addrspace(1)* %globalptr_arg, align 4 @@ -24,7 +24,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "/tmp/test_debug_value.cl", directory: "/Users/matt/src/llvm/build_debug") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "test_debug_value", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, flags: DIFlagPrototyped, isOptimized: true, function: void (i32 addrspace(1)*)* @test_debug_value, variables: !9) +!4 = distinct !DISubprogram(name: "test_debug_value", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, flags: DIFlagPrototyped, isOptimized: true, variables: !9) !5 = !DISubroutineType(types: !6) !6 = !{null, !7} !7 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: !8, size: 64, align: 32) diff --git a/test/CodeGen/ARM/2010-08-04-StackVariable.ll b/test/CodeGen/ARM/2010-08-04-StackVariable.ll index 06d090a1be0..14ddb59b538 100644 --- a/test/CodeGen/ARM/2010-08-04-StackVariable.ll +++ b/test/CodeGen/ARM/2010-08-04-StackVariable.ll @@ -3,7 +3,7 @@ %struct.SVal = type { i8*, i32 } -define i32 @_Z3fooi4SVal(i32 %i, %struct.SVal* noalias %location) nounwind ssp { +define i32 @_Z3fooi4SVal(i32 %i, %struct.SVal* noalias %location) nounwind ssp !dbg !17 { entry: %"alloca point" = bitcast i32 0 to i32 ; <i32> [#uses=0] call void @llvm.dbg.value(metadata i32 %i, i64 0, metadata !23, metadata !DIExpression()), !dbg !24 @@ -31,7 +31,7 @@ return: ; preds = %bb2 ret i32 %.0, !dbg !29 } -define linkonce_odr void @_ZN4SValC1Ev(%struct.SVal* %this) nounwind ssp align 2 { +define linkonce_odr void @_ZN4SValC1Ev(%struct.SVal* %this) nounwind ssp align 2 !dbg !16 { entry: %"alloca point" = bitcast i32 0 to i32 ; <i32> [#uses=0] call void @llvm.dbg.value(metadata %struct.SVal* %this, i64 0, metadata !31, metadata !DIExpression()), !dbg !34 @@ -47,7 +47,7 @@ return: ; preds = %entry declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone -define i32 @main() nounwind ssp { +define i32 @main() nounwind ssp !dbg !20 { entry: %0 = alloca %struct.SVal ; <%struct.SVal*> [#uses=3] %v = alloca %struct.SVal ; <%struct.SVal*> [#uses=4] @@ -93,11 +93,11 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !13 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !14 = !DISubroutineType(types: !15) !15 = !{null, !12} -!16 = distinct !DISubprogram(name: "SVal", linkageName: "_ZN4SValC1Ev", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !48, scope: !1, type: !14, function: void (%struct.SVal*)* @_ZN4SValC1Ev) -!17 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooi4SVal", line: 16, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !48, scope: !2, type: !18, function: i32 (i32, %struct.SVal*)* @_Z3fooi4SVal) +!16 = distinct !DISubprogram(name: "SVal", linkageName: "_ZN4SValC1Ev", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !48, scope: !1, type: !14) +!17 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooi4SVal", line: 16, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !48, scope: !2, type: !18) !18 = !DISubroutineType(types: !19) !19 = !{!13, !13, !1} -!20 = distinct !DISubprogram(name: "main", linkageName: "main", line: 23, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !48, scope: !2, type: !21, function: i32 ()* @main) +!20 = distinct !DISubprogram(name: "main", linkageName: "main", line: 23, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !48, scope: !2, type: !21) !21 = !DISubroutineType(types: !22) !22 = !{!13} !23 = !DILocalVariable(name: "i", line: 16, arg: 1, scope: !17, file: !2, type: !13) diff --git a/test/CodeGen/ARM/2011-01-19-MergedGlobalDbg.ll b/test/CodeGen/ARM/2011-01-19-MergedGlobalDbg.ll index 147255176cc..d5eed8b6a2c 100644 --- a/test/CodeGen/ARM/2011-01-19-MergedGlobalDbg.ll +++ b/test/CodeGen/ARM/2011-01-19-MergedGlobalDbg.ll @@ -28,7 +28,7 @@ target triple = "thumbv7-apple-darwin10" ; CHECK-NOT: {{DW_TAG|NULL}} ; CHECK: DW_AT_location [DW_FORM_exprloc] (<0x8> 03 [[ADDR]] 10 01 22 ) -define zeroext i8 @get1(i8 zeroext %a) nounwind optsize { +define zeroext i8 @get1(i8 zeroext %a) nounwind optsize !dbg !0 { entry: tail call void @llvm.dbg.value(metadata i8 %a, i64 0, metadata !10, metadata !DIExpression()), !dbg !30 %0 = load i8, i8* @x1, align 4, !dbg !30 @@ -39,7 +39,7 @@ entry: declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnone -define zeroext i8 @get2(i8 zeroext %a) nounwind optsize { +define zeroext i8 @get2(i8 zeroext %a) nounwind optsize !dbg !6 { entry: tail call void @llvm.dbg.value(metadata i8 %a, i64 0, metadata !18, metadata !DIExpression()), !dbg !32 %0 = load i8, i8* @x2, align 4, !dbg !32 @@ -48,7 +48,7 @@ entry: ret i8 %0, !dbg !33 } -define zeroext i8 @get3(i8 zeroext %a) nounwind optsize { +define zeroext i8 @get3(i8 zeroext %a) nounwind optsize !dbg !7 { entry: tail call void @llvm.dbg.value(metadata i8 %a, i64 0, metadata !21, metadata !DIExpression()), !dbg !34 %0 = load i8, i8* @x3, align 4, !dbg !34 @@ -57,7 +57,7 @@ entry: ret i8 %0, !dbg !35 } -define zeroext i8 @get4(i8 zeroext %a) nounwind optsize { +define zeroext i8 @get4(i8 zeroext %a) nounwind optsize !dbg !8 { entry: tail call void @llvm.dbg.value(metadata i8 %a, i64 0, metadata !24, metadata !DIExpression()), !dbg !36 %0 = load i8, i8* @x4, align 4, !dbg !36 @@ -66,7 +66,7 @@ entry: ret i8 %0, !dbg !37 } -define zeroext i8 @get5(i8 zeroext %a) nounwind optsize { +define zeroext i8 @get5(i8 zeroext %a) nounwind optsize !dbg !9 { entry: tail call void @llvm.dbg.value(metadata i8 %a, i64 0, metadata !27, metadata !DIExpression()), !dbg !38 %0 = load i8, i8* @x5, align 4, !dbg !38 @@ -78,16 +78,16 @@ entry: !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!49} -!0 = distinct !DISubprogram(name: "get1", linkageName: "get1", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 4, file: !47, scope: !1, type: !3, function: i8 (i8)* @get1, variables: !42) +!0 = distinct !DISubprogram(name: "get1", linkageName: "get1", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 4, file: !47, scope: !1, type: !3, variables: !42) !1 = !DIFile(filename: "foo.c", directory: "/tmp/") !2 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2369.8)", isOptimized: true, emissionKind: 0, file: !47, enums: !48, retainedTypes: !48, subprograms: !40, globals: !41, imports: !48) !3 = !DISubroutineType(types: !4) !4 = !{!5, !5} !5 = !DIBasicType(tag: DW_TAG_base_type, name: "_Bool", size: 8, align: 8, encoding: DW_ATE_boolean) -!6 = distinct !DISubprogram(name: "get2", linkageName: "get2", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 7, file: !47, scope: !1, type: !3, function: i8 (i8)* @get2, variables: !43) -!7 = distinct !DISubprogram(name: "get3", linkageName: "get3", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 10, file: !47, scope: !1, type: !3, function: i8 (i8)* @get3, variables: !44) -!8 = distinct !DISubprogram(name: "get4", linkageName: "get4", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 13, file: !47, scope: !1, type: !3, function: i8 (i8)* @get4, variables: !45) -!9 = distinct !DISubprogram(name: "get5", linkageName: "get5", line: 16, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 16, file: !47, scope: !1, type: !3, function: i8 (i8)* @get5, variables: !46) +!6 = distinct !DISubprogram(name: "get2", linkageName: "get2", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 7, file: !47, scope: !1, type: !3, variables: !43) +!7 = distinct !DISubprogram(name: "get3", linkageName: "get3", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 10, file: !47, scope: !1, type: !3, variables: !44) +!8 = distinct !DISubprogram(name: "get4", linkageName: "get4", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 13, file: !47, scope: !1, type: !3, variables: !45) +!9 = distinct !DISubprogram(name: "get5", linkageName: "get5", line: 16, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 16, file: !47, scope: !1, type: !3, variables: !46) !10 = !DILocalVariable(name: "a", line: 4, arg: 1, scope: !0, file: !1, type: !5) !11 = !DILocalVariable(name: "b", line: 4, scope: !12, file: !1, type: !5) !12 = distinct !DILexicalBlock(line: 4, column: 0, file: !47, scope: !0) diff --git a/test/CodeGen/ARM/2011-08-02-MergedGlobalDbg.ll b/test/CodeGen/ARM/2011-08-02-MergedGlobalDbg.ll index cfdc1debc6a..3d82e706862 100644 --- a/test/CodeGen/ARM/2011-08-02-MergedGlobalDbg.ll +++ b/test/CodeGen/ARM/2011-08-02-MergedGlobalDbg.ll @@ -28,7 +28,7 @@ target triple = "thumbv7-apple-macosx10.7.0" @x4 = internal unnamed_addr global i32 4, align 4 @x5 = global i32 0, align 4 -define i32 @get1(i32 %a) nounwind optsize ssp { +define i32 @get1(i32 %a) nounwind optsize ssp !dbg !1 { tail call void @llvm.dbg.value(metadata i32 %a, i64 0, metadata !10, metadata !DIExpression()), !dbg !30 %1 = load i32, i32* @x1, align 4, !dbg !31 tail call void @llvm.dbg.value(metadata i32 %1, i64 0, metadata !11, metadata !DIExpression()), !dbg !31 @@ -36,7 +36,7 @@ define i32 @get1(i32 %a) nounwind optsize ssp { ret i32 %1, !dbg !31 } -define i32 @get2(i32 %a) nounwind optsize ssp { +define i32 @get2(i32 %a) nounwind optsize ssp !dbg !6 { tail call void @llvm.dbg.value(metadata i32 %a, i64 0, metadata !13, metadata !DIExpression()), !dbg !32 %1 = load i32, i32* @x2, align 4, !dbg !33 tail call void @llvm.dbg.value(metadata i32 %1, i64 0, metadata !14, metadata !DIExpression()), !dbg !33 @@ -44,7 +44,7 @@ define i32 @get2(i32 %a) nounwind optsize ssp { ret i32 %1, !dbg !33 } -define i32 @get3(i32 %a) nounwind optsize ssp { +define i32 @get3(i32 %a) nounwind optsize ssp !dbg !7 { tail call void @llvm.dbg.value(metadata i32 %a, i64 0, metadata !16, metadata !DIExpression()), !dbg !34 %1 = load i32, i32* @x3, align 4, !dbg !35 tail call void @llvm.dbg.value(metadata i32 %1, i64 0, metadata !17, metadata !DIExpression()), !dbg !35 @@ -52,7 +52,7 @@ define i32 @get3(i32 %a) nounwind optsize ssp { ret i32 %1, !dbg !35 } -define i32 @get4(i32 %a) nounwind optsize ssp { +define i32 @get4(i32 %a) nounwind optsize ssp !dbg !8 { tail call void @llvm.dbg.value(metadata i32 %a, i64 0, metadata !19, metadata !DIExpression()), !dbg !36 %1 = load i32, i32* @x4, align 4, !dbg !37 tail call void @llvm.dbg.value(metadata i32 %1, i64 0, metadata !20, metadata !DIExpression()), !dbg !37 @@ -60,7 +60,7 @@ define i32 @get4(i32 %a) nounwind optsize ssp { ret i32 %1, !dbg !37 } -define i32 @get5(i32 %a) nounwind optsize ssp { +define i32 @get5(i32 %a) nounwind optsize ssp !dbg !9 { tail call void @llvm.dbg.value(metadata i32 %a, i64 0, metadata !27, metadata !DIExpression()), !dbg !38 %1 = load i32, i32* @x5, align 4, !dbg !39 tail call void @llvm.dbg.value(metadata i32 %1, i64 0, metadata !28, metadata !DIExpression()), !dbg !39 @@ -74,15 +74,15 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.module.flags = !{!49} !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang", isOptimized: true, emissionKind: 1, file: !47, enums: !48, retainedTypes: !48, subprograms: !40, globals: !41, imports: !48) -!1 = distinct !DISubprogram(name: "get1", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !47, scope: !2, type: !3, function: i32 (i32)* @get1, variables: !42) +!1 = distinct !DISubprogram(name: "get1", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !47, scope: !2, type: !3, variables: !42) !2 = !DIFile(filename: "ss3.c", directory: "/private/tmp") !3 = !DISubroutineType(types: !4) !4 = !{!5} !5 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!6 = distinct !DISubprogram(name: "get2", line: 8, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 8, file: !47, scope: !2, type: !3, function: i32 (i32)* @get2, variables: !43) -!7 = distinct !DISubprogram(name: "get3", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 11, file: !47, scope: !2, type: !3, function: i32 (i32)* @get3, variables: !44) -!8 = distinct !DISubprogram(name: "get4", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 14, file: !47, scope: !2, type: !3, function: i32 (i32)* @get4, variables: !45) -!9 = distinct !DISubprogram(name: "get5", line: 17, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 17, file: !47, scope: !2, type: !3, function: i32 (i32)* @get5, variables: !46) +!6 = distinct !DISubprogram(name: "get2", line: 8, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 8, file: !47, scope: !2, type: !3, variables: !43) +!7 = distinct !DISubprogram(name: "get3", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 11, file: !47, scope: !2, type: !3, variables: !44) +!8 = distinct !DISubprogram(name: "get4", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 14, file: !47, scope: !2, type: !3, variables: !45) +!9 = distinct !DISubprogram(name: "get5", line: 17, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 17, file: !47, scope: !2, type: !3, variables: !46) !10 = !DILocalVariable(name: "a", line: 5, arg: 1, scope: !1, file: !2, type: !5) !11 = !DILocalVariable(name: "b", line: 5, scope: !12, file: !2, type: !5) !12 = distinct !DILexicalBlock(line: 5, column: 19, file: !47, scope: !1) diff --git a/test/CodeGen/ARM/coalesce-dbgvalue.ll b/test/CodeGen/ARM/coalesce-dbgvalue.ll index 02ef24e9d55..4468f1ec9c4 100644 --- a/test/CodeGen/ARM/coalesce-dbgvalue.ll +++ b/test/CodeGen/ARM/coalesce-dbgvalue.ll @@ -15,7 +15,7 @@ target triple = "thumbv7-apple-ios3.0.0" @d = common global i32 0, align 4 ; Function Attrs: nounwind ssp -define i32 @pr16110() #0 { +define i32 @pr16110() #0 !dbg !4 { for.cond1.preheader: store i32 0, i32* @c, align 4, !dbg !21 br label %for.cond1.outer, !dbg !26 @@ -83,7 +83,7 @@ attributes #3 = { nounwind } !1 = !DIFile(filename: "pr16110.c", directory: "/d/b") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "pr16110", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 7, file: !1, scope: !5, type: !6, function: i32 ()* @pr16110, variables: !9) +!4 = distinct !DISubprogram(name: "pr16110", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 7, file: !1, scope: !5, type: !6, variables: !9) !5 = !DIFile(filename: "pr16110.c", directory: "/d/b") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/CodeGen/ARM/debug-frame-vararg.ll b/test/CodeGen/ARM/debug-frame-vararg.ll index 825a6aaf320..13ca20c2035 100644 --- a/test/CodeGen/ARM/debug-frame-vararg.ll +++ b/test/CodeGen/ARM/debug-frame-vararg.ll @@ -29,7 +29,7 @@ !1 = !DIFile(filename: "var.c", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "sum", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !6, function: i32 (i32, ...)* @sum, variables: !2) +!4 = distinct !DISubprogram(name: "sum", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "var.c", directory: "/tmp") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} @@ -108,7 +108,7 @@ ; CHECK-THUMB-FP-ELIM: add r7, sp, #8 ; CHECK-THUMB-FP-ELIM: .cfi_def_cfa r7, 20 -define i32 @sum(i32 %count, ...) { +define i32 @sum(i32 %count, ...) !dbg !4 { entry: %vl = alloca i8*, align 4 %vl1 = bitcast i8** %vl to i8* diff --git a/test/CodeGen/ARM/debug-frame.ll b/test/CodeGen/ARM/debug-frame.ll index da2125c0f6d..33d38969899 100644 --- a/test/CodeGen/ARM/debug-frame.ll +++ b/test/CodeGen/ARM/debug-frame.ll @@ -129,7 +129,7 @@ declare void @_ZSt9terminatev() !1 = !DIFile(filename: "exp.cpp", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "test", linkageName: "_Z4testiiiiiddddd", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !6, function: void (i32, i32, i32, i32, i32, double, double, double, double, double)* @_Z4testiiiiiddddd, variables: !2) +!4 = distinct !DISubprogram(name: "test", linkageName: "_Z4testiiiiiddddd", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "exp.cpp", directory: "/tmp") !6 = !DISubroutineType(types: !7) !7 = !{null, !8, !8, !8, !8, !8, !9, !9, !9, !9, !9} diff --git a/test/CodeGen/ARM/debug-info-arg.ll b/test/CodeGen/ARM/debug-info-arg.ll index d9fa9672156..02bd585b354 100644 --- a/test/CodeGen/ARM/debug-info-arg.ll +++ b/test/CodeGen/ARM/debug-info-arg.ll @@ -6,7 +6,7 @@ target triple = "thumbv7-apple-ios" %struct.tag_s = type { i32, i32, i32 } -define void @foo(%struct.tag_s* nocapture %this, %struct.tag_s* %c, i64 %x, i64 %y, %struct.tag_s* nocapture %ptr1, %struct.tag_s* nocapture %ptr2) nounwind ssp { +define void @foo(%struct.tag_s* nocapture %this, %struct.tag_s* %c, i64 %x, i64 %y, %struct.tag_s* nocapture %ptr1, %struct.tag_s* nocapture %ptr2) nounwind ssp !dbg !1 { tail call void @llvm.dbg.value(metadata %struct.tag_s* %this, i64 0, metadata !5, metadata !DIExpression()), !dbg !20 tail call void @llvm.dbg.value(metadata %struct.tag_s* %c, i64 0, metadata !13, metadata !DIExpression()), !dbg !21 tail call void @llvm.dbg.value(metadata i64 %x, i64 0, metadata !14, metadata !DIExpression()), !dbg !22 @@ -33,7 +33,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.module.flags = !{!33} !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "Apple clang version 3.0 (tags/Apple/clang-211.10.1) (based on LLVM 3.0svn)", isOptimized: true, emissionKind: 1, file: !32, enums: !{}, retainedTypes: !{}, subprograms: !30, imports: null) -!1 = distinct !DISubprogram(name: "foo", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 11, file: !2, scope: !2, type: !3, function: void (%struct.tag_s*, %struct.tag_s*, i64, i64, %struct.tag_s*, %struct.tag_s*)* @foo, variables: !31) +!1 = distinct !DISubprogram(name: "foo", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 11, file: !2, scope: !2, type: !3, variables: !31) !2 = !DIFile(filename: "one.c", directory: "/Volumes/Athwagate/R10048772") !3 = !DISubroutineType(types: !4) !4 = !{null} diff --git a/test/CodeGen/ARM/debug-info-blocks.ll b/test/CodeGen/ARM/debug-info-blocks.ll index bd5c51e2039..2e68b04dc5c 100644 --- a/test/CodeGen/ARM/debug-info-blocks.ll +++ b/test/CodeGen/ARM/debug-info-blocks.ll @@ -27,7 +27,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon declare void @llvm.memcpy.p0i8.p0i8.i32(i8* nocapture, i8* nocapture, i32, i32, i1) nounwind -define hidden void @foobar_func_block_invoke_0(i8* %.block_descriptor, %0* %loadedMydata, [4 x i32] %bounds.coerce0, [4 x i32] %data.coerce0) ssp { +define hidden void @foobar_func_block_invoke_0(i8* %.block_descriptor, %0* %loadedMydata, [4 x i32] %bounds.coerce0, [4 x i32] %data.coerce0) ssp !dbg !23 { %1 = alloca %0*, align 4 %bounds = alloca %struct.CR, align 4 %data = alloca %struct.CR, align 4 @@ -118,7 +118,7 @@ define hidden void @foobar_func_block_invoke_0(i8* %.block_descriptor, %0* %load !20 = !DIFile(filename: "header4.h", directory: "/Volumes/Sandbox/llvm") !21 = !{!22} !22 = !DIEnumerator(name: "Eleven", value: 0) ; [ DW_TAG_enumerator ] -!23 = distinct !DISubprogram(name: "foobar_func_block_invoke_0", line: 609, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 609, file: !152, scope: !24, type: !25, function: void (i8*, %0*, [4 x i32], [4 x i32])* @foobar_func_block_invoke_0) +!23 = distinct !DISubprogram(name: "foobar_func_block_invoke_0", line: 609, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 609, file: !152, scope: !24, type: !25) !24 = !DIFile(filename: "MyLibrary.m", directory: "/Volumes/Sandbox/llvm") !25 = !DISubroutineType(types: !26) !26 = !{null} diff --git a/test/CodeGen/ARM/debug-info-branch-folding.ll b/test/CodeGen/ARM/debug-info-branch-folding.ll index 5f5a4860cfc..ca4d8a3dabb 100644 --- a/test/CodeGen/ARM/debug-info-branch-folding.ll +++ b/test/CodeGen/ARM/debug-info-branch-folding.ll @@ -14,7 +14,7 @@ target triple = "thumbv7-apple-macosx10.6.7" declare <4 x float> @test0001(float) nounwind readnone ssp -define i32 @main(i32 %argc, i8** nocapture %argv, i1 %cond) nounwind ssp { +define i32 @main(i32 %argc, i8** nocapture %argv, i1 %cond) nounwind ssp !dbg !10 { entry: br label %for.body9 @@ -42,7 +42,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.module.flags = !{!56} !llvm.dbg.cu = !{!2} -!0 = distinct !DISubprogram(name: "test0001", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !54, scope: null, type: !3, function: <4 x float> (float)* @test0001, variables: !51) +!0 = distinct !DISubprogram(name: "test0001", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !54, scope: null, type: !3, variables: !51) !1 = !DIFile(filename: "build2.c", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 (trunk 129915)", isOptimized: true, emissionKind: 1, file: !54, enums: !{}, retainedTypes: !{}, subprograms: !50, imports: null) !3 = !DISubroutineType(types: !4) @@ -52,7 +52,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !7 = !DIBasicType(tag: DW_TAG_base_type, name: "float", size: 32, align: 32, encoding: DW_ATE_float) !8 = !{!9} !9 = !DISubrange(count: 4) -!10 = distinct !DISubprogram(name: "main", line: 59, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !54, scope: null, type: !11, function: i32 (i32, i8**, i1)* @main, variables: !52) +!10 = distinct !DISubprogram(name: "main", line: 59, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !54, scope: null, type: !11, variables: !52) !11 = !DISubroutineType(types: !12) !12 = !{!13} !13 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/CodeGen/ARM/debug-info-d16-reg.ll b/test/CodeGen/ARM/debug-info-d16-reg.ll index 60e6cd0679e..0d457d3a737 100644 --- a/test/CodeGen/ARM/debug-info-d16-reg.ll +++ b/test/CodeGen/ARM/debug-info-d16-reg.ll @@ -10,7 +10,7 @@ target triple = "thumbv7-apple-darwin10" @.str = private unnamed_addr constant [11 x i8] c"%p %lf %c\0A\00", align 4 @.str1 = private unnamed_addr constant [6 x i8] c"point\00", align 4 -define i32 @inlineprinter(i8* %ptr, double %val, i8 zeroext %c) nounwind optsize { +define i32 @inlineprinter(i8* %ptr, double %val, i8 zeroext %c) nounwind optsize !dbg !9 { entry: tail call void @llvm.dbg.value(metadata i8* %ptr, i64 0, metadata !19, metadata !DIExpression()), !dbg !26 tail call void @llvm.dbg.value(metadata double %val, i64 0, metadata !20, metadata !DIExpression()), !dbg !26 @@ -20,7 +20,7 @@ entry: ret i32 0, !dbg !29 } -define i32 @printer(i8* %ptr, double %val, i8 zeroext %c) nounwind optsize noinline { +define i32 @printer(i8* %ptr, double %val, i8 zeroext %c) nounwind optsize noinline !dbg !0 { entry: tail call void @llvm.dbg.value(metadata i8* %ptr, i64 0, metadata !16, metadata !DIExpression()), !dbg !30 tail call void @llvm.dbg.value(metadata double %val, i64 0, metadata !17, metadata !DIExpression()), !dbg !30 @@ -34,7 +34,7 @@ declare i32 @printf(i8* nocapture, ...) nounwind declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnone -define i32 @main(i32 %argc, i8** nocapture %argv) nounwind optsize { +define i32 @main(i32 %argc, i8** nocapture %argv) nounwind optsize !dbg !10 { entry: tail call void @llvm.dbg.value(metadata i32 %argc, i64 0, metadata !22, metadata !DIExpression()), !dbg !34 tail call void @llvm.dbg.value(metadata i8** %argv, i64 0, metadata !23, metadata !DIExpression()), !dbg !34 @@ -59,7 +59,7 @@ declare i32 @puts(i8* nocapture) nounwind !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!48} -!0 = distinct !DISubprogram(name: "printer", linkageName: "printer", line: 12, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 12, file: !46, scope: !1, type: !3, function: i32 (i8*, double, i8)* @printer, variables: !43) +!0 = distinct !DISubprogram(name: "printer", linkageName: "printer", line: 12, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 12, file: !46, scope: !1, type: !3, variables: !43) !1 = !DIFile(filename: "a.c", directory: "/tmp/") !2 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "(LLVM build 00)", isOptimized: true, emissionKind: 1, file: !46, enums: !47, retainedTypes: !47, subprograms: !42, imports: null) !3 = !DISubroutineType(types: !4) @@ -68,8 +68,8 @@ declare i32 @puts(i8* nocapture) nounwind !6 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 32, align: 32, file: !46, scope: !1, baseType: null) !7 = !DIBasicType(tag: DW_TAG_base_type, name: "double", size: 64, align: 32, encoding: DW_ATE_float) !8 = !DIBasicType(tag: DW_TAG_base_type, name: "unsigned char", size: 8, align: 8, encoding: DW_ATE_unsigned_char) -!9 = distinct !DISubprogram(name: "inlineprinter", linkageName: "inlineprinter", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !46, scope: !1, type: !3, function: i32 (i8*, double, i8)* @inlineprinter, variables: !44) -!10 = distinct !DISubprogram(name: "main", linkageName: "main", line: 18, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 18, file: !46, scope: !1, type: !11, function: i32 (i32, i8**)* @main, variables: !45) +!9 = distinct !DISubprogram(name: "inlineprinter", linkageName: "inlineprinter", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !46, scope: !1, type: !3, variables: !44) +!10 = distinct !DISubprogram(name: "main", linkageName: "main", line: 18, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 18, file: !46, scope: !1, type: !11, variables: !45) !11 = !DISubroutineType(types: !12) !12 = !{!5, !5, !13} !13 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 32, align: 32, file: !46, scope: !1, baseType: !14) diff --git a/test/CodeGen/ARM/debug-info-no-frame.ll b/test/CodeGen/ARM/debug-info-no-frame.ll index 039a6720b69..d77a195b952 100644 --- a/test/CodeGen/ARM/debug-info-no-frame.ll +++ b/test/CodeGen/ARM/debug-info-no-frame.ll @@ -1,7 +1,7 @@ ; RUN: llc -mtriple=armv7-none-linux-gnueabihf < %s -o - | FileCheck %s ; Function Attrs: nounwind -define void @need_cfi_def_cfa_offset() #0 { +define void @need_cfi_def_cfa_offset() #0 !dbg !3 { ; CHECK-LABEL: need_cfi_def_cfa_offset: ; CHECK: sub sp, sp, #4 ; CHECK: .cfi_def_cfa_offset 4 @@ -24,7 +24,7 @@ attributes #1 = { nounwind readnone } !0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "", isOptimized: false, subprograms: !{!3}) !1 = !DIFile(filename: "file.c", directory: "/dir") !2 = !{} -!3 = distinct !DISubprogram(name: "need_cfi_def_cfa_offset", scope: !1, file: !1, line: 1, type: !4, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: false, function: void ()* @need_cfi_def_cfa_offset, variables: !2) +!3 = distinct !DISubprogram(name: "need_cfi_def_cfa_offset", scope: !1, file: !1, line: 1, type: !4, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: false, variables: !2) !4 = !DISubroutineType(types: !5) !5 = !{null} !6 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/CodeGen/ARM/debug-info-qreg.ll b/test/CodeGen/ARM/debug-info-qreg.ll index 1052a86bb83..1cd90d43364 100644 --- a/test/CodeGen/ARM/debug-info-qreg.ll +++ b/test/CodeGen/ARM/debug-info-qreg.ll @@ -15,7 +15,7 @@ target triple = "thumbv7-apple-macosx10.6.7" declare <4 x float> @test0001(float) nounwind readnone ssp -define i32 @main(i32 %argc, i8** nocapture %argv) nounwind ssp { +define i32 @main(i32 %argc, i8** nocapture %argv) nounwind ssp !dbg !10 { entry: br label %for.body9 @@ -38,7 +38,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!56} -!0 = distinct !DISubprogram(name: "test0001", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !54, scope: !1, type: !3, function: <4 x float> (float)* @test0001, variables: !51) +!0 = distinct !DISubprogram(name: "test0001", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !54, scope: !1, type: !3, variables: !51) !1 = !DIFile(filename: "build2.c", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 (trunk 129915)", isOptimized: true, emissionKind: 1, file: !54, enums: !{}, retainedTypes: !{}, subprograms: !50, imports: null) !3 = !DISubroutineType(types: !4) @@ -48,7 +48,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !7 = !DIBasicType(tag: DW_TAG_base_type, name: "float", size: 32, align: 32, encoding: DW_ATE_float) !8 = !{!9} !9 = !DISubrange(count: 4) -!10 = distinct !DISubprogram(name: "main", line: 59, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 59, file: !54, scope: !1, type: !11, function: i32 (i32, i8**)* @main, variables: !52) +!10 = distinct !DISubprogram(name: "main", line: 59, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 59, file: !54, scope: !1, type: !11, variables: !52) !11 = !DISubroutineType(types: !12) !12 = !{!13} !13 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/CodeGen/ARM/debug-info-s16-reg.ll b/test/CodeGen/ARM/debug-info-s16-reg.ll index f1741158ef5..654aa4545ca 100644 --- a/test/CodeGen/ARM/debug-info-s16-reg.ll +++ b/test/CodeGen/ARM/debug-info-s16-reg.ll @@ -12,7 +12,7 @@ target triple = "thumbv7-apple-macosx10.6.7" @.str = private unnamed_addr constant [11 x i8] c"%p %lf %c\0A\00" @.str1 = private unnamed_addr constant [6 x i8] c"point\00" -define i32 @inlineprinter(i8* %ptr, float %val, i8 zeroext %c) nounwind optsize ssp { +define i32 @inlineprinter(i8* %ptr, float %val, i8 zeroext %c) nounwind optsize ssp !dbg !0 { entry: tail call void @llvm.dbg.value(metadata i8* %ptr, i64 0, metadata !8, metadata !DIExpression()), !dbg !24 tail call void @llvm.dbg.value(metadata float %val, i64 0, metadata !10, metadata !DIExpression()), !dbg !25 @@ -25,7 +25,7 @@ entry: declare i32 @printf(i8* nocapture, ...) nounwind optsize -define i32 @printer(i8* %ptr, float %val, i8 zeroext %c) nounwind optsize noinline ssp { +define i32 @printer(i8* %ptr, float %val, i8 zeroext %c) nounwind optsize noinline ssp !dbg !6 { entry: tail call void @llvm.dbg.value(metadata i8* %ptr, i64 0, metadata !14, metadata !DIExpression()), !dbg !30 tail call void @llvm.dbg.value(metadata float %val, i64 0, metadata !15, metadata !DIExpression()), !dbg !31 @@ -36,7 +36,7 @@ entry: ret i32 0, !dbg !35 } -define i32 @main(i32 %argc, i8** nocapture %argv) nounwind optsize ssp { +define i32 @main(i32 %argc, i8** nocapture %argv) nounwind optsize ssp !dbg !7 { entry: tail call void @llvm.dbg.value(metadata i32 %argc, i64 0, metadata !17, metadata !DIExpression()), !dbg !36 tail call void @llvm.dbg.value(metadata i8** %argv, i64 0, metadata !18, metadata !DIExpression()), !dbg !37 @@ -65,14 +65,14 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!53} -!0 = distinct !DISubprogram(name: "inlineprinter", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !51, scope: !1, type: !3, function: i32 (i8*, float, i8)* @inlineprinter, variables: !48) +!0 = distinct !DISubprogram(name: "inlineprinter", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !51, scope: !1, type: !3, variables: !48) !1 = !DIFile(filename: "a.c", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 (trunk 129915)", isOptimized: true, emissionKind: 1, file: !51, enums: !52, retainedTypes: !52, subprograms: !47, imports: null) !3 = !DISubroutineType(types: !4) !4 = !{!5} !5 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!6 = distinct !DISubprogram(name: "printer", line: 12, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 12, file: !51, scope: !1, type: !3, function: i32 (i8*, float, i8)* @printer, variables: !49) -!7 = distinct !DISubprogram(name: "main", line: 18, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 18, file: !51, scope: !1, type: !3, function: i32 (i32, i8**)* @main, variables: !50) +!6 = distinct !DISubprogram(name: "printer", line: 12, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 12, file: !51, scope: !1, type: !3, variables: !49) +!7 = distinct !DISubprogram(name: "main", line: 18, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 18, file: !51, scope: !1, type: !3, variables: !50) !8 = !DILocalVariable(name: "ptr", line: 4, arg: 1, scope: !0, file: !1, type: !9) !9 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 32, align: 32, scope: !2, baseType: null) !10 = !DILocalVariable(name: "val", line: 4, arg: 2, scope: !0, file: !1, type: !11) diff --git a/test/CodeGen/ARM/debug-info-sreg2.ll b/test/CodeGen/ARM/debug-info-sreg2.ll index 9d086d7fba5..eadf1b48156 100644 --- a/test/CodeGen/ARM/debug-info-sreg2.ll +++ b/test/CodeGen/ARM/debug-info-sreg2.ll @@ -12,7 +12,7 @@ target triple = "thumbv7-apple-macosx10.6.7" ; CHECK-NEXT: Ending address offset: ; CHECK-NEXT: Location description: 90 {{.. .. .. .. $}} -define void @_Z3foov() optsize ssp { +define void @_Z3foov() optsize ssp !dbg !1 { entry: %call = tail call float @_Z3barv() optsize, !dbg !11 tail call void @llvm.dbg.value(metadata float %call, i64 0, metadata !5, metadata !DIExpression()), !dbg !11 @@ -44,7 +44,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.module.flags = !{!20} !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.0 (trunk 130845)", isOptimized: true, emissionKind: 1, file: !18, enums: !19, retainedTypes: !19, subprograms: !16, imports: null) -!1 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foov", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !18, scope: !2, type: !3, function: void ()* @_Z3foov, variables: !17) +!1 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foov", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !18, scope: !2, type: !3, variables: !17) !2 = !DIFile(filename: "k.cc", directory: "/private/tmp") !3 = !DISubroutineType(types: !4) !4 = !{null} diff --git a/test/CodeGen/ARM/debug-segmented-stacks.ll b/test/CodeGen/ARM/debug-segmented-stacks.ll index 7428e54250e..bd0abedc413 100644 --- a/test/CodeGen/ARM/debug-segmented-stacks.ll +++ b/test/CodeGen/ARM/debug-segmented-stacks.ll @@ -5,7 +5,7 @@ !llvm.module.flags = !{!9, !10} !llvm.ident = !{!11} -define void @test_basic() #0 { +define void @test_basic() #0 !dbg !4 { %mem = alloca i32, i32 10 call void @dummy_use (i32* %mem, i32 10) ret void @@ -43,7 +43,7 @@ define void @test_basic() #0 { !1 = !DIFile(filename: "var.c", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "test_basic", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !6, function: void ()* @test_basic, variables: !2) +!4 = distinct !DISubprogram(name: "test_basic", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "var.c", directory: "/tmp") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} diff --git a/test/CodeGen/ARM/sched-it-debug-nodes.ll b/test/CodeGen/ARM/sched-it-debug-nodes.ll index e605acb51c8..854ba073593 100644 --- a/test/CodeGen/ARM/sched-it-debug-nodes.ll +++ b/test/CodeGen/ARM/sched-it-debug-nodes.ll @@ -7,7 +7,7 @@ target triple = "thumbv7" %struct.s = type opaque ; Function Attrs: nounwind -define arm_aapcscc i32 @f(%struct.s* %s, i32 %u, i8* %b, i32 %n) #0 { +define arm_aapcscc i32 @f(%struct.s* %s, i32 %u, i8* %b, i32 %n) #0 !dbg !4 { entry: tail call void @llvm.dbg.value(metadata %struct.s* %s, i64 0, metadata !19, metadata !28), !dbg !29 tail call void @llvm.dbg.value(metadata i32 %u, i64 0, metadata !20, metadata !28), !dbg !29 @@ -54,7 +54,7 @@ attributes #3 = { nounwind } !1 = !DIFile(filename: "<stdin>", directory: "/Users/compnerd/Source/llvm") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f", scope: !5, file: !5, line: 9, type: !6, isLocal: false, isDefinition: true, scopeLine: 9, flags: DIFlagPrototyped, isOptimized: true, function: i32 (%struct.s*, i32, i8*, i32)* @f, variables: !18) +!4 = distinct !DISubprogram(name: "f", scope: !5, file: !5, line: 9, type: !6, isLocal: false, isDefinition: true, scopeLine: 9, flags: DIFlagPrototyped, isOptimized: true, variables: !18) !5 = !DIFile(filename: "<stdin>", directory: "/Users/compnerd/Source/llvm") !6 = !DISubroutineType(types: !7) !7 = !{!8, !9, !12, !13, !17} diff --git a/test/CodeGen/ARM/vfp-regs-dwarf.ll b/test/CodeGen/ARM/vfp-regs-dwarf.ll index 29c9fd0dcc8..1b2055e5aff 100644 --- a/test/CodeGen/ARM/vfp-regs-dwarf.ll +++ b/test/CodeGen/ARM/vfp-regs-dwarf.ll @@ -10,7 +10,7 @@ ; the layout of the VFP registers correctly. The fact that the numbers are ; monotonic in memory is also a nice property to have. -define void @stack_offsets() { +define void @stack_offsets() !dbg !4 { ; CHECK-LABEL: stack_offsets: ; CHECK: vpush {d13} ; CHECK: vpush {d11} @@ -35,7 +35,7 @@ define void @stack_offsets() { !1 = !DIFile(filename: "tmp.c", directory: "/Users/tim/llvm/build") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "bar", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: void ()* @stack_offsets, variables: !2) +!4 = distinct !DISubprogram(name: "bar", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "tmp.c", directory: "/Users/tim/llvm/build") !6 = !DISubroutineType(types: !7) !7 = !{null} diff --git a/test/CodeGen/Hexagon/cfi-late.ll b/test/CodeGen/Hexagon/cfi-late.ll index aeffa29013e..ce38711ae8d 100644 --- a/test/CodeGen/Hexagon/cfi-late.ll +++ b/test/CodeGen/Hexagon/cfi-late.ll @@ -16,7 +16,7 @@ target triple = "hexagon-unknown--elf" ; CHECK: } ; Function Attrs: nounwind -define i32 @foo(i32 %x, i32 %y) #0 { +define i32 @foo(i32 %x, i32 %y) #0 !dbg !4 { entry: tail call void @llvm.dbg.value(metadata i32 %x, i64 0, metadata !9, metadata !14), !dbg !15 tail call void @llvm.dbg.value(metadata i32 %y, i64 0, metadata !10, metadata !14), !dbg !16 @@ -45,7 +45,7 @@ attributes #3 = { nounwind } !1 = !DIFile(filename: "cfi-late.c", directory: "/test") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: true, function: i32 (i32, i32)* @foo, variables: !8) +!4 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: true, variables: !8) !5 = !DISubroutineType(types: !6) !6 = !{!7, !7, !7} !7 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/CodeGen/Hexagon/hwloop-dbg.ll b/test/CodeGen/Hexagon/hwloop-dbg.ll index af208b3a4da..341f8db9e33 100644 --- a/test/CodeGen/Hexagon/hwloop-dbg.ll +++ b/test/CodeGen/Hexagon/hwloop-dbg.ll @@ -3,7 +3,7 @@ target datalayout = "e-p:32:32:32-i64:64:64-i32:32:32-i16:16:16-i1:32:32-f64:64:64-f32:32:32-v64:64:64-v32:32:32-a0:0-n16:32" target triple = "hexagon" -define void @foo(i32* nocapture %a, i32* nocapture %b) nounwind { +define void @foo(i32* nocapture %a, i32* nocapture %b) nounwind !dbg !5 { entry: tail call void @llvm.dbg.value(metadata i32* %a, i64 0, metadata !13, metadata !DIExpression()), !dbg !17 tail call void @llvm.dbg.value(metadata i32* %b, i64 0, metadata !14, metadata !DIExpression()), !dbg !18 @@ -40,7 +40,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "QuIC LLVM Hexagon Clang version 6.1-pre-unknown, (git://git-hexagon-aus.quicinc.com/llvm/clang-mainline.git e9382867661454cdf44addb39430741578e9765c) (llvm/llvm-mainline.git 36412bb1fcf03ed426d4437b41198bae066675ac)", isOptimized: true, emissionKind: 1, file: !28, enums: !2, retainedTypes: !2, subprograms: !3, globals: !2) !2 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !28, scope: null, type: !7, function: void (i32*, i32*)* @foo, variables: !11) +!5 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !28, scope: null, type: !7, variables: !11) !6 = !DIFile(filename: "hwloop-dbg.c", directory: "/usr2/kparzysz/s.hex/t") !7 = !DISubroutineType(types: !8) !8 = !{null, !9, !9} diff --git a/test/CodeGen/Inputs/DbgValueOtherTargets.ll b/test/CodeGen/Inputs/DbgValueOtherTargets.ll index 2e308066223..440073fea15 100644 --- a/test/CodeGen/Inputs/DbgValueOtherTargets.ll +++ b/test/CodeGen/Inputs/DbgValueOtherTargets.ll @@ -1,6 +1,6 @@ ; Check that DEBUG_VALUE comments come through on a variety of targets. -define i32 @main() nounwind ssp { +define i32 @main() nounwind ssp !dbg !0 { entry: ; CHECK: DEBUG_VALUE call void @llvm.dbg.value(metadata i32 0, i64 0, metadata !7, metadata !DIExpression()), !dbg !9 @@ -14,7 +14,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!13} -!0 = distinct !DISubprogram(name: "main", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !12, scope: !1, type: !3, function: i32 ()* @main) +!0 = distinct !DISubprogram(name: "main", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !12, scope: !1, type: !3) !1 = !DIFile(filename: "/tmp/x.c", directory: "/Users/manav") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 2.9 (trunk 120996)", isOptimized: false, emissionKind: 0, file: !12, enums: !6, retainedTypes: !6, subprograms: !11) !3 = !DISubroutineType(types: !4) diff --git a/test/CodeGen/MIR/X86/expected-metadata-node-after-debug-location.mir b/test/CodeGen/MIR/X86/expected-metadata-node-after-debug-location.mir index e49d74a22b7..620bb5d961e 100644 --- a/test/CodeGen/MIR/X86/expected-metadata-node-after-debug-location.mir +++ b/test/CodeGen/MIR/X86/expected-metadata-node-after-debug-location.mir @@ -2,7 +2,7 @@ --- | - define i32 @test(i32 %x) #0 { + define i32 @test(i32 %x) #0 !dbg !4 { entry: %x.addr = alloca i32, align 4 store i32 %x, i32* %x.addr, align 4 @@ -24,7 +24,7 @@ !1 = !DIFile(filename: "test.ll", directory: "") !2 = !{} !3 = !{!4} - !4 = distinct !DISubprogram(name: "test", scope: !5, file: !5, line: 4, type: !6, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32)* @test, variables: !2) + !4 = distinct !DISubprogram(name: "test", scope: !5, file: !5, line: 4, type: !6, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DIFile(filename: "test.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} diff --git a/test/CodeGen/MIR/X86/expected-metadata-node-after-exclaim.mir b/test/CodeGen/MIR/X86/expected-metadata-node-after-exclaim.mir index 2ece729679c..6497f5db202 100644 --- a/test/CodeGen/MIR/X86/expected-metadata-node-after-exclaim.mir +++ b/test/CodeGen/MIR/X86/expected-metadata-node-after-exclaim.mir @@ -2,7 +2,7 @@ --- | - define i32 @test(i32 %x) #0 { + define i32 @test(i32 %x) #0 !dbg !4 { entry: %x.addr = alloca i32, align 4 store i32 %x, i32* %x.addr, align 4 @@ -24,7 +24,7 @@ !1 = !DIFile(filename: "test.ll", directory: "") !2 = !{} !3 = !{!4} - !4 = distinct !DISubprogram(name: "test", scope: !5, file: !5, line: 4, type: !6, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32)* @test, variables: !2) + !4 = distinct !DISubprogram(name: "test", scope: !5, file: !5, line: 4, type: !6, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DIFile(filename: "test.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} diff --git a/test/CodeGen/MIR/X86/instructions-debug-location.mir b/test/CodeGen/MIR/X86/instructions-debug-location.mir index d80786d7566..ea2cdbf7cb2 100644 --- a/test/CodeGen/MIR/X86/instructions-debug-location.mir +++ b/test/CodeGen/MIR/X86/instructions-debug-location.mir @@ -4,7 +4,7 @@ --- | - define i32 @test(i32 %x) #0 { + define i32 @test(i32 %x) #0 !dbg !4 { entry: %x.addr = alloca i32, align 4 store i32 %x, i32* %x.addr, align 4 @@ -35,7 +35,7 @@ !1 = !DIFile(filename: "test.ll", directory: "") !2 = !{} !3 = !{!4} - !4 = distinct !DISubprogram(name: "test", scope: !5, file: !5, line: 4, type: !6, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32)* @test, variables: !2) + !4 = distinct !DISubprogram(name: "test", scope: !5, file: !5, line: 4, type: !6, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DIFile(filename: "test.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} diff --git a/test/CodeGen/MIR/X86/metadata-operands.mir b/test/CodeGen/MIR/X86/metadata-operands.mir index 34d34b8a1a1..89a1e6fcb81 100644 --- a/test/CodeGen/MIR/X86/metadata-operands.mir +++ b/test/CodeGen/MIR/X86/metadata-operands.mir @@ -4,7 +4,7 @@ --- | - define i32 @test(i32 %x) #0 { + define i32 @test(i32 %x) #0 !dbg !4 { entry: %x.addr = alloca i32, align 4 store i32 %x, i32* %x.addr, align 4 @@ -26,7 +26,7 @@ !1 = !DIFile(filename: "test.ll", directory: "") !2 = !{} !3 = !{!4} - !4 = distinct !DISubprogram(name: "test", scope: !5, file: !5, line: 4, type: !6, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32)* @test, variables: !2) + !4 = distinct !DISubprogram(name: "test", scope: !5, file: !5, line: 4, type: !6, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DIFile(filename: "test.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} diff --git a/test/CodeGen/MIR/X86/unknown-metadata-node.mir b/test/CodeGen/MIR/X86/unknown-metadata-node.mir index ecd81011130..958a30678be 100644 --- a/test/CodeGen/MIR/X86/unknown-metadata-node.mir +++ b/test/CodeGen/MIR/X86/unknown-metadata-node.mir @@ -2,7 +2,7 @@ --- | - define i32 @test(i32 %x) #0 { + define i32 @test(i32 %x) #0 !dbg !4 { entry: %x.addr = alloca i32, align 4 store i32 %x, i32* %x.addr, align 4 @@ -24,7 +24,7 @@ !1 = !DIFile(filename: "test.ll", directory: "") !2 = !{} !3 = !{!4} - !4 = distinct !DISubprogram(name: "test", scope: !5, file: !5, line: 4, type: !6, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32)* @test, variables: !2) + !4 = distinct !DISubprogram(name: "test", scope: !5, file: !5, line: 4, type: !6, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DIFile(filename: "test.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} diff --git a/test/CodeGen/PowerPC/dbg.ll b/test/CodeGen/PowerPC/dbg.ll index 9b33134babe..b636cff0f20 100644 --- a/test/CodeGen/PowerPC/dbg.ll +++ b/test/CodeGen/PowerPC/dbg.ll @@ -4,7 +4,7 @@ target datalayout = "E-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v128:128:128-n32:64" target triple = "powerpc64-unknown-linux-gnu" -define i32 @main(i32 %argc, i8** nocapture %argv) nounwind readnone { +define i32 @main(i32 %argc, i8** nocapture %argv) nounwind readnone !dbg !5 { entry: tail call void @llvm.dbg.value(metadata i32 %argc, i64 0, metadata !15, metadata !DIExpression()), !dbg !17 tail call void @llvm.dbg.value(metadata i8** %argv, i64 0, metadata !16, metadata !DIExpression()), !dbg !18 @@ -20,7 +20,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.1", isOptimized: true, emissionKind: 0, file: !21, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !21, scope: null, type: !7, function: i32 (i32, i8**)* @main, variables: !13) +!5 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !21, scope: null, type: !7, variables: !13) !6 = !DIFile(filename: "dbg.c", directory: "/src") !7 = !DISubroutineType(types: !8) !8 = !{!9, !9, !10} diff --git a/test/CodeGen/PowerPC/pr17168.ll b/test/CodeGen/PowerPC/pr17168.ll index 41eef12afb8..b1bac59c9ce 100644 --- a/test/CodeGen/PowerPC/pr17168.ll +++ b/test/CodeGen/PowerPC/pr17168.ll @@ -9,7 +9,7 @@ target triple = "powerpc64-unknown-linux-gnu" @grid_points = external global [3 x i32], align 4 ; Function Attrs: nounwind -define fastcc void @compute_rhs() #0 { +define fastcc void @compute_rhs() #0 !dbg !114 { entry: br i1 undef, label %for.cond871.preheader.for.inc960_crit_edge, label %for.end1042, !dbg !439 @@ -168,7 +168,7 @@ attributes #1 = { nounwind readnone } !111 = !DILocalVariable(name: "d", line: 271, scope: !102, file: !5, type: !8) !112 = !DILocalVariable(name: "m", line: 271, scope: !102, file: !5, type: !8) !113 = !DILocalVariable(name: "add", line: 272, scope: !102, file: !5, type: !20) -!114 = distinct !DISubprogram(name: "compute_rhs", line: 1767, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1767, file: !1, scope: !5, type: !115, function: void ()* @compute_rhs, variables: !117) +!114 = distinct !DISubprogram(name: "compute_rhs", line: 1767, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1767, file: !1, scope: !5, type: !115, variables: !117) !115 = !DISubroutineType(types: !116) !116 = !{null} !117 = !{!118, !119, !120, !121, !122, !123, !124, !125, !126, !127, !128, !129, !130, !131} diff --git a/test/CodeGen/PowerPC/pr24546.ll b/test/CodeGen/PowerPC/pr24546.ll index a04edfe65ea..06f6bc93da9 100644 --- a/test/CodeGen/PowerPC/pr24546.ll +++ b/test/CodeGen/PowerPC/pr24546.ll @@ -6,7 +6,7 @@ @php_intpow10.powers = external unnamed_addr constant [23 x double], align 8 ; Function Attrs: nounwind -define double @_php_math_round(double %value, i32 signext %places, i32 signext %mode) #0 { +define double @_php_math_round(double %value, i32 signext %places, i32 signext %mode) #0 !dbg !6 { entry: br i1 undef, label %if.then, label %if.else, !dbg !32 @@ -62,7 +62,7 @@ attributes #3 = { nounwind } !3 = !{!4} !4 = !DIBasicType(name: "double", size: 64, align: 64, encoding: DW_ATE_float) !5 = !{!6, !18} -!6 = distinct !DISubprogram(name: "_php_math_round", scope: !1, file: !1, line: 15, type: !7, isLocal: false, isDefinition: true, scopeLine: 16, flags: DIFlagPrototyped, isOptimized: true, function: double (double, i32, i32)* @_php_math_round, variables: !10) +!6 = distinct !DISubprogram(name: "_php_math_round", scope: !1, file: !1, line: 15, type: !7, isLocal: false, isDefinition: true, scopeLine: 16, flags: DIFlagPrototyped, isOptimized: true, variables: !10) !7 = !DISubroutineType(types: !8) !8 = !{!4, !4, !9, !9} !9 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/CodeGen/PowerPC/unwind-dw2-g.ll b/test/CodeGen/PowerPC/unwind-dw2-g.ll index 69adf2d2052..e44da85f5b3 100644 --- a/test/CodeGen/PowerPC/unwind-dw2-g.ll +++ b/test/CodeGen/PowerPC/unwind-dw2-g.ll @@ -3,7 +3,7 @@ target datalayout = "E-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f3 target triple = "powerpc64-unknown-linux-gnu" ; Function Attrs: nounwind -define void @foo() #0 { +define void @foo() #0 !dbg !4 { entry: call void @llvm.eh.unwind.init(), !dbg !9 ret void, !dbg !10 @@ -25,7 +25,7 @@ attributes #0 = { nounwind } !1 = !DIFile(filename: "/tmp/unwind-dw2.c", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: void ()* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "/tmp/unwind-dw2.c", directory: "/tmp") !6 = !DISubroutineType(types: !7) !7 = !{null} diff --git a/test/CodeGen/WinEH/wineh-cloning.ll b/test/CodeGen/WinEH/wineh-cloning.ll index e6074f29a3a..b4e785d42dd 100644 --- a/test/CodeGen/WinEH/wineh-cloning.ll +++ b/test/CodeGen/WinEH/wineh-cloning.ll @@ -453,7 +453,7 @@ exit: ; CHECK-NEXT: call void @f() ; CHECK-NEXT: unreachable -define void @test12() personality i32 (...)* @__CxxFrameHandler3 { +define void @test12() personality i32 (...)* @__CxxFrameHandler3 !dbg !5 { entry: invoke void @f() to label %cont unwind label %left, !dbg !8 @@ -559,7 +559,7 @@ exit: !2 = !DIFile(filename: "test.cpp", directory: ".") !3 = !{} !4 = !{!5} -!5 = distinct !DISubprogram(name: "test12", scope: !2, file: !2, type: !6, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: true, function: void ()* @test12, variables: !3) +!5 = distinct !DISubprogram(name: "test12", scope: !2, file: !2, type: !6, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: true, variables: !3) !6 = !DISubroutineType(types: !7) !7 = !{null} !8 = !DILocation(line: 1, scope: !5) diff --git a/test/CodeGen/X86/2010-01-18-DbgValue.ll b/test/CodeGen/X86/2010-01-18-DbgValue.ll index 4052db99461..c15e7a79bfa 100644 --- a/test/CodeGen/X86/2010-01-18-DbgValue.ll +++ b/test/CodeGen/X86/2010-01-18-DbgValue.ll @@ -6,7 +6,7 @@ %struct.Pt = type { double, double } %struct.Rect = type { %struct.Pt, %struct.Pt } -define double @foo(%struct.Rect* byval %my_r0) nounwind ssp { +define double @foo(%struct.Rect* byval %my_r0) nounwind ssp !dbg !1 { entry: ;CHECK: DEBUG_VALUE %retval = alloca double ; <double*> [#uses=2] @@ -32,7 +32,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !llvm.module.flags = !{!21} !0 = !DILocalVariable(name: "my_r0", line: 11, arg: 1, scope: !1, file: !2, type: !7) -!1 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 11, file: !19, scope: !2, type: !4, function: double (%struct.Rect*)* @foo) +!1 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 11, file: !19, scope: !2, type: !4) !2 = !DIFile(filename: "b2.c", directory: "/tmp/") !3 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: false, emissionKind: 0, file: !19, enums: !20, retainedTypes: !20, subprograms: !18) !4 = !DISubroutineType(types: !5) diff --git a/test/CodeGen/X86/2010-05-25-DotDebugLoc.ll b/test/CodeGen/X86/2010-05-25-DotDebugLoc.ll index bd04b034dca..f157d5011b0 100644 --- a/test/CodeGen/X86/2010-05-25-DotDebugLoc.ll +++ b/test/CodeGen/X86/2010-05-25-DotDebugLoc.ll @@ -7,7 +7,7 @@ %0 = type { double } -define hidden %0 @__divsc3(float %a, float %b, float %c, float %d) nounwind readnone { +define hidden %0 @__divsc3(float %a, float %b, float %c, float %d) nounwind readnone !dbg !1 { entry: tail call void @llvm.dbg.value(metadata float %a, i64 0, metadata !0, metadata !DIExpression()), !dbg !DILocation(scope: !1) tail call void @llvm.dbg.value(metadata float %b, i64 0, metadata !11, metadata !DIExpression()), !dbg !DILocation(scope: !1) @@ -200,7 +200,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.module.flags = !{!48} !0 = !DILocalVariable(name: "a", line: 1921, arg: 1, scope: !1, file: !2, type: !9) -!1 = distinct !DISubprogram(name: "__divsc3", linkageName: "__divsc3", line: 1922, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 1922, file: !45, scope: !2, type: !4, function: %0 (float, float, float, float)* @__divsc3, variables: !43) +!1 = distinct !DISubprogram(name: "__divsc3", linkageName: "__divsc3", line: 1922, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 1922, file: !45, scope: !2, type: !4, variables: !43) !2 = !DIFile(filename: "libgcc2.c", directory: "/Users/yash/clean/LG.D/gcc/../../llvmgcc/gcc") !3 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: true, emissionKind: 1, file: !45, enums: !47, retainedTypes: !47, subprograms: !44, imports: null) !4 = !DISubroutineType(types: !5) diff --git a/test/CodeGen/X86/2010-05-26-DotDebugLoc.ll b/test/CodeGen/X86/2010-05-26-DotDebugLoc.ll index 74134f0026d..a34e7bd9fe4 100644 --- a/test/CodeGen/X86/2010-05-26-DotDebugLoc.ll +++ b/test/CodeGen/X86/2010-05-26-DotDebugLoc.ll @@ -7,7 +7,7 @@ target triple = "x86_64-apple-darwin10" @llvm.used = appending global [1 x i8*] [i8* bitcast (i8* (%struct.a*)* @bar to i8*)], section "llvm.metadata" ; <[1 x i8*]*> [#uses=0] -define i8* @bar(%struct.a* %myvar) nounwind optsize noinline ssp { +define i8* @bar(%struct.a* %myvar) nounwind optsize noinline ssp !dbg !9 { entry: tail call void @llvm.dbg.value(metadata %struct.a* %myvar, i64 0, metadata !8, metadata !DIExpression()), !dbg !DILocation(scope: !9) %0 = getelementptr inbounds %struct.a, %struct.a* %myvar, i64 0, i32 0, !dbg !28 ; <i32*> [#uses=1] @@ -29,11 +29,11 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !2 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: true, emissionKind: 1, file: !36, enums: !37, retainedTypes: !37, subprograms: !32, globals: !31, imports: !37) !3 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !4 = !DILocalVariable(name: "x", line: 12, arg: 1, scope: !5, file: !1, type: !3) -!5 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 13, file: !36, scope: !1, type: !6, function: void (i32)* @foo, variables: !33) +!5 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 13, file: !36, scope: !1, type: !6, variables: !33) !6 = !DISubroutineType(types: !7) !7 = !{null, !3} !8 = !DILocalVariable(name: "myvar", line: 17, arg: 1, scope: !9, file: !1, type: !13) -!9 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 17, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 17, file: !36, scope: !1, type: !10, function: i8* (%struct.a*)* @bar, variables: !34) +!9 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 17, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 17, file: !36, scope: !1, type: !10, variables: !34) !10 = !DISubroutineType(types: !11) !11 = !{!12, !13} !12 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, file: !36, scope: !1, baseType: null) diff --git a/test/CodeGen/X86/2010-05-28-Crash.ll b/test/CodeGen/X86/2010-05-28-Crash.ll index e87bf404049..80118331be0 100644 --- a/test/CodeGen/X86/2010-05-28-Crash.ll +++ b/test/CodeGen/X86/2010-05-28-Crash.ll @@ -2,7 +2,7 @@ ; RUN: llc -mtriple=x86_64-apple-darwin -regalloc=basic < %s | FileCheck %s ; Test to check separate label for inlined function argument. -define i32 @foo(i32 %y) nounwind optsize ssp { +define i32 @foo(i32 %y) nounwind optsize ssp !dbg !1 { entry: tail call void @llvm.dbg.value(metadata i32 %y, i64 0, metadata !0, metadata !DIExpression()), !dbg !DILocation(scope: !1) %0 = tail call i32 (...) @zoo(i32 %y) nounwind, !dbg !9 ; <i32> [#uses=1] @@ -13,7 +13,7 @@ declare i32 @zoo(...) declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnone -define i32 @bar(i32 %x) nounwind optsize ssp { +define i32 @bar(i32 %x) nounwind optsize ssp !dbg !8 { entry: tail call void @llvm.dbg.value(metadata i32 %x, i64 0, metadata !7, metadata !DIExpression()), !dbg !DILocation(scope: !8) tail call void @llvm.dbg.value(metadata i32 1, i64 0, metadata !0, metadata !DIExpression()) nounwind, !dbg !DILocation(scope: !1) @@ -26,14 +26,14 @@ entry: !llvm.module.flags = !{!20} !0 = !DILocalVariable(name: "y", line: 2, arg: 1, scope: !1, file: !2, type: !6) -!1 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 2, file: !18, scope: !2, type: !4, function: i32 (i32)* @foo, variables: !15) +!1 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 2, file: !18, scope: !2, type: !4, variables: !15) !2 = !DIFile(filename: "f.c", directory: "/tmp") !3 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: true, emissionKind: 1, file: !18, enums: !19, retainedTypes: !19, subprograms: !17, imports: null) !4 = !DISubroutineType(types: !5) !5 = !{!6, !6} !6 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !7 = !DILocalVariable(name: "x", line: 6, arg: 1, scope: !8, file: !2, type: !6) -!8 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 6, file: !18, scope: !2, type: !4, function: i32 (i32)* @bar, variables: !16) +!8 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 6, file: !18, scope: !2, type: !4, variables: !16) !9 = !DILocation(line: 3, scope: !10) !10 = distinct !DILexicalBlock(line: 2, column: 0, file: !18, scope: !1) !11 = !{i32 1} diff --git a/test/CodeGen/X86/2010-06-01-DeadArg-DbgInfo.ll b/test/CodeGen/X86/2010-06-01-DeadArg-DbgInfo.ll index c92ea3ab596..71e16a90c9d 100644 --- a/test/CodeGen/X86/2010-06-01-DeadArg-DbgInfo.ll +++ b/test/CodeGen/X86/2010-06-01-DeadArg-DbgInfo.ll @@ -7,7 +7,7 @@ target triple = "x86_64-apple-darwin10.2" @llvm.used = appending global [1 x i8*] [i8* bitcast (i32 (%struct.foo*, i32)* @_ZN3foo3bazEi to i8*)], section "llvm.metadata" ; <[1 x i8*]*> [#uses=0] -define i32 @_ZN3foo3bazEi(%struct.foo* nocapture %this, i32 %x) nounwind readnone optsize noinline ssp align 2 { +define i32 @_ZN3foo3bazEi(%struct.foo* nocapture %this, i32 %x) nounwind readnone optsize noinline ssp align 2 !dbg !8 { ;CHECK: DEBUG_VALUE: baz:this <- RDI{{$}} entry: tail call void @llvm.dbg.value(metadata %struct.foo* %this, i64 0, metadata !15, metadata !DIExpression()), !dbg !DILocation(scope: !8) @@ -24,14 +24,14 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.dbg.lv = !{!0, !14, !15, !16, !17, !24, !25, !28} !0 = !DILocalVariable(name: "this", line: 11, arg: 1, scope: !1, file: !3, type: !12) -!1 = distinct !DISubprogram(name: "bar", linkageName: "_ZN3foo3barEi", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 11, file: !31, scope: !2, type: !9, function: i32 (%struct.foo*, i32)* null) +!1 = distinct !DISubprogram(name: "bar", linkageName: "_ZN3foo3barEi", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 11, file: !31, scope: !2, type: !9) !2 = !DICompositeType(tag: DW_TAG_structure_type, name: "foo", line: 3, size: 32, align: 32, file: !31, scope: !3, elements: !5) !3 = !DIFile(filename: "foo.cp", directory: "/tmp/") !4 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "4.2.1 LLVM build", isOptimized: true, emissionKind: 0, file: !31, enums: !32, retainedTypes: !32, subprograms: !33) !5 = !{!6, !1, !8} !6 = !DIDerivedType(tag: DW_TAG_member, name: "y", line: 8, size: 32, align: 32, file: !31, scope: !2, baseType: !7) !7 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!8 = distinct !DISubprogram(name: "baz", linkageName: "_ZN3foo3bazEi", line: 15, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 15, file: !31, scope: !2, type: !9, function: i32 (%struct.foo*, i32)* @_ZN3foo3bazEi) +!8 = distinct !DISubprogram(name: "baz", linkageName: "_ZN3foo3bazEi", line: 15, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 15, file: !31, scope: !2, type: !9) !9 = !DISubroutineType(types: !10) !10 = !{!7, !11, !7} !11 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial, file: !31, scope: !3, baseType: !2) diff --git a/test/CodeGen/X86/2010-08-04-StackVariable.ll b/test/CodeGen/X86/2010-08-04-StackVariable.ll index b24c1a21a51..d305d678c59 100644 --- a/test/CodeGen/X86/2010-08-04-StackVariable.ll +++ b/test/CodeGen/X86/2010-08-04-StackVariable.ll @@ -3,7 +3,7 @@ %struct.SVal = type { i8*, i32 } -define i32 @_Z3fooi4SVal(i32 %i, %struct.SVal* noalias %location) nounwind ssp { +define i32 @_Z3fooi4SVal(i32 %i, %struct.SVal* noalias %location) nounwind ssp !dbg !17 { entry: %"alloca point" = bitcast i32 0 to i32 ; <i32> [#uses=0] call void @llvm.dbg.value(metadata i32 %i, i64 0, metadata !23, metadata !DIExpression()), !dbg !24 @@ -31,7 +31,7 @@ return: ; preds = %bb2 ret i32 %.0, !dbg !29 } -define linkonce_odr void @_ZN4SValC1Ev(%struct.SVal* %this) nounwind ssp align 2 { +define linkonce_odr void @_ZN4SValC1Ev(%struct.SVal* %this) nounwind ssp align 2 !dbg !16 { entry: %"alloca point" = bitcast i32 0 to i32 ; <i32> [#uses=0] call void @llvm.dbg.value(metadata %struct.SVal* %this, i64 0, metadata !31, metadata !DIExpression()), !dbg !34 @@ -47,7 +47,7 @@ return: ; preds = %entry declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone -define i32 @main() nounwind ssp { +define i32 @main() nounwind ssp !dbg !20 { entry: %0 = alloca %struct.SVal ; <%struct.SVal*> [#uses=3] %v = alloca %struct.SVal ; <%struct.SVal*> [#uses=4] @@ -94,11 +94,11 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !13 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !14 = !DISubroutineType(types: !15) !15 = !{null, !12} -!16 = distinct !DISubprogram(name: "SVal", linkageName: "_ZN4SValC1Ev", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 11, file: !47, scope: !1, type: !14, function: void (%struct.SVal*)* @_ZN4SValC1Ev) -!17 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooi4SVal", line: 16, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 16, file: !47, scope: !2, type: !18, function: i32 (i32, %struct.SVal*)* @_Z3fooi4SVal) +!16 = distinct !DISubprogram(name: "SVal", linkageName: "_ZN4SValC1Ev", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 11, file: !47, scope: !1, type: !14) +!17 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooi4SVal", line: 16, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 16, file: !47, scope: !2, type: !18) !18 = !DISubroutineType(types: !19) !19 = !{!13, !13, !1} -!20 = distinct !DISubprogram(name: "main", linkageName: "main", line: 23, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 23, file: !47, scope: !2, type: !21, function: i32 ()* @main) +!20 = distinct !DISubprogram(name: "main", linkageName: "main", line: 23, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 23, file: !47, scope: !2, type: !21) !21 = !DISubroutineType(types: !22) !22 = !{!13} !23 = !DILocalVariable(name: "i", line: 16, arg: 1, scope: !17, file: !2, type: !13) diff --git a/test/CodeGen/X86/2010-09-16-EmptyFilename.ll b/test/CodeGen/X86/2010-09-16-EmptyFilename.ll index 230cd086ebc..4303ca991a8 100644 --- a/test/CodeGen/X86/2010-09-16-EmptyFilename.ll +++ b/test/CodeGen/X86/2010-09-16-EmptyFilename.ll @@ -2,12 +2,12 @@ ; Radar 8286101 ; CHECK: .file {{[0-9]+}} "<stdin>" -define i32 @foo() nounwind ssp { +define i32 @foo() nounwind ssp !dbg !0 { entry: ret i32 42, !dbg !8 } -define i32 @bar() nounwind ssp { +define i32 @bar() nounwind ssp !dbg !6 { entry: ret i32 21, !dbg !10 } @@ -15,13 +15,13 @@ entry: !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!17} -!0 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 53, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !14, scope: !1, type: !3, function: i32 ()* @foo) +!0 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 53, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !14, scope: !1, type: !3) !1 = !DIFile(filename: "", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 2.9 (trunk 114084)", isOptimized: false, emissionKind: 0, file: !15, enums: !16, retainedTypes: !16, subprograms: !13) !3 = !DISubroutineType(types: !4) !4 = !{!5} !5 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!6 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !15, scope: !7, type: !3, function: i32 ()* @bar) +!6 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !15, scope: !7, type: !3) !7 = !DIFile(filename: "bug.c", directory: "/private/tmp") !8 = !DILocation(line: 53, column: 13, scope: !9) !9 = distinct !DILexicalBlock(line: 53, column: 11, file: !14, scope: !0) diff --git a/test/CodeGen/X86/2010-11-02-DbgParameter.ll b/test/CodeGen/X86/2010-11-02-DbgParameter.ll index 10ade11ba32..b091003585c 100644 --- a/test/CodeGen/X86/2010-11-02-DbgParameter.ll +++ b/test/CodeGen/X86/2010-11-02-DbgParameter.ll @@ -6,7 +6,7 @@ target triple = "i386-apple-darwin11.0.0" %struct.bar = type { i32, i32 } -define i32 @foo(%struct.bar* nocapture %i) nounwind readnone optsize noinline ssp { +define i32 @foo(%struct.bar* nocapture %i) nounwind readnone optsize noinline ssp !dbg !0 { ; CHECK: TAG_formal_parameter entry: tail call void @llvm.dbg.value(metadata %struct.bar* %i, i64 0, metadata !6, metadata !DIExpression()), !dbg !12 @@ -18,7 +18,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!19} -!0 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !17, scope: !1, type: !3, function: i32 (%struct.bar*)* @foo, variables: !16) +!0 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !17, scope: !1, type: !3, variables: !16) !1 = !DIFile(filename: "one.c", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 2.9 (trunk 117922)", isOptimized: true, emissionKind: 0, file: !17, enums: !18, retainedTypes: !18, subprograms: !15, imports: null) !3 = !DISubroutineType(types: !4) diff --git a/test/CodeGen/X86/2011-01-24-DbgValue-Before-Use.ll b/test/CodeGen/X86/2011-01-24-DbgValue-Before-Use.ll index a4c6bf50153..661ec94fee4 100644 --- a/test/CodeGen/X86/2011-01-24-DbgValue-Before-Use.ll +++ b/test/CodeGen/X86/2011-01-24-DbgValue-Before-Use.ll @@ -20,7 +20,7 @@ target triple = "x86_64-apple-darwin10.0.0" @.str1 = private unnamed_addr constant [14 x i8] c"m=%u, z_s=%d\0A\00" @str = internal constant [21 x i8] c"Failing test vector:\00" -define i64 @gcd(i64 %a, i64 %b) nounwind readnone optsize noinline ssp { +define i64 @gcd(i64 %a, i64 %b) nounwind readnone optsize noinline ssp !dbg !0 { entry: tail call void @llvm.dbg.value(metadata i64 %a, i64 0, metadata !10, metadata !DIExpression()), !dbg !18 tail call void @llvm.dbg.value(metadata i64 %b, i64 0, metadata !11, metadata !DIExpression()), !dbg !19 @@ -38,7 +38,7 @@ if.then: ; preds = %while.body ret i64 %b.addr.0, !dbg !23 } -define i32 @main() nounwind optsize ssp { +define i32 @main() nounwind optsize ssp !dbg !6 { entry: %call = tail call i32 @rand() nounwind optsize, !dbg !24 tail call void @llvm.dbg.value(metadata i32 %call, i64 0, metadata !14, metadata !DIExpression()), !dbg !24 @@ -78,13 +78,13 @@ declare i32 @puts(i8* nocapture) nounwind !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!33} -!0 = distinct !DISubprogram(name: "gcd", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !31, scope: !1, type: !3, function: i64 (i64, i64)* @gcd, variables: !29) +!0 = distinct !DISubprogram(name: "gcd", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !31, scope: !1, type: !3, variables: !29) !1 = !DIFile(filename: "rem_small.c", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 2.9 (trunk 124117)", isOptimized: true, emissionKind: 1, file: !31, enums: !32, retainedTypes: !32, subprograms: !28, imports: null) !3 = !DISubroutineType(types: !4) !4 = !{!5} !5 = !DIBasicType(tag: DW_TAG_base_type, name: "long int", size: 64, align: 64, encoding: DW_ATE_signed) -!6 = distinct !DISubprogram(name: "main", line: 25, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !31, scope: !1, type: !7, function: i32 ()* @main, variables: !30) +!6 = distinct !DISubprogram(name: "main", line: 25, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !31, scope: !1, type: !7, variables: !30) !7 = !DISubroutineType(types: !8) !8 = !{!9} !9 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/CodeGen/X86/2012-11-30-handlemove-dbg.ll b/test/CodeGen/X86/2012-11-30-handlemove-dbg.ll index 8f218ef9f5f..50b486c6f92 100644 --- a/test/CodeGen/X86/2012-11-30-handlemove-dbg.ll +++ b/test/CodeGen/X86/2012-11-30-handlemove-dbg.ll @@ -14,7 +14,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone -define signext i16 @subdivp(%struct.node.0.27* nocapture %p, double %dsq, double %tolsq, %struct.hgstruct.2.29* nocapture byval align 8 %hg) nounwind uwtable readonly ssp { +define signext i16 @subdivp(%struct.node.0.27* nocapture %p, double %dsq, double %tolsq, %struct.hgstruct.2.29* nocapture byval align 8 %hg) nounwind uwtable readonly ssp !dbg !14 { entry: call void @llvm.dbg.declare(metadata %struct.hgstruct.2.29* %hg, metadata !4, metadata !DIExpression()), !dbg !DILocation(scope: !14) %type = getelementptr inbounds %struct.node.0.27, %struct.node.0.27* %p, i64 0, i32 0 @@ -47,6 +47,6 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !11 = !DIFile(filename: "MultiSource/Benchmarks/Olden/bh/newbh.c", directory: "MultiSource/Benchmarks/Olden/bh") !12 = !{i32 1, !"Debug Info Version", i32 3} !13 = !{!14} -!14 = distinct !DISubprogram(name: "subdivp", isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !11, scope: !5, type: !15, function: i16 (%struct.node.0.27*, double, double, %struct.hgstruct.2.29* )* @subdivp) +!14 = distinct !DISubprogram(name: "subdivp", isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !11, scope: !5, type: !15) !15 = !DISubroutineType(types: !16) !16 = !{null} diff --git a/test/CodeGen/X86/2012-11-30-misched-dbg.ll b/test/CodeGen/X86/2012-11-30-misched-dbg.ll index d222ffc8dfb..7ed416e36c2 100644 --- a/test/CodeGen/X86/2012-11-30-misched-dbg.ll +++ b/test/CodeGen/X86/2012-11-30-misched-dbg.ll @@ -14,7 +14,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone -define i32 @AttachGalley(%union.rec** nocapture %suspend_pt) nounwind uwtable ssp { +define i32 @AttachGalley(%union.rec** nocapture %suspend_pt) nounwind uwtable ssp !dbg !21 { entry: %num14075 = alloca [20 x i8], align 16 br label %if.end33 @@ -86,7 +86,7 @@ declare i32 @__sprintf_chk(i8*, i32, i64, i8*, ...) !19 = !DIFile(filename: "MultiSource/Benchmarks/MiBench/consumer-typeset/z19.c", directory: "MultiSource/Benchmarks/MiBench/consumer-typeset") !20 = !{!21} -!21 = distinct !DISubprogram(name: "AttachGalley", isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !19, scope: !14, type: !22, function: i32 (%union.rec**)* @AttachGalley) +!21 = distinct !DISubprogram(name: "AttachGalley", isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !19, scope: !14, type: !22) !22 = !DISubroutineType(types: !23) !23 = !{null} @@ -99,7 +99,7 @@ declare i32 @__sprintf_chk(i8*, i32, i64, i8*, ...) %"class.__gnu_cxx::hash_map" = type { %"class.__gnu_cxx::hashtable" } %"class.__gnu_cxx::hashtable" = type { i64, i64, i64, i64, i64, i64 } -define void @main() uwtable ssp personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) { +define void @main() uwtable ssp personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) !dbg !37 { entry: %X = alloca %"class.__gnu_cxx::hash_map", align 8 br i1 undef, label %cond.true, label %cond.end @@ -141,4 +141,4 @@ declare void @_Znwm() !34 = !DIFile(filename: "SingleSource/Benchmarks/Shootout-C++/hash.cpp", directory: "SingleSource/Benchmarks/Shootout-C++") !35 = !{i32 1, !"Debug Info Version", i32 3} !36 = !{!37} -!37 = distinct !DISubprogram(name: "main", isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !19, scope: !14, type: !22, function: void ()* @main) +!37 = distinct !DISubprogram(name: "main", isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !19, scope: !14, type: !22) diff --git a/test/CodeGen/X86/2012-11-30-regpres-dbg.ll b/test/CodeGen/X86/2012-11-30-regpres-dbg.ll index 80f1b325b4c..3f7a10ae035 100644 --- a/test/CodeGen/X86/2012-11-30-regpres-dbg.ll +++ b/test/CodeGen/X86/2012-11-30-regpres-dbg.ll @@ -11,7 +11,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone -define void @test() unnamed_addr uwtable ssp align 2 { +define void @test() unnamed_addr uwtable ssp align 2 !dbg !2 { entry: %callback = alloca %struct.btCompoundLeafCallback, align 8 br i1 undef, label %if.end, label %if.then @@ -38,7 +38,7 @@ invoke.cont44: ; preds = %if.end !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.3 (trunk 168984) (llvm/trunk 168983)", isOptimized: true, emissionKind: 0, file: !6, subprograms: !1) !1 = !{!2} -!2 = distinct !DISubprogram(name: "test", isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !6, scope: !5, type: !7, function: void ()* @test) +!2 = distinct !DISubprogram(name: "test", isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !6, scope: !5, type: !7) !3 = !DILocalVariable(name: "callback", line: 214, scope: !2, type: !4) !4 = !DICompositeType(tag: DW_TAG_structure_type, name: "btCompoundLeafCallback", line: 90, size: 512, align: 64, file: !6) !5 = !DIFile(filename: "MultiSource/Benchmarks/Bullet/btCompoundCollisionAlgorithm.cpp", directory: "MultiSource/Benchmarks/Bullet") diff --git a/test/CodeGen/X86/MachineSink-DbgValue.ll b/test/CodeGen/X86/MachineSink-DbgValue.ll index 2f1a7b082b8..457d9beb37d 100644 --- a/test/CodeGen/X86/MachineSink-DbgValue.ll +++ b/test/CodeGen/X86/MachineSink-DbgValue.ll @@ -3,7 +3,7 @@ target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64" target triple = "x86_64-apple-macosx10.7.0" -define i32 @foo(i32 %i, i32* nocapture %c) nounwind uwtable readonly ssp { +define i32 @foo(i32 %i, i32* nocapture %c) nounwind uwtable readonly ssp !dbg !1 { tail call void @llvm.dbg.value(metadata i32 %i, i64 0, metadata !6, metadata !DIExpression()), !dbg !12 %ab = load i32, i32* %c, align 1, !dbg !14 tail call void @llvm.dbg.value(metadata i32* %c, i64 0, metadata !7, metadata !DIExpression()), !dbg !13 @@ -29,7 +29,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.module.flags = !{!22} !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "Apple clang version 3.0 (tags/Apple/clang-211.10.1) (based on LLVM 3.0svn)", isOptimized: true, emissionKind: 1, file: !20, enums: !21, retainedTypes: !21, subprograms: !18, imports: null) -!1 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !20, scope: !2, type: !3, function: i32 (i32, i32*)* @foo, variables: !19) +!1 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !20, scope: !2, type: !3, variables: !19) !2 = !DIFile(filename: "a.c", directory: "/private/tmp") !3 = !DISubroutineType(types: !4) !4 = !{!5} diff --git a/test/CodeGen/X86/dbg-changes-codegen-branch-folding.ll b/test/CodeGen/X86/dbg-changes-codegen-branch-folding.ll index bee8107cd4b..54bd4892683 100644 --- a/test/CodeGen/X86/dbg-changes-codegen-branch-folding.ll +++ b/test/CodeGen/X86/dbg-changes-codegen-branch-folding.ll @@ -48,7 +48,7 @@ @.str2 = private unnamed_addr constant [2 x i8] c"-\00", align 1 ; Function Attrs: uwtable -define void @_Z3barii(i32 %param1, i32 %param2) #0 { +define void @_Z3barii(i32 %param1, i32 %param2) #0 !dbg !24 { entry: %var1 = alloca %struct.AAA3, align 1 %var2 = alloca %struct.AAA3, align 1 @@ -137,7 +137,7 @@ attributes #2 = { nounwind readnone } !21 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !22) !22 = !DIDerivedType(tag: DW_TAG_const_type, baseType: !"_ZTS4AAA3") !23 = !{!24, !35, !40} -!24 = distinct !DISubprogram(name: "bar", linkageName: "_Z3barii", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 11, file: !1, scope: !25, type: !26, function: void (i32, i32)* @_Z3barii, variables: !29) +!24 = distinct !DISubprogram(name: "bar", linkageName: "_Z3barii", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 11, file: !1, scope: !25, type: !26, variables: !29) !25 = !DIFile(filename: "dbg-changes-codegen-branch-folding.cpp", directory: "/tmp/dbginfo") !26 = !DISubroutineType(types: !27) !27 = !{null, !28, !28} diff --git a/test/CodeGen/X86/dbg-combine.ll b/test/CodeGen/X86/dbg-combine.ll index c4fbc133f31..3e78c316a06 100644 --- a/test/CodeGen/X86/dbg-combine.ll +++ b/test/CodeGen/X86/dbg-combine.ll @@ -24,7 +24,7 @@ ; ModuleID = 'dbg-combine.c' ; Function Attrs: nounwind uwtable -define i32 @foo() #0 { +define i32 @foo() #0 !dbg !4 { entry: %elems = alloca i32, align 4 %saved_stack = alloca i8* @@ -78,7 +78,7 @@ attributes #2 = { nounwind } !1 = !DIFile(filename: "dbg-combine.c", directory: "/home/probinson/projects/scratch") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, function: i32 ()* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "dbg-combine.c", directory: "/home/probinson/projects/scratch") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/CodeGen/X86/debugloc-argsize.ll b/test/CodeGen/X86/debugloc-argsize.ll index 56f67b72d98..0283154abab 100644 --- a/test/CodeGen/X86/debugloc-argsize.ll +++ b/test/CodeGen/X86/debugloc-argsize.ll @@ -3,7 +3,7 @@ ; CHECK-LABEL: _Z3foov: ; CHECK: .loc 1 4 3 prologue_end ; CHECK: .cfi_escape 0x2e, 0x10 -define void @_Z3foov() #0 personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) { +define void @_Z3foov() #0 personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) !dbg !4 { entry: tail call void @_Z3bariii(i32 0, i32 1, i32 2) #1, !dbg !10 invoke void @_Z3bariii(i32 4, i32 5, i32 6) #1 @@ -42,7 +42,7 @@ attributes #2 = { nounwind } !1 = !DIFile(filename: "foo.cpp", directory: "foo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foov", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: true, function: void ()* @_Z3foov, variables: !2) +!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foov", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: true, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/CodeGen/X86/fpstack-debuginstr-kill.ll b/test/CodeGen/X86/fpstack-debuginstr-kill.ll index 7f9cc9cdd92..2ee67dc190b 100644 --- a/test/CodeGen/X86/fpstack-debuginstr-kill.ll +++ b/test/CodeGen/X86/fpstack-debuginstr-kill.ll @@ -3,7 +3,7 @@ @g1 = global double 0.000000e+00, align 8 @g2 = global i32 0, align 4 -define void @_Z16fpuop_arithmeticjj(i32, i32) { +define void @_Z16fpuop_arithmeticjj(i32, i32) !dbg !4 { entry: switch i32 undef, label %sw.bb.i1921 [ ] @@ -47,7 +47,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) !1 = !DIFile(filename: "fpu_ieee.cpp", directory: "x87stackifier") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "fpuop_arithmetic", linkageName: "_Z16fpuop_arithmeticjj", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 13, file: !5, scope: !6, type: !7, function: void (i32, i32)* @_Z16fpuop_arithmeticjj, variables: !10) +!4 = distinct !DISubprogram(name: "fpuop_arithmetic", linkageName: "_Z16fpuop_arithmeticjj", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 13, file: !5, scope: !6, type: !7, variables: !10) !5 = !DIFile(filename: "f1.cpp", directory: "x87stackifier") !6 = !DIFile(filename: "f1.cpp", directory: "x87stackifier") !7 = !DISubroutineType(types: !8) diff --git a/test/CodeGen/X86/machine-trace-metrics-crash.ll b/test/CodeGen/X86/machine-trace-metrics-crash.ll index f0536507a6b..048260c51fe 100644 --- a/test/CodeGen/X86/machine-trace-metrics-crash.ll +++ b/test/CodeGen/X86/machine-trace-metrics-crash.ll @@ -54,7 +54,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, file: !1, isOptimized: true, runtimeVersion: 0, emissionKind: 1) !1 = !DIFile(filename: "24199.cpp", directory: "/bin") !2 = !{i32 2, !"Debug Info Version", i32 3} -!3 = distinct !DISubprogram(linkageName: "foo", file: !1, line: 18, isLocal: false, isDefinition: true, scopeLine: 18, function: void (%struct.A*)* @foo) +!3 = distinct !DISubprogram(linkageName: "foo", file: !1, line: 18, isLocal: false, isDefinition: true, scopeLine: 18) !4 = !DIExpression() !5 = !DILocalVariable(name: "this", arg: 1, scope: !3, flags: DIFlagArtificial | DIFlagObjectPointer) !6 = !DILocation(line: 0, scope: !3) diff --git a/test/CodeGen/X86/misched-code-difference-with-debug.ll b/test/CodeGen/X86/misched-code-difference-with-debug.ll index 2be1ba62d76..0a1ea830a41 100644 --- a/test/CodeGen/X86/misched-code-difference-with-debug.ll +++ b/test/CodeGen/X86/misched-code-difference-with-debug.ll @@ -43,7 +43,7 @@ entry: ; CHECK-LABEL: test_with_debug ; CHECK: movl [[A]], [[B]] ; CHECK-NEXT: movl [[A]], [[C]] -define void @test_with_debug() { +define void @test_with_debug() !dbg !13 { entry: %c = alloca %class.C, align 1 %0 = load i8, i8* @argc, align 1 @@ -75,7 +75,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) !10 = !DIDerivedType(baseType: !"_ZTS1C", tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial) !11 = !DIBasicType(tag: DW_TAG_base_type, name: "char", size: 8, align: 8, encoding: DW_ATE_signed_char) !12 = !{!13} -!13 = distinct !DISubprogram(name: "test_with_debug", linkageName: "test_with_debug", line: 6, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 6, file: !1, scope: !14, type: !15, function: void ()* @test_with_debug, variables: !17) +!13 = distinct !DISubprogram(name: "test_with_debug", linkageName: "test_with_debug", line: 6, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 6, file: !1, scope: !14, type: !15, variables: !17) !14 = !DIFile(filename: "test.cpp", directory: "") !15 = !DISubroutineType(types: !16) !16 = !{null} diff --git a/test/CodeGen/X86/movpc32-check.ll b/test/CodeGen/X86/movpc32-check.ll index 0835a1bb3c6..606af3c898f 100644 --- a/test/CodeGen/X86/movpc32-check.ll +++ b/test/CodeGen/X86/movpc32-check.ll @@ -4,7 +4,7 @@ target datalayout = "e-m:e-p:32:32-f64:32:64-f80:32-n8:16:32-S128" target triple = "i686-pc-linux" ; Function Attrs: nounwind -define void @test() #0 { +define void @test() #0 !dbg !4 { entry: call void bitcast (void (...)* @bar to void ()*)(), !dbg !11 ret void, !dbg !12 @@ -23,7 +23,7 @@ attributes #1 = { "disable-tail-calls"="false" "less-precise-fpmad"="false" "no- !1 = !DIFile(filename: "test.c", directory: "movpc-test") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "test", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, isOptimized: false, function: void ()* @test, variables: !2) +!4 = distinct !DISubprogram(name: "test", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/CodeGen/X86/null-streamer.ll b/test/CodeGen/X86/null-streamer.ll index f675e49c1c6..e80f3fcbe58 100644 --- a/test/CodeGen/X86/null-streamer.ll +++ b/test/CodeGen/X86/null-streamer.ll @@ -18,7 +18,7 @@ define void @f1() { !1 = !DIFile(filename: "file.c", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !1, scope: !1, type: !6, function: i32 ()* null, variables: !2) +!4 = distinct !DISubprogram(name: "", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !1, scope: !1, type: !6, variables: !2) !6 = !DISubroutineType(types: !7) !7 = !{!8} !8 = !DIBasicType(tag: DW_TAG_base_type, size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/CodeGen/X86/push-cfi-debug.ll b/test/CodeGen/X86/push-cfi-debug.ll index 61110e566e6..cc00fab525a 100644 --- a/test/CodeGen/X86/push-cfi-debug.ll +++ b/test/CodeGen/X86/push-cfi-debug.ll @@ -25,7 +25,7 @@ declare x86_stdcallcc void @stdfoo(i32, i32) #0 ; CHECK: .cfi_adjust_cfa_offset -8 ; CHECK: addl $8, %esp ; CHECK: .cfi_adjust_cfa_offset -8 -define void @test1() #0 { +define void @test1() #0 !dbg !4 { entry: tail call void @foo(i32 1, i32 2) #1, !dbg !10 tail call x86_stdcallcc void @stdfoo(i32 3, i32 4) #1, !dbg !11 @@ -42,7 +42,7 @@ attributes #0 = { nounwind optsize } !1 = !DIFile(filename: "foo.c", directory: "foo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "test1", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, isOptimized: true, function: void ()* @test1, variables: !2) +!4 = distinct !DISubprogram(name: "test1", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, isOptimized: true, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/CodeGen/X86/stack-protector-dbginfo.ll b/test/CodeGen/X86/stack-protector-dbginfo.ll index d4eb2d880cc..237b96603c0 100644 --- a/test/CodeGen/X86/stack-protector-dbginfo.ll +++ b/test/CodeGen/X86/stack-protector-dbginfo.ll @@ -8,7 +8,7 @@ @a = external global { i64, [56 x i8] }, align 32 ; Function Attrs: nounwind sspreq -define i32 @_Z18read_response_sizev() #0 { +define i32 @_Z18read_response_sizev() #0 !dbg !9 { entry: tail call void @llvm.dbg.value(metadata !22, i64 0, metadata !23, metadata !DIExpression()), !dbg !39 %0 = load i64, i64* getelementptr inbounds ({ i64, [56 x i8] }, { i64, [56 x i8] }* @a, i32 0, i32 0), align 8, !dbg !40 @@ -34,7 +34,7 @@ attributes #0 = { sspreq } !6 = !{!7} !7 = !DIEnumerator(name: "max_frame_size", value: 0) ; [ DW_TAG_enumerator ] [max_frame_size :: 0] !8 = !{!9, !24, !41, !65} -!9 = distinct !DISubprogram(name: "read_response_size", linkageName: "_Z18read_response_sizev", line: 27, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 27, file: !1, scope: !10, type: !11, function: i32 ()* @_Z18read_response_sizev, variables: !14) +!9 = distinct !DISubprogram(name: "read_response_size", linkageName: "_Z18read_response_sizev", line: 27, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 27, file: !1, scope: !10, type: !11, variables: !14) !10 = !DIFile(filename: "<unknown>", directory: "/Users/matt/ryan_bug") !11 = !DISubroutineType(types: !12) !12 = !{!13} diff --git a/test/CodeGen/X86/unknown-location.ll b/test/CodeGen/X86/unknown-location.ll index 8222a623025..c41e529aa95 100644 --- a/test/CodeGen/X86/unknown-location.ll +++ b/test/CodeGen/X86/unknown-location.ll @@ -10,7 +10,7 @@ ; CHECK-NEXT: idivl ; CHECK-NEXT: .loc 1 4 3 -define i32 @foo(i32 %w, i32 %x, i32 %y, i32 %z) nounwind { +define i32 @foo(i32 %w, i32 %x, i32 %y, i32 %z) nounwind !dbg !1 { entry: %a = add i32 %w, %x, !dbg !8 %b = sdiv i32 %a, %y @@ -22,7 +22,7 @@ entry: !llvm.module.flags = !{!12} !0 = !DILocalVariable(name: "x", line: 1, arg: 2, scope: !1, file: !2, type: !6) -!1 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !10, scope: !2, type: !4, function: i32 (i32, i32, i32, i32)* @foo) +!1 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !10, scope: !2, type: !4) !2 = !DIFile(filename: "test.c", directory: "/dir") !3 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "producer", isOptimized: false, emissionKind: 0, file: !10, enums: !11, retainedTypes: !11, subprograms: !9) !4 = !DISubroutineType(types: !5) diff --git a/test/CodeGen/XCore/dwarf_debug.ll b/test/CodeGen/XCore/dwarf_debug.ll index 36fd1536608..6c8f389e8a9 100644 --- a/test/CodeGen/XCore/dwarf_debug.ll +++ b/test/CodeGen/XCore/dwarf_debug.ll @@ -9,7 +9,7 @@ ; CHECK: .loc 1 2 0 prologue_end # test.c:2:0 ; CHECK: add r0, r0, 1 ; CHECK: retsp 2 -define i32 @f(i32 %a) { +define i32 @f(i32 %a) !dbg !4 { entry: %a.addr = alloca i32, align 4 store i32 %a, i32* %a.addr, align 4 @@ -27,7 +27,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) !1 = !DIFile(filename: "test.c", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !1, type: !6, function: i32 (i32)* @f, variables: !2) +!4 = distinct !DISubprogram(name: "f", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !1, type: !6, variables: !2) !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} !8 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/DebugInfo/AArch64/cfi-eof-prologue.ll b/test/DebugInfo/AArch64/cfi-eof-prologue.ll index f2511fec43b..c4681ca12fb 100644 --- a/test/DebugInfo/AArch64/cfi-eof-prologue.ll +++ b/test/DebugInfo/AArch64/cfi-eof-prologue.ll @@ -26,7 +26,7 @@ target triple = "aarch64-apple-ios" @_ZTV1B = external unnamed_addr constant [4 x i8*] ; Function Attrs: nounwind -define %struct.B* @_ZN1BC2Ev(%struct.B* %this) unnamed_addr #0 align 2 { +define %struct.B* @_ZN1BC2Ev(%struct.B* %this) unnamed_addr #0 align 2 !dbg !28 { entry: tail call void @llvm.dbg.value(metadata %struct.B* %this, i64 0, metadata !30, metadata !38), !dbg !39 %0 = getelementptr inbounds %struct.B, %struct.B* %this, i64 0, i32 0, !dbg !40 @@ -39,7 +39,7 @@ entry: declare %struct.A* @_ZN1AC2Ev(%struct.A*) ; Function Attrs: nounwind -define %struct.B* @_ZN1BC1Ev(%struct.B* %this) unnamed_addr #0 align 2 { +define %struct.B* @_ZN1BC1Ev(%struct.B* %this) unnamed_addr #0 align 2 !dbg !32 { entry: tail call void @llvm.dbg.value(metadata %struct.B* %this, i64 0, metadata !34, metadata !38), !dbg !44 tail call void @llvm.dbg.value(metadata %struct.B* %this, i64 0, metadata !45, metadata !38) #3, !dbg !47 @@ -89,11 +89,11 @@ attributes #3 = { nounwind } !25 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS1A") !26 = !DISubprogram(name: "~A", line: 3, isLocal: false, isDefinition: false, virtuality: DW_VIRTUALITY_virtual, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !5, scope: !"_ZTS1A", type: !23, containingType: !"_ZTS1A") !27 = !{!28, !32} -!28 = distinct !DISubprogram(name: "B", linkageName: "_ZN1BC2Ev", line: 9, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 9, file: !5, scope: !"_ZTS1B", type: !9, function: %struct.B* (%struct.B*)* @_ZN1BC2Ev, declaration: !8, variables: !29) +!28 = distinct !DISubprogram(name: "B", linkageName: "_ZN1BC2Ev", line: 9, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 9, file: !5, scope: !"_ZTS1B", type: !9, declaration: !8, variables: !29) !29 = !{!30} !30 = !DILocalVariable(name: "this", arg: 1, flags: DIFlagArtificial | DIFlagObjectPointer, scope: !28, type: !31) !31 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !"_ZTS1B") -!32 = distinct !DISubprogram(name: "B", linkageName: "_ZN1BC1Ev", line: 9, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 9, file: !5, scope: !"_ZTS1B", type: !9, function: %struct.B* (%struct.B*)* @_ZN1BC1Ev, declaration: !8, variables: !33) +!32 = distinct !DISubprogram(name: "B", linkageName: "_ZN1BC1Ev", line: 9, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 9, file: !5, scope: !"_ZTS1B", type: !9, declaration: !8, variables: !33) !33 = !{!34} !34 = !DILocalVariable(name: "this", arg: 1, flags: DIFlagArtificial | DIFlagObjectPointer, scope: !32, type: !31) !35 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/DebugInfo/AArch64/coalescing.ll b/test/DebugInfo/AArch64/coalescing.ll index 041fba81956..79b40dd27c8 100644 --- a/test/DebugInfo/AArch64/coalescing.ll +++ b/test/DebugInfo/AArch64/coalescing.ll @@ -14,7 +14,7 @@ target datalayout = "e-m:o-i64:64-i128:128-n32:64-S128" target triple = "arm64-apple-ios" ; Function Attrs: nounwind optsize -define void @_Z5startv() #0 { +define void @_Z5startv() #0 !dbg !4 { entry: %size = alloca i32, align 4 %0 = bitcast i32* %size to i8*, !dbg !15 @@ -48,7 +48,7 @@ attributes #3 = { nounwind optsize } !1 = !DIFile(filename: "<stdin>", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "start", linkageName: "_Z5startv", line: 2, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !5, scope: !6, type: !7, function: void ()* @_Z5startv, variables: !9) +!4 = distinct !DISubprogram(name: "start", linkageName: "_Z5startv", line: 2, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !5, scope: !6, type: !7, variables: !9) !5 = !DIFile(filename: "test1.c", directory: "") !6 = !DIFile(filename: "test1.c", directory: "") !7 = !DISubroutineType(types: !8) diff --git a/test/DebugInfo/AArch64/constant-dbgloc.ll b/test/DebugInfo/AArch64/constant-dbgloc.ll index f2b8c86d4d4..aae518725fa 100644 --- a/test/DebugInfo/AArch64/constant-dbgloc.ll +++ b/test/DebugInfo/AArch64/constant-dbgloc.ll @@ -13,7 +13,7 @@ target triple = "aarch64--linux-gnueabihf" ; CHECK: movn ; Function Attrs: nounwind -define i32 @main() { +define i32 @main() !dbg !4 { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval @@ -27,7 +27,7 @@ entry: !1 = !DIFile(filename: "test.c", directory: "/home/user/clang/build") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{!7} !7 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/DebugInfo/AArch64/dwarfdump.ll b/test/DebugInfo/AArch64/dwarfdump.ll index 4324bdf7db7..57dcdf82d69 100644 --- a/test/DebugInfo/AArch64/dwarfdump.ll +++ b/test/DebugInfo/AArch64/dwarfdump.ll @@ -18,7 +18,7 @@ ; CHECK-4: DW_AT_high_pc [DW_FORM_data4] (0x00000008) ; CHECK-3: DW_AT_high_pc [DW_FORM_addr] (0x0000000000000008) -define i32 @main() nounwind { +define i32 @main() nounwind !dbg !3 { ret i32 0, !dbg !8 } @@ -30,7 +30,7 @@ attributes #0 = { nounwind } !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.3 ", isOptimized: false, emissionKind: 0, file: !9, enums: !1, retainedTypes: !1, subprograms: !2, globals: !1, imports: !1) !1 = !{} !2 = !{!3} -!3 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !9, scope: !4, type: !5, function: i32 ()* @main, variables: !1) +!3 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !9, scope: !4, type: !5, variables: !1) !4 = !DIFile(filename: "tmp.c", directory: "/home/tim/llvm/build") !5 = !DISubroutineType(types: !6) !6 = !{!7} diff --git a/test/DebugInfo/AArch64/frameindices.ll b/test/DebugInfo/AArch64/frameindices.ll index 62b0abf2991..5fb03dfc883 100644 --- a/test/DebugInfo/AArch64/frameindices.ll +++ b/test/DebugInfo/AArch64/frameindices.ll @@ -42,7 +42,7 @@ target triple = "aarch64-apple-ios" @a = global i64 0, align 8 @b = global i32* null, align 8 -define void @_Z3f131A(%struct.A* nocapture readonly %p1) #0 { +define void @_Z3f131A(%struct.A* nocapture readonly %p1) #0 !dbg !25 { entry: %agg.tmp = alloca %struct.A, align 8 tail call void @llvm.dbg.declare(metadata %struct.A* %p1, metadata !30, metadata !46), !dbg !47 @@ -67,7 +67,7 @@ declare void @_Z2f91A(%struct.A*) #0 ; Function Attrs: nounwind declare void @llvm.memcpy.p0i8.p0i8.i64(i8* nocapture, i8* nocapture readonly, i64, i32, i1) #3 -define void @_Z3f111A(%struct.A* nocapture readonly %p1) #0 { +define void @_Z3f111A(%struct.A* nocapture readonly %p1) #0 !dbg !31 { entry: %agg.tmp.i = alloca %struct.A, align 8 tail call void @llvm.dbg.declare(metadata %struct.A* %p1, metadata !33, metadata !46), !dbg !63 @@ -83,7 +83,7 @@ entry: ret void, !dbg !73 } -define void @_Z3f16v() #0 personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) { +define void @_Z3f16v() #0 personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) !dbg !34 { entry: %agg.tmp.i.i = alloca %struct.A, align 8 %d = alloca %struct.B, align 1 @@ -185,16 +185,16 @@ attributes #5 = { builtin } !22 = !DISubroutineType(types: !23) !23 = !{null, !19} !24 = !{!25, !31, !34} -!25 = distinct !DISubprogram(name: "f13", linkageName: "_Z3f131A", line: 13, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 13, file: !5, scope: !26, type: !27, function: void (%struct.A*)* @_Z3f131A, variables: !29) +!25 = distinct !DISubprogram(name: "f13", linkageName: "_Z3f131A", line: 13, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 13, file: !5, scope: !26, type: !27, variables: !29) !26 = !DIFile(filename: "test.cpp", directory: "") !27 = !DISubroutineType(types: !28) !28 = !{null, !"_ZTS1A"} !29 = !{!30} !30 = !DILocalVariable(name: "p1", line: 13, arg: 1, scope: !25, file: !26, type: !"_ZTS1A") -!31 = distinct !DISubprogram(name: "f11", linkageName: "_Z3f111A", line: 17, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 17, file: !5, scope: !26, type: !27, function: void (%struct.A*)* @_Z3f111A, variables: !32) +!31 = distinct !DISubprogram(name: "f11", linkageName: "_Z3f111A", line: 17, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 17, file: !5, scope: !26, type: !27, variables: !32) !32 = !{!33} !33 = !DILocalVariable(name: "p1", line: 17, arg: 1, scope: !31, file: !26, type: !"_ZTS1A") -!34 = distinct !DISubprogram(name: "f16", linkageName: "_Z3f16v", line: 18, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 18, file: !5, scope: !26, type: !35, function: void ()* @_Z3f16v, variables: !37) +!34 = distinct !DISubprogram(name: "f16", linkageName: "_Z3f16v", line: 18, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 18, file: !5, scope: !26, type: !35, variables: !37) !35 = !DISubroutineType(types: !36) !36 = !{null} !37 = !{!38, !39} diff --git a/test/DebugInfo/AArch64/prologue_end.ll b/test/DebugInfo/AArch64/prologue_end.ll index 47634f939c5..a7011222995 100644 --- a/test/DebugInfo/AArch64/prologue_end.ll +++ b/test/DebugInfo/AArch64/prologue_end.ll @@ -6,7 +6,7 @@ ; func(); ; } -define void @prologue_end_test() nounwind uwtable { +define void @prologue_end_test() nounwind uwtable !dbg !4 { ; CHECK: prologue_end_test: ; CHECK: .cfi_startproc ; CHECK: stp x29, x30 @@ -31,7 +31,7 @@ declare i32 @func() !1 = !DIFile(filename: "foo.c", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "prologue_end_test", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: false, function: void ()* @prologue_end_test, variables: !2) +!4 = distinct !DISubprogram(name: "prologue_end_test", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = !{i32 2, !"Dwarf Version", i32 2} diff --git a/test/DebugInfo/AArch64/struct_by_value.ll b/test/DebugInfo/AArch64/struct_by_value.ll index 991dbb513a8..edbef82557c 100644 --- a/test/DebugInfo/AArch64/struct_by_value.ll +++ b/test/DebugInfo/AArch64/struct_by_value.ll @@ -31,7 +31,7 @@ target triple = "arm64-apple-ios3.0.0" %struct.five = type { i32, i32, i32, i32, i32 } ; Function Attrs: nounwind ssp -define i32 @return_five_int(%struct.five* %f) #0 { +define i32 @return_five_int(%struct.five* %f) #0 !dbg !4 { entry: call void @llvm.dbg.declare(metadata %struct.five* %f, metadata !17, metadata !DIExpression(DW_OP_deref)), !dbg !18 %a = getelementptr inbounds %struct.five, %struct.five* %f, i32 0, i32 0, !dbg !19 @@ -52,7 +52,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "struct_by_value.c", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "return_five_int", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 14, file: !1, scope: !5, type: !6, function: i32 (%struct.five*)* @return_five_int, variables: !2) +!4 = distinct !DISubprogram(name: "return_five_int", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 14, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "struct_by_value.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8, !9} diff --git a/test/DebugInfo/ARM/PR16736.ll b/test/DebugInfo/ARM/PR16736.ll index 0b7e22b0042..905cb2d174e 100644 --- a/test/DebugInfo/ARM/PR16736.ll +++ b/test/DebugInfo/ARM/PR16736.ll @@ -13,7 +13,7 @@ target datalayout = "e-p:32:32:32-i1:8:32-i8:8:32-i16:16:32-i32:32:32-i64:64:64- target triple = "thumbv7-apple-ios" ; Function Attrs: nounwind -define arm_aapcscc void @_Z1hiiiif(i32, i32, i32, i32, float %x) #0 { +define arm_aapcscc void @_Z1hiiiif(i32, i32, i32, i32, float %x) #0 !dbg !4 { entry: tail call void @llvm.dbg.value(metadata i32 %0, i64 0, metadata !12, metadata !DIExpression()), !dbg !18 tail call void @llvm.dbg.value(metadata i32 %1, i64 0, metadata !13, metadata !DIExpression()), !dbg !18 @@ -45,7 +45,7 @@ attributes #3 = { nounwind } !1 = !DIFile(filename: "/<unknown>", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "h", linkageName: "_Z1hiiiif", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !5, scope: !6, type: !7, function: void (i32, i32, i32, i32, float)* @_Z1hiiiif, variables: !11) +!4 = distinct !DISubprogram(name: "h", linkageName: "_Z1hiiiif", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !5, scope: !6, type: !7, variables: !11) !5 = !DIFile(filename: "/arm.cpp", directory: "") !6 = !DIFile(filename: "/arm.cpp", directory: "") !7 = !DISubroutineType(types: !8) diff --git a/test/DebugInfo/ARM/cfi-eof-prologue.ll b/test/DebugInfo/ARM/cfi-eof-prologue.ll index 61f0d9bf496..7430551fd61 100644 --- a/test/DebugInfo/ARM/cfi-eof-prologue.ll +++ b/test/DebugInfo/ARM/cfi-eof-prologue.ll @@ -27,7 +27,7 @@ target triple = "thumbv7-apple-ios" @_ZTV1B = external unnamed_addr constant [4 x i8*] ; Function Attrs: nounwind -define %struct.B* @_ZN1BC2Ev(%struct.B* %this) unnamed_addr #0 align 2 { +define %struct.B* @_ZN1BC2Ev(%struct.B* %this) unnamed_addr #0 align 2 !dbg !28 { entry: tail call void @llvm.dbg.value(metadata %struct.B* %this, i64 0, metadata !30, metadata !40), !dbg !41 %0 = getelementptr inbounds %struct.B, %struct.B* %this, i32 0, i32 0, !dbg !42 @@ -40,7 +40,7 @@ entry: declare %struct.A* @_ZN1AC2Ev(%struct.A*) ; Function Attrs: nounwind -define %struct.B* @_ZN1BC1Ev(%struct.B* %this) unnamed_addr #0 align 2 { +define %struct.B* @_ZN1BC1Ev(%struct.B* %this) unnamed_addr #0 align 2 !dbg !32 { entry: tail call void @llvm.dbg.value(metadata %struct.B* %this, i64 0, metadata !34, metadata !40), !dbg !46 tail call void @llvm.dbg.value(metadata %struct.B* %this, i64 0, metadata !47, metadata !40) #3, !dbg !49 @@ -90,11 +90,11 @@ attributes #3 = { nounwind } !25 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 32, align: 32, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS1A") !26 = !DISubprogram(name: "~A", line: 3, isLocal: false, isDefinition: false, virtuality: DW_VIRTUALITY_virtual, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !5, scope: !"_ZTS1A", type: !23, containingType: !"_ZTS1A") !27 = !{!28, !32} -!28 = distinct !DISubprogram(name: "B", linkageName: "_ZN1BC2Ev", line: 9, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 9, file: !5, scope: !"_ZTS1B", type: !9, function: %struct.B* (%struct.B*)* @_ZN1BC2Ev, declaration: !8, variables: !29) +!28 = distinct !DISubprogram(name: "B", linkageName: "_ZN1BC2Ev", line: 9, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 9, file: !5, scope: !"_ZTS1B", type: !9, declaration: !8, variables: !29) !29 = !{!30} !30 = !DILocalVariable(name: "this", arg: 1, flags: DIFlagArtificial | DIFlagObjectPointer, scope: !28, type: !31) !31 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 32, align: 32, baseType: !"_ZTS1B") -!32 = distinct !DISubprogram(name: "B", linkageName: "_ZN1BC1Ev", line: 9, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 9, file: !5, scope: !"_ZTS1B", type: !9, function: %struct.B* (%struct.B*)* @_ZN1BC1Ev, declaration: !8, variables: !33) +!32 = distinct !DISubprogram(name: "B", linkageName: "_ZN1BC1Ev", line: 9, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 9, file: !5, scope: !"_ZTS1B", type: !9, declaration: !8, variables: !33) !33 = !{!34} !34 = !DILocalVariable(name: "this", arg: 1, flags: DIFlagArtificial | DIFlagObjectPointer, scope: !32, type: !31) !35 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/DebugInfo/ARM/constant-dbgloc.ll b/test/DebugInfo/ARM/constant-dbgloc.ll index 168a8dd523a..5fd219af86c 100644 --- a/test/DebugInfo/ARM/constant-dbgloc.ll +++ b/test/DebugInfo/ARM/constant-dbgloc.ll @@ -13,7 +13,7 @@ target triple = "armv7--linux-gnueabihf" ; CHECK: mvn ; Function Attrs: nounwind -define i32 @main() { +define i32 @main() !dbg !4 { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval @@ -27,7 +27,7 @@ entry: !1 = !DIFile(filename: "test.c", directory: "/home/user/clang/build") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{!7} !7 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/DebugInfo/ARM/float-args.ll b/test/DebugInfo/ARM/float-args.ll index b567b4e5e31..9ec7db2bdf0 100644 --- a/test/DebugInfo/ARM/float-args.ll +++ b/test/DebugInfo/ARM/float-args.ll @@ -16,7 +16,7 @@ target datalayout = "e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64" target triple = "armv7--none-eabi" -define float @foo(float %p) { +define float @foo(float %p) !dbg !4 { entry: tail call void @llvm.dbg.value(metadata float %p, i64 0, metadata !9, metadata !15), !dbg !16 ret float %p, !dbg !18 @@ -31,7 +31,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) !1 = !DIFile(filename: "test.c", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: true, function: float (float)* @foo, variables: !8) +!4 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: true, variables: !8) !5 = !DISubroutineType(types: !6) !6 = !{!7, !7} !7 = !DIBasicType(name: "float", size: 32, align: 32, encoding: DW_ATE_float) diff --git a/test/DebugInfo/ARM/header.ll b/test/DebugInfo/ARM/header.ll index 67accd0fa53..bb1f141c84d 100644 --- a/test/DebugInfo/ARM/header.ll +++ b/test/DebugInfo/ARM/header.ll @@ -12,7 +12,7 @@ ; CHECK: .section __DWARF,__debug_str,regular,debug -define void @f() { +define void @f() !dbg !4 { ret void, !dbg !9 } !llvm.dbg.cu = !{!0} @@ -22,7 +22,7 @@ define void @f() { !1 = !DIFile(filename: "/foo/test.c", directory: "/foo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: true, function: void ()* @f, variables: !2) +!4 = distinct !DISubprogram(name: "f", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: true, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/DebugInfo/ARM/lowerbdgdeclare_vla.ll b/test/DebugInfo/ARM/lowerbdgdeclare_vla.ll index cf8bd89f676..806bbc3b1d1 100644 --- a/test/DebugInfo/ARM/lowerbdgdeclare_vla.ll +++ b/test/DebugInfo/ARM/lowerbdgdeclare_vla.ll @@ -17,7 +17,7 @@ target datalayout = "e-p:32:32:32-i1:8:32-i8:8:32-i16:16:32-i32:32:32-i64:32:64- target triple = "thumbv7-apple-ios8.0.0" ; Function Attrs: nounwind optsize readnone -define void @run(float %r) #0 { +define void @run(float %r) #0 !dbg !4 { entry: tail call void @llvm.dbg.declare(metadata float %r, metadata !11, metadata !DIExpression()), !dbg !22 %conv = fptosi float %r to i32, !dbg !23 @@ -71,7 +71,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "<unknown>", directory: "/Volumes/Data/radar/15464571") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "run", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !5, scope: !6, type: !7, function: void (float)* @run, variables: !10) +!4 = distinct !DISubprogram(name: "run", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !5, scope: !6, type: !7, variables: !10) !5 = !DIFile(filename: "test.c", directory: "/Volumes/Data/radar/15464571") !6 = !DIFile(filename: "test.c", directory: "/Volumes/Data/radar/15464571") !7 = !DISubroutineType(types: !8) diff --git a/test/DebugInfo/ARM/multiple-constant-uses-drops-dbgloc.ll b/test/DebugInfo/ARM/multiple-constant-uses-drops-dbgloc.ll index 59f5a672ae7..de3bee248a1 100644 --- a/test/DebugInfo/ARM/multiple-constant-uses-drops-dbgloc.ll +++ b/test/DebugInfo/ARM/multiple-constant-uses-drops-dbgloc.ll @@ -19,7 +19,7 @@ target triple = "armv7--linux-gnueabihf" @b = common global i32 0, align 4 ; Function Attrs: nounwind -define void @proc() #0 { +define void @proc() #0 !dbg !4 { entry: store i8 65, i8* @ch, align 1, !dbg !17 store i32 0, i32* @b, align 4, !dbg !18 @@ -36,7 +36,7 @@ attributes #0 = { nounwind "less-precise-fpmad"="false" "no-frame-pointer-elim"= !1 = !DIFile(filename: "test.c", directory: "/home/user/clang/build") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "proc", scope: !1, file: !1, line: 4, type: !5, isLocal: false, isDefinition: true, scopeLine: 5, flags: DIFlagPrototyped, isOptimized: false, function: void ()* @proc, variables: !2) +!4 = distinct !DISubprogram(name: "proc", scope: !1, file: !1, line: 4, type: !5, isLocal: false, isDefinition: true, scopeLine: 5, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = !{!8, !10} diff --git a/test/DebugInfo/ARM/prologue_end.ll b/test/DebugInfo/ARM/prologue_end.ll index 317c806134f..9194bf3284a 100644 --- a/test/DebugInfo/ARM/prologue_end.ll +++ b/test/DebugInfo/ARM/prologue_end.ll @@ -7,7 +7,7 @@ ; func(); ; } -define void @prologue_end_test() nounwind uwtable { +define void @prologue_end_test() nounwind uwtable !dbg !4 { ; CHECK: prologue_end_test: ; CHECK: .cfi_startproc ; CHECK: push {r7, lr} @@ -32,7 +32,7 @@ declare i32 @func() !1 = !DIFile(filename: "foo.c", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "prologue_end_test", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: false, function: void ()* @prologue_end_test, variables: !2) +!4 = distinct !DISubprogram(name: "prologue_end_test", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = !{i32 2, !"Dwarf Version", i32 2} diff --git a/test/DebugInfo/ARM/s-super-register.ll b/test/DebugInfo/ARM/s-super-register.ll index be17080442b..887d37e2763 100644 --- a/test/DebugInfo/ARM/s-super-register.ll +++ b/test/DebugInfo/ARM/s-super-register.ll @@ -9,7 +9,7 @@ target triple = "thumbv7-apple-macosx10.6.7" ; 0x9d DW_OP_bit_piece ; CHECK: Location description: 90 {{.. .. ((93 ..)|(9d .. ..)) $}} -define void @_Z3foov() optsize ssp { +define void @_Z3foov() optsize ssp !dbg !1 { entry: %call = tail call float @_Z3barv() optsize, !dbg !11 tail call void @llvm.dbg.value(metadata float %call, i64 0, metadata !5, metadata !DIExpression()), !dbg !11 @@ -41,7 +41,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.module.flags = !{!20} !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.0 (trunk 130845)", isOptimized: true, emissionKind: 1, file: !18, enums: !19, retainedTypes: !19, subprograms: !16, imports: null) -!1 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foov", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !18, scope: !2, type: !3, function: void ()* @_Z3foov, variables: !17) +!1 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foov", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !18, scope: !2, type: !3, variables: !17) !2 = !DIFile(filename: "k.cc", directory: "/private/tmp") !3 = !DISubroutineType(types: !4) !4 = !{null} diff --git a/test/DebugInfo/ARM/selectiondag-deadcode.ll b/test/DebugInfo/ARM/selectiondag-deadcode.ll index dbf65cf0776..fe5e87658dd 100644 --- a/test/DebugInfo/ARM/selectiondag-deadcode.ll +++ b/test/DebugInfo/ARM/selectiondag-deadcode.ll @@ -1,7 +1,7 @@ ; RUN: llc -filetype=asm < %s | FileCheck %s target triple = "thumbv7-apple-ios7.0.0" %class.Matrix3.0.6.10 = type { [9 x float] } -define arm_aapcscc void @_Z9GetMatrixv(%class.Matrix3.0.6.10* noalias nocapture sret %agg.result) #0 { +define arm_aapcscc void @_Z9GetMatrixv(%class.Matrix3.0.6.10* noalias nocapture sret %agg.result) #0 !dbg !39 { br i1 fcmp oeq (float fadd (float fadd (float fmul (float undef, float undef), float fmul (float undef, float undef)), float fmul (float undef, float undef)), float 0.000000e+00), label %_ZN7Vector39NormalizeEv.exit, label %1 tail call arm_aapcscc void @_ZL4Sqrtd() #3 br label %_ZN7Vector39NormalizeEv.exit @@ -21,7 +21,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 declare arm_aapcscc void @_ZL4Sqrtd() #2 !4 = !DICompositeType(tag: DW_TAG_class_type, name: "Matrix3", line: 20, size: 288, align: 32, file: !5, identifier: "_ZTS7Matrix3") !5 = !DIFile(filename: "test.ii", directory: "/Volumes/Data/radar/15094721") -!39 = distinct !DISubprogram(name: "GetMatrix", linkageName: "_Z9GetMatrixv", line: 32, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 32, file: !5, scope: !40, type: !41, function: void (%class.Matrix3.0.6.10*)* @_Z9GetMatrixv) +!39 = distinct !DISubprogram(name: "GetMatrix", linkageName: "_Z9GetMatrixv", line: 32, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 32, file: !5, scope: !40, type: !41) !40 = !DIFile(filename: "test.ii", directory: "/Volumes/Data/radar/15094721") !41 = !DISubroutineType(types: null) !45 = !DILocalVariable(name: "matrix", line: 35, scope: !39, file: !40, type: !4) diff --git a/test/DebugInfo/ARM/single-constant-use-preserves-dbgloc.ll b/test/DebugInfo/ARM/single-constant-use-preserves-dbgloc.ll index a2f1198b009..9bd7becb35b 100644 --- a/test/DebugInfo/ARM/single-constant-use-preserves-dbgloc.ll +++ b/test/DebugInfo/ARM/single-constant-use-preserves-dbgloc.ll @@ -16,7 +16,7 @@ target datalayout = "e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64" target triple = "armv7--linux-gnueabihf" ; Function Attrs: nounwind -define i32 @main() { +define i32 @main() !dbg !4 { entry: %retval = alloca i32, align 4 %x = alloca i32, align 4 @@ -52,7 +52,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) !1 = !DIFile(filename: "test.c", directory: "/home/user/clang/build") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: false, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{!7} !7 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/DebugInfo/COFF/asan-module-ctor.ll b/test/DebugInfo/COFF/asan-module-ctor.ll index 8e6ca6254cc..f132eb42570 100644 --- a/test/DebugInfo/COFF/asan-module-ctor.ll +++ b/test/DebugInfo/COFF/asan-module-ctor.ll @@ -24,7 +24,7 @@ target triple = "i686-pc-win32" @llvm.global_ctors = appending global [1 x { i32, void ()* }] [{ i32, void ()* } { i32 1, void ()* @asan.module_ctor }] ; Function Attrs: nounwind sanitize_address -define i32 @foo() #0 { +define i32 @foo() #0 !dbg !4 { entry: ret i32 0, !dbg !10 } @@ -86,7 +86,7 @@ attributes #0 = { nounwind sanitize_address "less-precise-fpmad"="false" "no-fra !1 = !DIFile(filename: "asan.c", directory: "D:\5C") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 ()* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "asan.c", directory: "D:C") !6 = !DISubroutineType(types: !2) !7 = !{i32 2, !"CodeView", i32 1} diff --git a/test/DebugInfo/COFF/asm.ll b/test/DebugInfo/COFF/asm.ll index c1bc9360968..b868b5c53fb 100644 --- a/test/DebugInfo/COFF/asm.ll +++ b/test/DebugInfo/COFF/asm.ll @@ -251,7 +251,7 @@ ; OBJ64: } ; Function Attrs: nounwind -define void @f() #0 { +define void @f() #0 !dbg !4 { entry: call void asm sideeffect inteldialect ".align 4", "~{dirflag},~{fpsr},~{flags}"() #2, !dbg !12 call void @g(), !dbg !13 @@ -272,7 +272,7 @@ attributes #2 = { nounwind } !1 = !DIFile(filename: "<unknown>", directory: "D:\5C") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !5, scope: !6, type: !7, function: void ()* @f, variables: !2) +!4 = distinct !DISubprogram(name: "f", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !5, scope: !6, type: !7, variables: !2) !5 = !DIFile(filename: "asm.c", directory: "D:\5C") !6 = !DIFile(filename: "asm.c", directory: "D:C") !7 = !DISubroutineType(types: !8) diff --git a/test/DebugInfo/COFF/cpp-mangling.ll b/test/DebugInfo/COFF/cpp-mangling.ll index 505b5f70a6a..25461baa226 100644 --- a/test/DebugInfo/COFF/cpp-mangling.ll +++ b/test/DebugInfo/COFF/cpp-mangling.ll @@ -33,7 +33,7 @@ attributes #0 = { nounwind "less-precise-fpmad"="false" "no-frame-pointer-elim"= !1 = !DIFile(filename: "<stdin>", directory: "D:\5C") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "bar", line: 2, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !5, scope: !6, type: !7, function: i32 (i32)* @"\01?bar@foo@@YAHH@Z", variables: !2) +!4 = distinct !DISubprogram(name: "bar", line: 2, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !5, scope: !6, type: !7, variables: !2) !5 = !DIFile(filename: "src.cpp", directory: "D:\5C") !6 = !DIFile(filename: "src.cpp", directory: "D:C") !7 = !DISubroutineType(types: !2) diff --git a/test/DebugInfo/COFF/multifile.ll b/test/DebugInfo/COFF/multifile.ll index 788c8c1ec5c..70d03e971ce 100644 --- a/test/DebugInfo/COFF/multifile.ll +++ b/test/DebugInfo/COFF/multifile.ll @@ -327,7 +327,7 @@ ; OBJ64: } ; Function Attrs: nounwind -define void @f() #0 { +define void @f() #0 !dbg !4 { entry: call void @g(), !dbg !12 call void @g(), !dbg !15 @@ -348,7 +348,7 @@ attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" " !1 = !DIFile(filename: "<unknown>", directory: "D:\5C") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !5, scope: !6, type: !7, function: void ()* @f, variables: !2) +!4 = distinct !DISubprogram(name: "f", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !5, scope: !6, type: !7, variables: !2) !5 = !DIFile(filename: "input.c", directory: "D:\5C") !6 = !DIFile(filename: "input.c", directory: "D:C") !7 = !DISubroutineType(types: !8) diff --git a/test/DebugInfo/COFF/multifunction.ll b/test/DebugInfo/COFF/multifunction.ll index cb346f58d1f..b6be809b9bc 100644 --- a/test/DebugInfo/COFF/multifunction.ll +++ b/test/DebugInfo/COFF/multifunction.ll @@ -630,7 +630,7 @@ ; OBJ64: } ; Function Attrs: nounwind -define void @x() #0 { +define void @x() #0 !dbg !4 { entry: call void @z(), !dbg !14 ret void, !dbg !15 @@ -639,14 +639,14 @@ entry: declare void @z() #1 ; Function Attrs: nounwind -define void @y() #0 { +define void @y() #0 !dbg !9 { entry: call void @z(), !dbg !16 ret void, !dbg !17 } ; Function Attrs: nounwind -define void @f() #0 { +define void @f() #0 !dbg !10 { entry: call void @x(), !dbg !18 call void @y(), !dbg !19 @@ -665,13 +665,13 @@ attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" " !1 = !DIFile(filename: "<unknown>", directory: "D:\5C") !2 = !{} !3 = !{!4, !9, !10} -!4 = distinct !DISubprogram(name: "x", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !5, scope: !6, type: !7, function: void ()* @x, variables: !2) +!4 = distinct !DISubprogram(name: "x", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !5, scope: !6, type: !7, variables: !2) !5 = !DIFile(filename: "source.c", directory: "D:\5C") !6 = !DIFile(filename: "source.c", directory: "D:C") !7 = !DISubroutineType(types: !8) !8 = !{null} -!9 = distinct !DISubprogram(name: "y", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !5, scope: !6, type: !7, function: void ()* @y, variables: !2) -!10 = distinct !DISubprogram(name: "f", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 11, file: !5, scope: !6, type: !7, function: void ()* @f, variables: !2) +!9 = distinct !DISubprogram(name: "y", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !5, scope: !6, type: !7, variables: !2) +!10 = distinct !DISubprogram(name: "f", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 11, file: !5, scope: !6, type: !7, variables: !2) !11 = !{i32 2, !"CodeView", i32 1} !12 = !{i32 1, !"Debug Info Version", i32 3} !13 = !{!"clang version 3.5 "} diff --git a/test/DebugInfo/COFF/simple.ll b/test/DebugInfo/COFF/simple.ll index f12f14c7ca6..4479ecd8cf7 100644 --- a/test/DebugInfo/COFF/simple.ll +++ b/test/DebugInfo/COFF/simple.ll @@ -229,7 +229,7 @@ ; OBJ64: } ; Function Attrs: nounwind -define void @f() #0 { +define void @f() #0 !dbg !4 { entry: call void @g(), !dbg !12 ret void, !dbg !13 @@ -248,7 +248,7 @@ attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" " !1 = !DIFile(filename: "<unknown>", directory: "D:\5C") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !5, scope: !6, type: !7, function: void ()* @f, variables: !2) +!4 = distinct !DISubprogram(name: "f", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !5, scope: !6, type: !7, variables: !2) !5 = !DIFile(filename: "test.c", directory: "D:\5C") !6 = !DIFile(filename: "test.c", directory: "D:C") !7 = !DISubroutineType(types: !8) diff --git a/test/DebugInfo/COFF/tail-call-without-lexical-scopes.ll b/test/DebugInfo/COFF/tail-call-without-lexical-scopes.ll index a4b48e37231..28b8d2859ef 100644 --- a/test/DebugInfo/COFF/tail-call-without-lexical-scopes.ll +++ b/test/DebugInfo/COFF/tail-call-without-lexical-scopes.ll @@ -66,7 +66,7 @@ attributes #2 = { nounwind } !1 = !DIFile(filename: "test.cpp", directory: "D:\5C") !2 = !{} !3 = !{!4, !7} -!4 = distinct !DISubprogram(name: "spam", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 7, file: !1, scope: !5, type: !6, function: void ()* @"\01?spam@@YAXXZ", variables: !2) +!4 = distinct !DISubprogram(name: "spam", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 7, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "test.cpp", directory: "D:C") !6 = !DISubroutineType(types: !2) !7 = distinct !DISubprogram(name: "bar", line: 3, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !2) diff --git a/test/DebugInfo/Generic/2009-11-05-DeadGlobalVariable.ll b/test/DebugInfo/Generic/2009-11-05-DeadGlobalVariable.ll index 3791005dcfe..40dacf8848b 100644 --- a/test/DebugInfo/Generic/2009-11-05-DeadGlobalVariable.ll +++ b/test/DebugInfo/Generic/2009-11-05-DeadGlobalVariable.ll @@ -2,7 +2,7 @@ ; Here variable bar is optimized away. Do not trip over while trying to generate debug info. -define i32 @foo() nounwind uwtable readnone ssp { +define i32 @foo() nounwind uwtable readnone ssp !dbg !5 { entry: ret i32 42, !dbg !15 } @@ -13,7 +13,7 @@ entry: !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 (trunk 139632)", isOptimized: true, emissionKind: 0, file: !17, enums: !1, retainedTypes: !1, subprograms: !3, globals: !12) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !17, scope: !6, type: !7, function: i32 ()* @foo) +!5 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !17, scope: !6, type: !7) !6 = !DIFile(filename: "fb.c", directory: "/private/tmp") !7 = !DISubroutineType(types: !8) !8 = !{!9} diff --git a/test/DebugInfo/Generic/2009-11-10-CurrentFn.ll b/test/DebugInfo/Generic/2009-11-10-CurrentFn.ll index 7817a73ed97..b0961135ebf 100644 --- a/test/DebugInfo/Generic/2009-11-10-CurrentFn.ll +++ b/test/DebugInfo/Generic/2009-11-10-CurrentFn.ll @@ -1,6 +1,6 @@ ; RUN: llc < %s -o /dev/null -define void @bar(i32 %i) nounwind uwtable ssp { +define void @bar(i32 %i) nounwind uwtable ssp !dbg !5 { entry: tail call void (...) @foo() nounwind, !dbg !14 ret void, !dbg !16 @@ -16,7 +16,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 (trunk 139632)", isOptimized: true, emissionKind: 0, file: !17, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "bar", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !17, scope: !6, type: !7, function: void (i32)* @bar, variables: !9) +!5 = distinct !DISubprogram(name: "bar", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !17, scope: !6, type: !7, variables: !9) !6 = !DIFile(filename: "cf.c", directory: "/private/tmp") !7 = !DISubroutineType(types: !8) !8 = !{null} diff --git a/test/DebugInfo/Generic/2010-03-24-MemberFn.ll b/test/DebugInfo/Generic/2010-03-24-MemberFn.ll index 298c30e3de2..5f63ce295fa 100644 --- a/test/DebugInfo/Generic/2010-03-24-MemberFn.ll +++ b/test/DebugInfo/Generic/2010-03-24-MemberFn.ll @@ -2,7 +2,7 @@ ; Here _ZN1S3fooEv is defined in header file identified as AT_decl_file no. 2 in debug info. %struct.S = type <{ i8 }> -define i32 @_Z3barv() nounwind ssp { +define i32 @_Z3barv() nounwind ssp !dbg !3 { entry: %retval = alloca i32 ; <i32*> [#uses=2] %0 = alloca i32 ; <i32*> [#uses=2] @@ -20,7 +20,7 @@ return: ; preds = %entry ret i32 %retval1, !dbg !16 } -define linkonce_odr i32 @_ZN1S3fooEv(%struct.S* %this) nounwind ssp align 2 { +define linkonce_odr i32 @_ZN1S3fooEv(%struct.S* %this) nounwind ssp align 2 !dbg !12 { entry: %this_addr = alloca %struct.S* ; <%struct.S**> [#uses=1] %retval = alloca i32 ; <i32*> [#uses=1] @@ -42,7 +42,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !0 = !DILocalVariable(name: "s1", line: 3, scope: !1, file: !4, type: !9) !1 = distinct !DILexicalBlock(line: 3, column: 0, file: !25, scope: !2) !2 = distinct !DILexicalBlock(line: 3, column: 0, file: !25, scope: !3) -!3 = distinct !DISubprogram(name: "bar", linkageName: "_Z3barv", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 3, file: !25, scope: !4, type: !6, function: i32 ()* @_Z3barv) +!3 = distinct !DISubprogram(name: "bar", linkageName: "_Z3barv", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 3, file: !25, scope: !4, type: !6) !4 = !DIFile(filename: "one.cc", directory: "/tmp/") !5 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: false, emissionKind: 0, file: !25, enums: !27, retainedTypes: !27, subprograms: !24, imports: null) !6 = !DISubroutineType(types: !7) @@ -51,7 +51,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !9 = !DICompositeType(tag: DW_TAG_structure_type, name: "S", line: 2, size: 8, align: 8, file: !26, scope: !4, elements: !11) !10 = !DIFile(filename: "one.h", directory: "/tmp/") !11 = !{!12} -!12 = distinct !DISubprogram(name: "foo", linkageName: "_ZN1S3fooEv", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 3, file: !26, scope: !9, type: !13, function: i32 (%struct.S*)* @_ZN1S3fooEv) +!12 = distinct !DISubprogram(name: "foo", linkageName: "_ZN1S3fooEv", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 3, file: !26, scope: !9, type: !13) !13 = !DISubroutineType(types: !14) !14 = !{!8, !15} !15 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial, file: !25, scope: !4, baseType: !9) diff --git a/test/DebugInfo/Generic/2010-04-06-NestedFnDbgInfo.ll b/test/DebugInfo/Generic/2010-04-06-NestedFnDbgInfo.ll index fd9124ad00a..a85ad9adcf7 100644 --- a/test/DebugInfo/Generic/2010-04-06-NestedFnDbgInfo.ll +++ b/test/DebugInfo/Generic/2010-04-06-NestedFnDbgInfo.ll @@ -21,7 +21,7 @@ %class.A = type { i8 } %class.B = type { i8 } -define i32 @main() ssp { +define i32 @main() ssp !dbg !2 { entry: %retval = alloca i32, align 4 ; <i32*> [#uses=3] %b = alloca %class.A, align 1 ; <%class.A*> [#uses=1] @@ -35,7 +35,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone -define linkonce_odr i32 @_ZN1B2fnEv(%class.A* %this) ssp align 2 { +define linkonce_odr i32 @_ZN1B2fnEv(%class.A* %this) ssp align 2 !dbg !10 { entry: %retval = alloca i32, align 4 ; <i32*> [#uses=2] %this.addr = alloca %class.A*, align 8 ; <%class.A**> [#uses=2] @@ -54,7 +54,7 @@ entry: ret i32 %0, !dbg !32 } -define internal i32 @_ZZN1B2fnEvEN1A3fooEv(%class.A* %this) ssp align 2 { +define internal i32 @_ZZN1B2fnEvEN1A3fooEv(%class.A* %this) ssp align 2 !dbg !23 { entry: %retval = alloca i32, align 4 ; <i32*> [#uses=2] %this.addr = alloca %class.A*, align 8 ; <%class.A**> [#uses=2] @@ -72,7 +72,7 @@ entry: !0 = !DILocalVariable(name: "b", line: 16, scope: !1, file: !3, type: !8) !1 = distinct !DILexicalBlock(line: 15, column: 12, file: !38, scope: !2) -!2 = distinct !DISubprogram(name: "main", linkageName: "main", line: 15, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 15, file: !38, scope: !3, type: !5, function: i32 ()* @main) +!2 = distinct !DISubprogram(name: "main", linkageName: "main", line: 15, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 15, file: !38, scope: !3, type: !5) !3 = !DIFile(filename: "one.cc", directory: "/tmp") !4 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang 1.5", isOptimized: false, emissionKind: 0, file: !38, enums: !39, retainedTypes: !39, subprograms: !37, imports: null) !5 = !DISubroutineType(types: !6) @@ -80,7 +80,7 @@ entry: !7 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !8 = !DICompositeType(tag: DW_TAG_class_type, name: "B", line: 2, size: 8, align: 8, file: !38, scope: !3, elements: !9) !9 = !{!10} -!10 = distinct !DISubprogram(name: "fn", linkageName: "_ZN1B2fnEv", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 4, file: !38, scope: !8, type: !11, function: i32 (%class.A*)* @_ZN1B2fnEv) +!10 = distinct !DISubprogram(name: "fn", linkageName: "_ZN1B2fnEv", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 4, file: !38, scope: !8, type: !11) !11 = !DISubroutineType(types: !12) !12 = !{!7, !13} !13 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial, file: !38, scope: !3, baseType: !8) @@ -93,7 +93,7 @@ entry: !20 = distinct !DILexicalBlock(line: 4, column: 12, file: !38, scope: !10) !21 = !DICompositeType(tag: DW_TAG_class_type, name: "A", line: 5, size: 8, align: 8, file: !38, scope: !10, elements: !22) !22 = !{!23} -!23 = distinct !DISubprogram(name: "foo", linkageName: "_ZZN1B2fnEvEN1A3fooEv", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 7, file: !38, scope: !21, type: !24, function: i32 (%class.A*)* @_ZZN1B2fnEvEN1A3fooEv) +!23 = distinct !DISubprogram(name: "foo", linkageName: "_ZZN1B2fnEvEN1A3fooEv", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 7, file: !38, scope: !21, type: !24) !24 = !DISubroutineType(types: !25) !25 = !{!7, !26} !26 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial, file: !38, scope: !3, baseType: !21) diff --git a/test/DebugInfo/Generic/2010-04-19-FramePtr.ll b/test/DebugInfo/Generic/2010-04-19-FramePtr.ll index 0b4cee03b25..3b7280028c0 100644 --- a/test/DebugInfo/Generic/2010-04-19-FramePtr.ll +++ b/test/DebugInfo/Generic/2010-04-19-FramePtr.ll @@ -4,7 +4,7 @@ ; RUN: grep -v DW_AT_APPLE_omit_frame_ptr %t -define i32 @foo() nounwind ssp { +define i32 @foo() nounwind ssp !dbg !1 { entry: %retval = alloca i32 ; <i32*> [#uses=2] %0 = alloca i32 ; <i32*> [#uses=2] @@ -24,7 +24,7 @@ return: ; preds = %entry !9 = !{!1} !0 = !DILocation(line: 2, scope: !1) -!1 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 2, file: !10, scope: null, type: !4, function: i32 ()* @foo) +!1 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 2, file: !10, scope: null, type: !4) !2 = !DIFile(filename: "a.c", directory: "/tmp") !3 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: false, emissionKind: 0, file: !10, enums: !11, retainedTypes: !11, subprograms: !9, imports: null) !4 = !DISubroutineType(types: !5) diff --git a/test/DebugInfo/Generic/2010-05-10-MultipleCU.ll b/test/DebugInfo/Generic/2010-05-10-MultipleCU.ll index 92277a97d21..486dbf0e940 100644 --- a/test/DebugInfo/Generic/2010-05-10-MultipleCU.ll +++ b/test/DebugInfo/Generic/2010-05-10-MultipleCU.ll @@ -7,12 +7,12 @@ ; CHECK: Compile Unit: ; CHECK: Compile Unit: -define i32 @foo() nounwind readnone ssp { +define i32 @foo() nounwind readnone ssp !dbg !2 { return: ret i32 42, !dbg !0 } -define i32 @bar() nounwind readnone ssp { +define i32 @bar() nounwind readnone ssp !dbg !10 { return: ret i32 21, !dbg !8 } @@ -24,7 +24,7 @@ return: !0 = !DILocation(line: 3, scope: !1) !1 = distinct !DILexicalBlock(line: 2, column: 0, file: !18, scope: !2) -!2 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !18, scope: !3, type: !5, function: i32 ()* @foo) +!2 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !18, scope: !3, type: !5) !3 = !DIFile(filename: "a.c", directory: "/tmp/") !4 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: false, emissionKind: 0, file: !18, enums: !19, retainedTypes: !19, subprograms: !16) !5 = !DISubroutineType(types: !6) @@ -32,7 +32,7 @@ return: !7 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !8 = !DILocation(line: 3, scope: !9) !9 = distinct !DILexicalBlock(line: 2, column: 0, file: !20, scope: !10) -!10 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !20, scope: !11, type: !13, function: i32 ()* @bar) +!10 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !20, scope: !11, type: !13) !11 = !DIFile(filename: "b.c", directory: "/tmp/") !12 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: false, emissionKind: 0, file: !20, enums: !19, retainedTypes: !19, subprograms: !17) !13 = !DISubroutineType(types: !14) diff --git a/test/DebugInfo/Generic/2010-06-29-InlinedFnLocalVar.ll b/test/DebugInfo/Generic/2010-06-29-InlinedFnLocalVar.ll index feba316213a..f01cf6db905 100644 --- a/test/DebugInfo/Generic/2010-06-29-InlinedFnLocalVar.ll +++ b/test/DebugInfo/Generic/2010-06-29-InlinedFnLocalVar.ll @@ -12,7 +12,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnone -define i32 @bar() nounwind ssp { +define i32 @bar() nounwind ssp !dbg !6 { entry: %0 = load i32, i32* @i, align 4, !dbg !17 ; <i32> [#uses=2] tail call void @llvm.dbg.value(metadata i32 %0, i64 0, metadata !59, metadata !DIExpression()), !dbg !19 @@ -31,7 +31,7 @@ entry: !3 = !DISubroutineType(types: !4) !4 = !{!5, !5} !5 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!6 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !27, scope: !1, type: !7, function: i32 ()* @bar) +!6 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !27, scope: !1, type: !7) !7 = !DISubroutineType(types: !8) !8 = !{!5} !9 = !DILocalVariable(name: "j", line: 9, arg: 1, scope: !0, file: !1, type: !5) diff --git a/test/DebugInfo/Generic/2010-07-19-Crash.ll b/test/DebugInfo/Generic/2010-07-19-Crash.ll index 3189f6fdb74..9565a2f09cb 100644 --- a/test/DebugInfo/Generic/2010-07-19-Crash.ll +++ b/test/DebugInfo/Generic/2010-07-19-Crash.ll @@ -2,7 +2,7 @@ ; PR7662 ; Do not add variables to !11 because it is a declaration entry. -define i32 @bar() nounwind readnone ssp { +define i32 @bar() nounwind readnone ssp !dbg !0 { entry: ret i32 42, !dbg !9 } @@ -12,7 +12,7 @@ entry: !llvm.dbg.sp = !{!0, !6, !11} !llvm.dbg.lv.foo = !{!7} -!0 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !12, scope: !1, type: !3, function: i32 ()* @bar) +!0 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !12, scope: !1, type: !3) !1 = !DIFile(filename: "one.c", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang 2.8", isOptimized: true, emissionKind: 0, file: !12, enums: !14, retainedTypes: !14, subprograms: !13) !3 = !DISubroutineType(types: !4) diff --git a/test/DebugInfo/Generic/2010-10-01-crash.ll b/test/DebugInfo/Generic/2010-10-01-crash.ll index 6ae48f1c408..712c32a7f62 100644 --- a/test/DebugInfo/Generic/2010-10-01-crash.ll +++ b/test/DebugInfo/Generic/2010-10-01-crash.ll @@ -1,6 +1,6 @@ ; RUN: llc -O0 %s -o /dev/null -define void @CGRectStandardize(i32* sret %agg.result, i32* byval %rect) nounwind ssp { +define void @CGRectStandardize(i32* sret %agg.result, i32* byval %rect) nounwind ssp !dbg !0 { entry: call void @llvm.dbg.declare(metadata i32* %rect, metadata !23, metadata !DIExpression()), !dbg !24 ret void @@ -13,7 +13,7 @@ declare void @llvm.memcpy.p0i8.p0i8.i32(i8* nocapture, i8* nocapture, i32, i32, !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!27} -!0 = distinct !DISubprogram(name: "CGRectStandardize", linkageName: "CGRectStandardize", line: 54, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !1, scope: null, function: void (i32*, i32*)* @CGRectStandardize) +!0 = distinct !DISubprogram(name: "CGRectStandardize", linkageName: "CGRectStandardize", line: 54, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !1, scope: null) !1 = !DIFile(filename: "GSFusedSilica.m", directory: "/Volumes/Data/Users/sabre/Desktop") !2 = distinct !DICompileUnit(language: DW_LANG_ObjC, producer: "clang version 2.9 (trunk 115292)", isOptimized: true, runtimeVersion: 1, emissionKind: 0, file: !25, enums: !26, retainedTypes: !26, subprograms: !{!0}) !5 = !DIDerivedType(tag: DW_TAG_typedef, name: "CGRect", line: 49, file: !25, baseType: null) diff --git a/test/DebugInfo/Generic/Inputs/gmlt.ll b/test/DebugInfo/Generic/Inputs/gmlt.ll index d73fef3b1de..b03a80b4dea 100644 --- a/test/DebugInfo/Generic/Inputs/gmlt.ll +++ b/test/DebugInfo/Generic/Inputs/gmlt.ll @@ -98,26 +98,26 @@ ; CHECK: .apple{{.*}} contents: ; Function Attrs: nounwind uwtable -define void @_Z2f1v() #0 { +define void @_Z2f1v() #0 !dbg !4 { entry: ret void, !dbg !13 } ; Function Attrs: nounwind uwtable -define void @_Z2f2v() #0 section "__TEXT,__bar" { +define void @_Z2f2v() #0 section "__TEXT,__bar" !dbg !7 { entry: ret void, !dbg !14 } ; Function Attrs: alwaysinline nounwind uwtable -define void @_Z2f3v() #1 { +define void @_Z2f3v() #1 !dbg !8 { entry: call void @_Z2f1v(), !dbg !15 ret void, !dbg !16 } ; Function Attrs: nounwind uwtable -define void @_Z2f4v() #0 { +define void @_Z2f4v() #0 !dbg !9 { entry: call void @_Z2f1v() #2, !dbg !17 ret void, !dbg !19 @@ -135,12 +135,12 @@ attributes #2 = { nounwind } !1 = !DIFile(filename: "gmlt.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4, !7, !8, !9} -!4 = distinct !DISubprogram(name: "f1", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: void ()* @_Z2f1v, variables: !2) +!4 = distinct !DISubprogram(name: "f1", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "gmlt.cpp", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !2) -!7 = distinct !DISubprogram(name: "f2", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, function: void ()* @_Z2f2v, variables: !2) -!8 = distinct !DISubprogram(name: "f3", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, function: void ()* @_Z2f3v, variables: !2) -!9 = distinct !DISubprogram(name: "f4", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !5, type: !6, function: void ()* @_Z2f4v, variables: !2) +!7 = distinct !DISubprogram(name: "f2", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) +!8 = distinct !DISubprogram(name: "f3", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !2) +!9 = distinct !DISubprogram(name: "f4", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !5, type: !6, variables: !2) !10 = !{i32 2, !"Dwarf Version", i32 4} !11 = !{i32 2, !"Debug Info Version", i32 3} !12 = !{!"clang version 3.6.0 "} diff --git a/test/DebugInfo/Generic/PR20038.ll b/test/DebugInfo/Generic/PR20038.ll index 8ad6d7834be..3e9145f03e8 100644 --- a/test/DebugInfo/Generic/PR20038.ll +++ b/test/DebugInfo/Generic/PR20038.ll @@ -55,7 +55,7 @@ @b = external global i8 ; Function Attrs: nounwind -define void @_Z4fun4v() #0 { +define void @_Z4fun4v() #0 !dbg !12 { entry: %this.addr.i.i = alloca %struct.C*, align 8, !dbg !21 %this.addr.i = alloca %struct.C*, align 8, !dbg !22 @@ -89,7 +89,7 @@ cleanup.done: ; preds = %cleanup.action, %la } ; Function Attrs: alwaysinline nounwind -define void @_ZN1CD1Ev(%struct.C* %this) unnamed_addr #1 align 2 { +define void @_ZN1CD1Ev(%struct.C* %this) unnamed_addr #1 align 2 !dbg !17 { entry: %this.addr.i = alloca %struct.C*, align 8, !dbg !37 %this.addr = alloca %struct.C*, align 8 @@ -103,7 +103,7 @@ entry: } ; Function Attrs: alwaysinline nounwind -define void @_ZN1CD2Ev(%struct.C* %this) unnamed_addr #1 align 2 { +define void @_ZN1CD2Ev(%struct.C* %this) unnamed_addr #1 align 2 !dbg !16 { entry: %this.addr = alloca %struct.C*, align 8 store %struct.C* %this, %struct.C** %this.addr, align 8 @@ -135,12 +135,12 @@ attributes #2 = { nounwind readnone } !9 = !{null, !10} !10 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS1C") !11 = !{!12, !16, !17} -!12 = distinct !DISubprogram(name: "fun4", linkageName: "_Z4fun4v", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !5, scope: !13, type: !14, function: void ()* @_Z4fun4v, variables: !2) +!12 = distinct !DISubprogram(name: "fun4", linkageName: "_Z4fun4v", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !5, scope: !13, type: !14, variables: !2) !13 = !DIFile(filename: "PR20038.cpp", directory: "/tmp/dbginfo") !14 = !DISubroutineType(types: !15) !15 = !{null} -!16 = distinct !DISubprogram(name: "~C", linkageName: "_ZN1CD2Ev", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !5, scope: !"_ZTS1C", type: !8, function: void (%struct.C*)* @_ZN1CD2Ev, declaration: !7, variables: !2) -!17 = distinct !DISubprogram(name: "~C", linkageName: "_ZN1CD1Ev", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !5, scope: !"_ZTS1C", type: !8, function: void (%struct.C*)* @_ZN1CD1Ev, declaration: !7, variables: !2) +!16 = distinct !DISubprogram(name: "~C", linkageName: "_ZN1CD2Ev", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !5, scope: !"_ZTS1C", type: !8, declaration: !7, variables: !2) +!17 = distinct !DISubprogram(name: "~C", linkageName: "_ZN1CD1Ev", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !5, scope: !"_ZTS1C", type: !8, declaration: !7, variables: !2) !18 = !{i32 2, !"Dwarf Version", i32 4} !19 = !{i32 2, !"Debug Info Version", i32 3} !20 = !{!"clang version 3.5.0 "} diff --git a/test/DebugInfo/Generic/array.ll b/test/DebugInfo/Generic/array.ll index a9571db23ff..2f181e3b595 100644 --- a/test/DebugInfo/Generic/array.ll +++ b/test/DebugInfo/Generic/array.ll @@ -1,7 +1,7 @@ ; RUN: %llc_dwarf -O0 < %s | FileCheck %s ; Do not emit AT_upper_bound for an unbounded array. ; radar 9241695 -define i32 @main() nounwind ssp { +define i32 @main() nounwind ssp !dbg !0 { entry: %retval = alloca i32, align 4 %a = alloca [0 x i32], align 4 @@ -15,7 +15,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!16} -!0 = distinct !DISubprogram(name: "main", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 3, file: !14, scope: !1, type: !3, function: i32 ()* @main) +!0 = distinct !DISubprogram(name: "main", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 3, file: !14, scope: !1, type: !3) !1 = !DIFile(filename: "array.c", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 (trunk 129138)", isOptimized: false, emissionKind: 0, file: !14, enums: !15, retainedTypes: !15, subprograms: !13, imports: null) !3 = !DISubroutineType(types: !4) diff --git a/test/DebugInfo/Generic/block-asan.ll b/test/DebugInfo/Generic/block-asan.ll index ae07e7b145b..92119631444 100644 --- a/test/DebugInfo/Generic/block-asan.ll +++ b/test/DebugInfo/Generic/block-asan.ll @@ -20,7 +20,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" %struct.__block_byref_x = type { i8*, %struct.__block_byref_x*, i32, i32, i32 } ; Function Attrs: nounwind ssp uwtable -define void @foo() #0 { +define void @foo() #0 !dbg !4 { entry: %x = alloca %struct.__block_byref_x, align 8 call void @llvm.dbg.declare(metadata %struct.__block_byref_x* %x, metadata !12, metadata !22), !dbg !23 @@ -62,7 +62,7 @@ attributes #3 = { nounwind } !1 = !DIFile(filename: "block.c", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, function: void ()* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "block.c", directory: "/tmp") !6 = !DISubroutineType(types: !7) !7 = !{null} diff --git a/test/DebugInfo/Generic/constant-pointers.ll b/test/DebugInfo/Generic/constant-pointers.ll index b46ee5d98f0..af0b6b0743c 100644 --- a/test/DebugInfo/Generic/constant-pointers.ll +++ b/test/DebugInfo/Generic/constant-pointers.ll @@ -19,7 +19,7 @@ ; CHECK: DW_AT_const_value [DW_FORM_udata] (0) ; Function Attrs: nounwind uwtable -define weak_odr void @_Z4funcILPv0ELPFvvE0ELi42EEvv() #0 { +define weak_odr void @_Z4funcILPv0ELPFvvE0ELi42EEvv() #0 !dbg !4 { entry: ret void, !dbg !18 } @@ -34,7 +34,7 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe !1 = !DIFile(filename: "constant-pointers.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "func<nullptr, nullptr, 42>", linkageName: "_Z4funcILPv0ELPFvvE0ELi42EEvv", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, function: void ()* @_Z4funcILPv0ELPFvvE0ELi42EEvv, templateParams: !8, variables: !2) +!4 = distinct !DISubprogram(name: "func<nullptr, nullptr, 42>", linkageName: "_Z4funcILPv0ELPFvvE0ELi42EEvv", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, templateParams: !8, variables: !2) !5 = !DIFile(filename: "constant-pointers.cpp", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !7) !7 = !{null} diff --git a/test/DebugInfo/Generic/constant-sdnodes-have-dbg-location.ll b/test/DebugInfo/Generic/constant-sdnodes-have-dbg-location.ll index 7fd9b98ba84..83377418518 100644 --- a/test/DebugInfo/Generic/constant-sdnodes-have-dbg-location.ll +++ b/test/DebugInfo/Generic/constant-sdnodes-have-dbg-location.ll @@ -3,7 +3,7 @@ ; CHECK: t{{[0-9]+}}: i32 = Constant<-1>test.c:4:5 -define i32 @main() { +define i32 @main() !dbg !4 { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval @@ -17,7 +17,7 @@ entry: !1 = !DIFile(filename: "test.c", directory: "/home/user/clang-llvm/build") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{!7} !7 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/DebugInfo/Generic/constantfp-sdnodes-have-dbg-location.ll b/test/DebugInfo/Generic/constantfp-sdnodes-have-dbg-location.ll index cb1dda9738e..6cf9178269c 100644 --- a/test/DebugInfo/Generic/constantfp-sdnodes-have-dbg-location.ll +++ b/test/DebugInfo/Generic/constantfp-sdnodes-have-dbg-location.ll @@ -3,7 +3,7 @@ ; CHECK: t{{[0-9]+}}: f64 = ConstantFP<1.500000e+00>test.c:3:5 -define double @f() { +define double @f() !dbg !4 { entry: ret double 1.500000e+00, !dbg !10 } @@ -15,7 +15,7 @@ entry: !1 = !DIFile(filename: "test.c", directory: "/home/user/clang-llvm/build") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, flags: DIFlagPrototyped, isOptimized: false, function: double ()* @f, variables: !2) +!4 = distinct !DISubprogram(name: "f", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{!7} !7 = !DIBasicType(name: "double", size: 64, align: 64, encoding: DW_ATE_float) diff --git a/test/DebugInfo/Generic/cross-cu-inlining.ll b/test/DebugInfo/Generic/cross-cu-inlining.ll index 6f9436ba1cf..d95b4340060 100644 --- a/test/DebugInfo/Generic/cross-cu-inlining.ll +++ b/test/DebugInfo/Generic/cross-cu-inlining.ll @@ -66,7 +66,7 @@ @i = external global i32 ; Function Attrs: uwtable -define i32 @main() #0 { +define i32 @main() #0 !dbg !4 { entry: %x.addr.i = alloca i32, align 4 %retval = alloca i32, align 4 @@ -84,7 +84,7 @@ entry: } ; Function Attrs: alwaysinline nounwind uwtable -define i32 @_Z4funci(i32 %x) #1 { +define i32 @_Z4funci(i32 %x) #1 !dbg !12 { entry: %x.addr = alloca i32, align 4 store i32 %x, i32* %x.addr, align 4 @@ -116,7 +116,7 @@ attributes #3 = { nounwind } !1 = !DIFile(filename: "a.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "a.cpp", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !7) !7 = !{!8} @@ -124,7 +124,7 @@ attributes #3 = { nounwind } !9 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.5.0 ", isOptimized: false, emissionKind: 1, file: !10, enums: !2, retainedTypes: !2, subprograms: !11, globals: !2, imports: !2) !10 = !DIFile(filename: "b.cpp", directory: "/tmp/dbginfo") !11 = !{!12} -!12 = distinct !DISubprogram(name: "func", linkageName: "_Z4funci", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !10, scope: !13, type: !14, function: i32 (i32)* @_Z4funci, variables: !2) +!12 = distinct !DISubprogram(name: "func", linkageName: "_Z4funci", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !10, scope: !13, type: !14, variables: !2) !13 = !DIFile(filename: "b.cpp", directory: "/tmp/dbginfo") !14 = !DISubroutineType(types: !15) !15 = !{!8, !8} diff --git a/test/DebugInfo/Generic/cross-cu-linkonce-distinct.ll b/test/DebugInfo/Generic/cross-cu-linkonce-distinct.ll index 25b6b971bce..1713ea112d4 100644 --- a/test/DebugInfo/Generic/cross-cu-linkonce-distinct.ll +++ b/test/DebugInfo/Generic/cross-cu-linkonce-distinct.ll @@ -49,7 +49,7 @@ @y = global i32 (i32)* @_Z4funci, align 8 ; Function Attrs: inlinehint nounwind uwtable -define linkonce_odr i32 @_Z4funci(i32 %i) #0 { +define linkonce_odr i32 @_Z4funci(i32 %i) #0 !dbg !4 { %1 = alloca i32, align 4 store i32 %i, i32* %1, align 4 call void @llvm.dbg.declare(metadata i32* %1, metadata !22, metadata !DIExpression()), !dbg !23 @@ -72,7 +72,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "a.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "func", linkageName: "_Z4funci", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 (i32)* @_Z4funci, variables: !2) +!4 = distinct !DISubprogram(name: "func", linkageName: "_Z4funci", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "a.cpp", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} @@ -83,7 +83,7 @@ attributes #1 = { nounwind readnone } !12 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.5.0 ", isOptimized: false, emissionKind: 1, file: !13, enums: !2, retainedTypes: !2, subprograms: !14, globals: !17, imports: !2) !13 = !DIFile(filename: "b.cpp", directory: "/tmp/dbginfo") !14 = !{!15} -!15 = distinct !DISubprogram(name: "func", linkageName: "_Z4funci", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !13, scope: !16, type: !6, function: i32 (i32)* @_Z4funci, variables: !2) +!15 = distinct !DISubprogram(name: "func", linkageName: "_Z4funci", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !13, scope: !16, type: !6, variables: !2) !16 = !DIFile(filename: "b.cpp", directory: "/tmp/dbginfo") !17 = !{!18} !18 = !DIGlobalVariable(name: "y", line: 4, isLocal: false, isDefinition: true, scope: null, file: !16, type: !11, variable: i32 (i32)** @y) diff --git a/test/DebugInfo/Generic/cross-cu-linkonce.ll b/test/DebugInfo/Generic/cross-cu-linkonce.ll index 50708d7ebe0..983871a1d0f 100644 --- a/test/DebugInfo/Generic/cross-cu-linkonce.ll +++ b/test/DebugInfo/Generic/cross-cu-linkonce.ll @@ -29,7 +29,7 @@ @y = global i32 (i32)* @_Z4funci, align 8 ; Function Attrs: inlinehint nounwind uwtable -define linkonce_odr i32 @_Z4funci(i32 %i) #0 { +define linkonce_odr i32 @_Z4funci(i32 %i) #0 !dbg !4 { %1 = alloca i32, align 4 store i32 %i, i32* %1, align 4 call void @llvm.dbg.declare(metadata i32* %1, metadata !20, metadata !DIExpression()), !dbg !21 @@ -52,7 +52,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "a.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "func", linkageName: "_Z4funci", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !5, scope: !6, type: !7, function: i32 (i32)* @_Z4funci, variables: !2) +!4 = distinct !DISubprogram(name: "func", linkageName: "_Z4funci", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !5, scope: !6, type: !7, variables: !2) !5 = !DIFile(filename: "func.h", directory: "/tmp/dbginfo") !6 = !DIFile(filename: "func.h", directory: "/tmp/dbginfo") !7 = !DISubroutineType(types: !8) diff --git a/test/DebugInfo/Generic/cu-range-hole.ll b/test/DebugInfo/Generic/cu-range-hole.ll index 96b5380d97c..12651a844ef 100644 --- a/test/DebugInfo/Generic/cu-range-hole.ll +++ b/test/DebugInfo/Generic/cu-range-hole.ll @@ -14,7 +14,7 @@ ; CHECK: DW_TAG_subprogram ; Function Attrs: nounwind uwtable -define i32 @b(i32 %c) #0 { +define i32 @b(i32 %c) #0 !dbg !5 { entry: %c.addr = alloca i32, align 4 store i32 %c, i32* %c.addr, align 4 @@ -38,7 +38,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: nounwind uwtable -define i32 @d(i32 %e) #0 { +define i32 @d(i32 %e) #0 !dbg !10 { entry: %e.addr = alloca i32, align 4 store i32 %e, i32* %e.addr, align 4 @@ -60,12 +60,12 @@ attributes #1 = { nounwind readnone } !2 = !DIFile(filename: "b.c", directory: "/usr/local/google/home/echristo") !3 = !{} !4 = !{!5, !10} -!5 = distinct !DISubprogram(name: "b", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !2, scope: !6, type: !7, function: i32 (i32)* @b, variables: !3) +!5 = distinct !DISubprogram(name: "b", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !2, scope: !6, type: !7, variables: !3) !6 = !DIFile(filename: "b.c", directory: "/usr/local/google/home/echristo") !7 = !DISubroutineType(types: !8) !8 = !{!9, !9} !9 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!10 = distinct !DISubprogram(name: "d", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !2, scope: !6, type: !7, function: i32 (i32)* @d, variables: !3) +!10 = distinct !DISubprogram(name: "d", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !2, scope: !6, type: !7, variables: !3) !11 = !{i32 2, !"Dwarf Version", i32 4} !12 = !{i32 1, !"Debug Info Version", i32 3} !13 = !DILocalVariable(name: "c", line: 1, arg: 1, scope: !5, file: !6, type: !9) diff --git a/test/DebugInfo/Generic/cu-ranges.ll b/test/DebugInfo/Generic/cu-ranges.ll index 03ddb2708bc..ab5577984e6 100644 --- a/test/DebugInfo/Generic/cu-ranges.ll +++ b/test/DebugInfo/Generic/cu-ranges.ll @@ -18,7 +18,7 @@ ; CHECK: 00000000 <End of list> ; Function Attrs: nounwind uwtable -define i32 @foo(i32 %a) #0 section "__TEXT,__foo" { +define i32 @foo(i32 %a) #0 section "__TEXT,__foo" !dbg !4 { entry: %a.addr = alloca i32, align 4 store i32 %a, i32* %a.addr, align 4 @@ -32,7 +32,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: nounwind uwtable -define i32 @bar(i32 %a) #0 { +define i32 @bar(i32 %a) #0 !dbg !9 { entry: %a.addr = alloca i32, align 4 store i32 %a, i32* %a.addr, align 4 @@ -53,12 +53,12 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "foo.c", directory: "/usr/local/google/home/echristo") !2 = !{} !3 = !{!4, !9} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "foo.c", directory: "/usr/local/google/home/echristo") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} !8 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!9 = distinct !DISubprogram(name: "bar", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !6, function: i32 (i32)* @bar, variables: !2) +!9 = distinct !DISubprogram(name: "bar", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !6, variables: !2) !10 = !{i32 2, !"Dwarf Version", i32 4} !11 = !{i32 1, !"Debug Info Version", i32 3} !12 = !{!"clang version 3.5.0 (trunk 204164) (llvm/trunk 204183)"} diff --git a/test/DebugInfo/Generic/dead-argument-order.ll b/test/DebugInfo/Generic/dead-argument-order.ll index b3ae5fe5e31..a6451a038cd 100644 --- a/test/DebugInfo/Generic/dead-argument-order.ll +++ b/test/DebugInfo/Generic/dead-argument-order.ll @@ -36,7 +36,7 @@ %struct.S = type { i32 } ; Function Attrs: nounwind readnone uwtable -define i32 @_Z8function1Si(i32 %s.coerce, i32 %i) #0 { +define i32 @_Z8function1Si(i32 %s.coerce, i32 %i) #0 !dbg !9 { entry: tail call void @llvm.dbg.declare(metadata %struct.S* undef, metadata !14, metadata !DIExpression()), !dbg !20 tail call void @llvm.dbg.value(metadata i32 %i, i64 0, metadata !15, metadata !DIExpression()), !dbg !20 @@ -66,7 +66,7 @@ attributes #1 = { nounwind readnone } !6 = !DIDerivedType(tag: DW_TAG_member, name: "i", line: 1, size: 32, align: 32, file: !1, scope: !"_ZTS1S", baseType: !7) !7 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !8 = !{!9} -!9 = distinct !DISubprogram(name: "function", linkageName: "_Z8function1Si", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !1, scope: !10, type: !11, function: i32 (i32, i32)* @_Z8function1Si, variables: !13) +!9 = distinct !DISubprogram(name: "function", linkageName: "_Z8function1Si", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !1, scope: !10, type: !11, variables: !13) !10 = !DIFile(filename: "dead-argument-order.cpp", directory: "/tmp/dbginfo") !11 = !DISubroutineType(types: !12) !12 = !{!7, !4, !7} diff --git a/test/DebugInfo/Generic/debug-info-qualifiers.ll b/test/DebugInfo/Generic/debug-info-qualifiers.ll index c13a5ea731b..aa197dd9f6f 100644 --- a/test/DebugInfo/Generic/debug-info-qualifiers.ll +++ b/test/DebugInfo/Generic/debug-info-qualifiers.ll @@ -35,7 +35,7 @@ %class.A = type { i8 } ; Function Attrs: nounwind -define void @_Z1gv() #0 { +define void @_Z1gv() #0 !dbg !17 { %a = alloca %class.A, align 1 %pl = alloca { i64, i64 }, align 8 %pr = alloca { i64, i64 }, align 8 @@ -76,7 +76,7 @@ attributes #1 = { nounwind readnone } !13 = !DISubprogram(name: "r", linkageName: "_ZNKO1A1rEv", line: 7, isLocal: false, isDefinition: false, virtualIndex: 6, flags: DIFlagObjectPointer | DIFlagRValueReference, isOptimized: false, scopeLine: 7, file: !5, scope: !"_ZTS1A", type: !14) !14 = !DISubroutineType(flags: DIFlagRValueReference, types: !9) !16 = !{!17} -!17 = distinct !DISubprogram(name: "g", linkageName: "_Z1gv", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !5, scope: !18, type: !19, function: void ()* @_Z1gv, variables: !2) +!17 = distinct !DISubprogram(name: "g", linkageName: "_Z1gv", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !5, scope: !18, type: !19, variables: !2) !18 = !DIFile(filename: "debug-info-qualifiers.cpp", directory: "") !19 = !DISubroutineType(types: !20) !20 = !{null} diff --git a/test/DebugInfo/Generic/debuginfofinder-multiple-cu.ll b/test/DebugInfo/Generic/debuginfofinder-multiple-cu.ll index 06ed02a4ce0..a4d226b86a6 100644 --- a/test/DebugInfo/Generic/debuginfofinder-multiple-cu.ll +++ b/test/DebugInfo/Generic/debuginfofinder-multiple-cu.ll @@ -11,11 +11,11 @@ ;CHECK: Subprogram: f from /tmp/test1.c:1 ;CHECK: Subprogram: g from /tmp/test2.c:1 -define void @f() { +define void @f() !dbg !4 { ret void, !dbg !14 } -define void @g() { +define void @g() !dbg !11 { ret void, !dbg !15 } @@ -26,14 +26,14 @@ define void @g() { !1 = !DIFile(filename: "test1.c", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: void ()* @f, variables: !2) +!4 = distinct !DISubprogram(name: "f", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "test1.c", directory: "/tmp") !6 = !DISubroutineType(types: !7) !7 = !{null} !8 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.4 (192092)", isOptimized: false, emissionKind: 0, file: !9, enums: !2, retainedTypes: !2, subprograms: !10, globals: !2, imports: !2) !9 = !DIFile(filename: "test2.c", directory: "/tmp") !10 = !{!11} -!11 = distinct !DISubprogram(name: "g", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !9, scope: !12, type: !6, function: void ()* @g, variables: !2) +!11 = distinct !DISubprogram(name: "g", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !9, scope: !12, type: !6, variables: !2) !12 = !DIFile(filename: "test2.c", directory: "/tmp") !13 = !{i32 2, !"Dwarf Version", i32 4} !14 = !DILocation(line: 1, scope: !4) diff --git a/test/DebugInfo/Generic/def-line.ll b/test/DebugInfo/Generic/def-line.ll index aa9830170b9..da9867952f1 100644 --- a/test/DebugInfo/Generic/def-line.ll +++ b/test/DebugInfo/Generic/def-line.ll @@ -43,20 +43,20 @@ ; CHECK: DW_AT_specification {{.*}}f3 ; Function Attrs: uwtable -define void @_ZN3foo2f2Ev() #0 align 2 { +define void @_ZN3foo2f2Ev() #0 align 2 !dbg !12 { entry: call void @_ZN3foo2f1Ev(), !dbg !19 ret void, !dbg !20 } ; Function Attrs: nounwind uwtable -define linkonce_odr void @_ZN3foo2f1Ev() #1 align 2 { +define linkonce_odr void @_ZN3foo2f1Ev() #1 align 2 !dbg !15 { entry: ret void, !dbg !21 } ; Function Attrs: nounwind uwtable -define void @_ZN3foo2f3Ev() #1 align 2 { +define void @_ZN3foo2f3Ev() #1 align 2 !dbg !13 { entry: ret void, !dbg !22 } @@ -80,10 +80,10 @@ attributes #1 = { nounwind uwtable "disable-tail-calls"="false" "less-precise-fp !9 = !DISubprogram(name: "f2", linkageName: "_ZN3foo2f2Ev", scope: !"_ZTS3foo", file: !1, line: 4, type: !7, isLocal: false, isDefinition: false, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: false) !10 = !DISubprogram(name: "f3", linkageName: "_ZN3foo2f3Ev", scope: !"_ZTS3foo", file: !1, line: 5, type: !7, isLocal: false, isDefinition: false, scopeLine: 5, flags: DIFlagPrototyped, isOptimized: false) !11 = !{!12, !13, !15} -!12 = distinct !DISubprogram(name: "f2", linkageName: "_ZN3foo2f2Ev", scope: !"_ZTS3foo", file: !1, line: 7, type: !7, isLocal: false, isDefinition: true, scopeLine: 7, flags: DIFlagPrototyped, isOptimized: false, function: void ()* @_ZN3foo2f2Ev, declaration: !9, variables: !2) -!13 = distinct !DISubprogram(name: "f3", linkageName: "_ZN3foo2f3Ev", scope: !"_ZTS3foo", file: !14, line: 1, type: !7, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: false, function: void ()* @_ZN3foo2f3Ev, declaration: !10, variables: !2) +!12 = distinct !DISubprogram(name: "f2", linkageName: "_ZN3foo2f2Ev", scope: !"_ZTS3foo", file: !1, line: 7, type: !7, isLocal: false, isDefinition: true, scopeLine: 7, flags: DIFlagPrototyped, isOptimized: false, declaration: !9, variables: !2) +!13 = distinct !DISubprogram(name: "f3", linkageName: "_ZN3foo2f3Ev", scope: !"_ZTS3foo", file: !14, line: 1, type: !7, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: false, declaration: !10, variables: !2) !14 = !DIFile(filename: "bar.cpp", directory: "/tmp/dbginfo") -!15 = distinct !DISubprogram(name: "f1", linkageName: "_ZN3foo2f1Ev", scope: !"_ZTS3foo", file: !1, line: 2, type: !7, isLocal: false, isDefinition: true, scopeLine: 2, flags: DIFlagPrototyped, isOptimized: false, function: void ()* @_ZN3foo2f1Ev, declaration: !6, variables: !2) +!15 = distinct !DISubprogram(name: "f1", linkageName: "_ZN3foo2f1Ev", scope: !"_ZTS3foo", file: !1, line: 2, type: !7, isLocal: false, isDefinition: true, scopeLine: 2, flags: DIFlagPrototyped, isOptimized: false, declaration: !6, variables: !2) !16 = !{i32 2, !"Dwarf Version", i32 4} !17 = !{i32 2, !"Debug Info Version", i32 3} !18 = !{!"clang version 3.8.0 (trunk 249440) (llvm/trunk 249465)"} diff --git a/test/DebugInfo/Generic/dwarf-public-names.ll b/test/DebugInfo/Generic/dwarf-public-names.ll index c14412d3d81..b98a8e7415c 100644 --- a/test/DebugInfo/Generic/dwarf-public-names.ll +++ b/test/DebugInfo/Generic/dwarf-public-names.ll @@ -55,7 +55,7 @@ @global_variable = global %struct.C zeroinitializer, align 1 @_ZN2ns25global_namespace_variableE = global i32 1, align 4 -define void @_ZN1C15member_functionEv(%struct.C* %this) nounwind uwtable align 2 { +define void @_ZN1C15member_functionEv(%struct.C* %this) nounwind uwtable align 2 !dbg !3 { entry: %this.addr = alloca %struct.C*, align 8 store %struct.C* %this, %struct.C** %this.addr, align 8 @@ -67,18 +67,18 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone -define i32 @_ZN1C22static_member_functionEv() nounwind uwtable align 2 { +define i32 @_ZN1C22static_member_functionEv() nounwind uwtable align 2 !dbg !18 { entry: %0 = load i32, i32* @_ZN1C22static_member_variableE, align 4, !dbg !33 ret i32 %0, !dbg !33 } -define i32 @_Z15global_functionv() nounwind uwtable { +define i32 @_Z15global_functionv() nounwind uwtable !dbg !19 { entry: ret i32 -1, !dbg !34 } -define void @_ZN2ns25global_namespace_functionEv() nounwind uwtable { +define void @_ZN2ns25global_namespace_functionEv() nounwind uwtable !dbg !20 { entry: call void @_ZN1C15member_functionEv(%struct.C* @global_variable), !dbg !35 ret void, !dbg !36 @@ -93,7 +93,7 @@ attributes #1 = { nounwind readnone } !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.3 (http://llvm.org/git/clang.git a09cd8103a6a719cb2628cdf0c91682250a17bd2) (http://llvm.org/git/llvm.git 47d03cec0afca0c01ae42b82916d1d731716cd20)", isOptimized: false, emissionKind: 0, file: !37, enums: !1, retainedTypes: !1, subprograms: !2, globals: !24, imports: !1) !1 = !{} !2 = !{!3, !18, !19, !20} -!3 = distinct !DISubprogram(name: "member_function", linkageName: "_ZN1C15member_functionEv", line: 9, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 9, file: !4, scope: null, type: !5, function: void (%struct.C*)* @_ZN1C15member_functionEv, declaration: !12, variables: !1) +!3 = distinct !DISubprogram(name: "member_function", linkageName: "_ZN1C15member_functionEv", line: 9, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 9, file: !4, scope: null, type: !5, declaration: !12, variables: !1) !4 = !DIFile(filename: "dwarf-public-names.cpp", directory: "/usr2/kparzysz/s.hex/t") !5 = !DISubroutineType(types: !6) !6 = !{null, !7} @@ -108,9 +108,9 @@ attributes #1 = { nounwind readnone } !15 = !DISubroutineType(types: !16) !16 = !{!11} !17 = !{} ; previously: invalid DW_TAG_base_type -!18 = distinct !DISubprogram(name: "static_member_function", linkageName: "_ZN1C22static_member_functionEv", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 13, file: !4, scope: null, type: !15, function: i32 ()* @_ZN1C22static_member_functionEv, declaration: !14, variables: !1) -!19 = distinct !DISubprogram(name: "global_function", linkageName: "_Z15global_functionv", line: 19, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 19, file: !4, scope: !4, type: !15, function: i32 ()* @_Z15global_functionv, variables: !1) -!20 = distinct !DISubprogram(name: "global_namespace_function", linkageName: "_ZN2ns25global_namespace_functionEv", line: 24, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 24, file: !4, scope: !21, type: !22, function: void ()* @_ZN2ns25global_namespace_functionEv, variables: !1) +!18 = distinct !DISubprogram(name: "static_member_function", linkageName: "_ZN1C22static_member_functionEv", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 13, file: !4, scope: null, type: !15, declaration: !14, variables: !1) +!19 = distinct !DISubprogram(name: "global_function", linkageName: "_Z15global_functionv", line: 19, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 19, file: !4, scope: !4, type: !15, variables: !1) +!20 = distinct !DISubprogram(name: "global_namespace_function", linkageName: "_ZN2ns25global_namespace_functionEv", line: 24, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 24, file: !4, scope: !21, type: !22, variables: !1) !21 = !DINamespace(name: "ns", line: 23, file: !4, scope: null) !22 = !DISubroutineType(types: !23) !23 = !{null} diff --git a/test/DebugInfo/Generic/enum-types.ll b/test/DebugInfo/Generic/enum-types.ll index 484f965384e..e71fcbc52bf 100644 --- a/test/DebugInfo/Generic/enum-types.ll +++ b/test/DebugInfo/Generic/enum-types.ll @@ -21,7 +21,7 @@ ; CHECK: DW_AT_type [DW_FORM_ref_addr] {{.*}}[[ENUM]] ; Function Attrs: nounwind ssp uwtable -define void @_Z4topA2EA(i32 %sa) #0 { +define void @_Z4topA2EA(i32 %sa) #0 !dbg !7 { entry: %sa.addr = alloca i32, align 4 store i32 %sa, i32* %sa.addr, align 4 @@ -33,7 +33,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: nounwind ssp uwtable -define void @_Z4topB2EA(i32 %sa) #0 { +define void @_Z4topB2EA(i32 %sa) #0 !dbg !17 { entry: %sa.addr = alloca i32, align 4 store i32 %sa, i32* %sa.addr, align 4 @@ -55,7 +55,7 @@ attributes #1 = { nounwind readnone } !4 = !{!5} !5 = !DIEnumerator(name: "EA_0", value: 0) ; [ DW_TAG_enumerator ] [EA_0 :: 0] !6 = !{!7} -!7 = distinct !DISubprogram(name: "topA", linkageName: "_Z4topA2EA", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !8, type: !9, function: void (i32)* @_Z4topA2EA, variables: !11) +!7 = distinct !DISubprogram(name: "topA", linkageName: "_Z4topA2EA", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !8, type: !9, variables: !11) !8 = !DIFile(filename: "a.cpp", directory: "") !9 = !DISubroutineType(types: !10) !10 = !{null, !"_ZTS2EA"} @@ -65,7 +65,7 @@ attributes #1 = { nounwind readnone } !14 = !{!15} !15 = !DICompositeType(tag: DW_TAG_enumeration_type, name: "EA", line: 1, size: 32, align: 32, file: !13, elements: !4, identifier: "_ZTS2EA") !16 = !{!17} -!17 = distinct !DISubprogram(name: "topB", linkageName: "_Z4topB2EA", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !13, scope: !18, type: !9, function: void (i32)* @_Z4topB2EA, variables: !11) +!17 = distinct !DISubprogram(name: "topB", linkageName: "_Z4topB2EA", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !13, scope: !18, type: !9, variables: !11) !18 = !DIFile(filename: "b.cpp", directory: "") !19 = !{i32 2, !"Dwarf Version", i32 2} !20 = !{i32 2, !"Debug Info Version", i32 3} diff --git a/test/DebugInfo/Generic/enum.ll b/test/DebugInfo/Generic/enum.ll index 8d91c4e3943..6d1bddc2f72 100644 --- a/test/DebugInfo/Generic/enum.ll +++ b/test/DebugInfo/Generic/enum.ll @@ -36,7 +36,7 @@ @a = global i64 0, align 8 ; Function Attrs: nounwind uwtable -define void @_Z4funcv() #0 { +define void @_Z4funcv() #0 !dbg !13 { entry: %b = alloca i32, align 4 call void @llvm.dbg.declare(metadata i32* %b, metadata !20, metadata !DIExpression()), !dbg !22 @@ -66,7 +66,7 @@ attributes #1 = { nounwind readnone } !10 = !DIEnumerator(name: "X", value: 0) ; [ DW_TAG_enumerator ] [X :: 0] !11 = !{} !12 = !{!13} -!13 = distinct !DISubprogram(name: "func", linkageName: "_Z4funcv", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !14, type: !15, function: void ()* @_Z4funcv, variables: !11) +!13 = distinct !DISubprogram(name: "func", linkageName: "_Z4funcv", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !14, type: !15, variables: !11) !14 = !DIFile(filename: "enum.cpp", directory: "/tmp") !15 = !DISubroutineType(types: !16) !16 = !{null} diff --git a/test/DebugInfo/Generic/global.ll b/test/DebugInfo/Generic/global.ll index ed8091a6832..6cac9a2de05 100644 --- a/test/DebugInfo/Generic/global.ll +++ b/test/DebugInfo/Generic/global.ll @@ -16,7 +16,7 @@ ; CHECK: DW_TAG_variable ; Function Attrs: nounwind readnone uwtable -define i32 @main() #0 { +define i32 @main() #0 !dbg !4 { entry: ret i32 0, !dbg !12 } @@ -30,7 +30,7 @@ attributes #0 = { nounwind readnone uwtable "less-precise-fpmad"="false" "no-fra !1 = !DIFile(filename: "global.cpp", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "global.cpp", directory: "/tmp") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/DebugInfo/Generic/gvn.ll b/test/DebugInfo/Generic/gvn.ll index 1b32918dd34..f9fb7ab5520 100644 --- a/test/DebugInfo/Generic/gvn.ll +++ b/test/DebugInfo/Generic/gvn.ll @@ -20,7 +20,7 @@ target triple = "arm64-apple-ios" @b = common global i32 0, align 4 ; Function Attrs: nounwind -define void @f3() #0 { +define void @f3() #0 !dbg !12 { entry: ; Verify that the call still has a debug location after GVN. ; CHECK: %call = tail call i32 @f2(i32 1) #{{[0-9]}}, !dbg @@ -78,7 +78,7 @@ attributes #3 = { nounwind } !9 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !10 = !{!11} !11 = !DILocalVariable(name: "p1", arg: 1, scope: !4, file: !1, line: 2, type: !8) -!12 = distinct !DISubprogram(name: "f3", scope: !1, file: !1, line: 9, type: !13, isLocal: false, isDefinition: true, scopeLine: 9, flags: DIFlagPrototyped, isOptimized: true, function: void ()* @f3, variables: !2) +!12 = distinct !DISubprogram(name: "f3", scope: !1, file: !1, line: 9, type: !13, isLocal: false, isDefinition: true, scopeLine: 9, flags: DIFlagPrototyped, isOptimized: true, variables: !2) !13 = !DISubroutineType(types: !14) !14 = !{null} !15 = !{!16, !17} diff --git a/test/DebugInfo/Generic/incorrect-variable-debugloc.ll b/test/DebugInfo/Generic/incorrect-variable-debugloc.ll index b5787923d1c..cf713ee3b97 100644 --- a/test/DebugInfo/Generic/incorrect-variable-debugloc.ll +++ b/test/DebugInfo/Generic/incorrect-variable-debugloc.ll @@ -58,7 +58,7 @@ @__asan_gen_1 = private unnamed_addr constant [13 x i8] c"1 32 1 3 tmp\00", align 1 ; Function Attrs: noreturn sanitize_address -define i32 @_Z3fn1v() #0 { +define i32 @_Z3fn1v() #0 !dbg !22 { entry: %MyAlloca = alloca [64 x i8], align 32, !dbg !39 %0 = ptrtoint [64 x i8]* %MyAlloca to i64, !dbg !39 @@ -116,7 +116,7 @@ entry: } ; Function Attrs: sanitize_address -define void @_ZN1C5m_fn3Ev(%struct.C* nocapture %this) #1 align 2 { +define void @_ZN1C5m_fn3Ev(%struct.C* nocapture %this) #1 align 2 !dbg !28 { entry: %MyAlloca = alloca [64 x i8], align 32, !dbg !48 %0 = ptrtoint [64 x i8]* %MyAlloca to i64, !dbg !48 @@ -358,13 +358,13 @@ attributes #3 = { nounwind readnone } !19 = !{null, !20} !20 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS1B") !21 = !{!22, !28, !32} -!22 = distinct !DISubprogram(name: "fn1", linkageName: "_Z3fn1v", line: 16, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 16, file: !5, scope: !23, type: !24, function: i32 ()* @_Z3fn1v, variables: !26) +!22 = distinct !DISubprogram(name: "fn1", linkageName: "_Z3fn1v", line: 16, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 16, file: !5, scope: !23, type: !24, variables: !26) !23 = !DIFile(filename: "incorrect-variable-debug-loc.cpp", directory: "/tmp/dbginfo") !24 = !DISubroutineType(types: !25) !25 = !{!8} !26 = !{!27} !27 = !DILocalVariable(name: "A", line: 17, scope: !22, file: !23, type: !"_ZTS1C") -!28 = distinct !DISubprogram(name: "m_fn3", linkageName: "_ZN1C5m_fn3Ev", line: 21, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 21, file: !5, scope: !"_ZTS1C", type: !11, function: void (%struct.C*)* @_ZN1C5m_fn3Ev, declaration: !10, variables: !29) +!28 = distinct !DISubprogram(name: "m_fn3", linkageName: "_ZN1C5m_fn3Ev", line: 21, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 21, file: !5, scope: !"_ZTS1C", type: !11, declaration: !10, variables: !29) !29 = !{!30} !30 = !DILocalVariable(name: "this", arg: 1, flags: DIFlagArtificial | DIFlagObjectPointer, scope: !28, type: !31) !31 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !"_ZTS1C") diff --git a/test/DebugInfo/Generic/incorrect-variable-debugloc1.ll b/test/DebugInfo/Generic/incorrect-variable-debugloc1.ll index 7d40e404ce1..33af0baeb65 100644 --- a/test/DebugInfo/Generic/incorrect-variable-debugloc1.ll +++ b/test/DebugInfo/Generic/incorrect-variable-debugloc1.ll @@ -27,7 +27,7 @@ ; DWARF4: Location description: 10 0d 9f ; Function Attrs: uwtable -define i32 @main() #0 { +define i32 @main() #0 !dbg !4 { entry: %c = alloca i32, align 4 tail call void @llvm.dbg.value(metadata i32 13, i64 0, metadata !10, metadata !16), !dbg !17 @@ -57,7 +57,7 @@ attributes #2 = { nounwind readnone } !1 = !DIFile(filename: "test.cpp", directory: "/home/kromanova/ngh/ToT_latest/llvm/test/DebugInfo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", line: 3, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 4, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !9) +!4 = distinct !DISubprogram(name: "main", line: 3, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 4, file: !1, scope: !5, type: !6, variables: !9) !5 = !DIFile(filename: "test.cpp", directory: "/home/kromanova/ngh/ToT_latest/llvm/test/DebugInfo") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/DebugInfo/Generic/inline-debug-info-multiret.ll b/test/DebugInfo/Generic/inline-debug-info-multiret.ll index e1ed553022c..5be261ac374 100644 --- a/test/DebugInfo/Generic/inline-debug-info-multiret.ll +++ b/test/DebugInfo/Generic/inline-debug-info-multiret.ll @@ -21,7 +21,7 @@ target triple = "x86_64-apple-darwin12.0.0" @global_var = external global i32 ; copy of above function with multiple returns -define i32 @_Z4testi(i32 %k) { +define i32 @_Z4testi(i32 %k) !dbg !4 { entry: %retval = alloca i32, align 4 %k.addr = alloca i32, align 4 @@ -57,7 +57,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 declare i32 @_Z8test_exti(i32) -define i32 @_Z5test2v() personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) { +define i32 @_Z5test2v() personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) !dbg !10 { entry: %exn.slot = alloca i8* %ehselector.slot = alloca i32 @@ -126,13 +126,13 @@ attributes #2 = { nounwind } !1 = !DIFile(filename: "<unknown>", directory: "") !2 = !{} !3 = !{!4, !10} -!4 = distinct !DISubprogram(name: "test", linkageName: "_Z4testi", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !5, scope: !6, type: !7, function: i32 (i32)* @_Z4testi, variables: !2) +!4 = distinct !DISubprogram(name: "test", linkageName: "_Z4testi", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !5, scope: !6, type: !7, variables: !2) !5 = !DIFile(filename: "test.cpp", directory: "") !6 = !DIFile(filename: "test.cpp", directory: "") !7 = !DISubroutineType(types: !8) !8 = !{!9, !9} !9 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!10 = distinct !DISubprogram(name: "test2", linkageName: "_Z5test2v", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 11, file: !5, scope: !6, type: !11, function: i32 ()* @_Z5test2v, variables: !2) +!10 = distinct !DISubprogram(name: "test2", linkageName: "_Z5test2v", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 11, file: !5, scope: !6, type: !11, variables: !2) !11 = !DISubroutineType(types: !12) !12 = !{!9} !13 = !DILocalVariable(name: "k", line: 4, arg: 1, scope: !4, file: !6, type: !9) diff --git a/test/DebugInfo/Generic/inline-debug-info.ll b/test/DebugInfo/Generic/inline-debug-info.ll index baadc39a9f7..a5d55a4f98a 100644 --- a/test/DebugInfo/Generic/inline-debug-info.ll +++ b/test/DebugInfo/Generic/inline-debug-info.ll @@ -41,7 +41,7 @@ target triple = "x86_64-apple-darwin12.0.0" @_ZTIi = external constant i8* @global_var = external global i32 -define i32 @_Z4testi(i32 %k) { +define i32 @_Z4testi(i32 %k) !dbg !4 { entry: %retval = alloca i32, align 4 %k.addr = alloca i32, align 4 @@ -75,7 +75,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 declare i32 @_Z8test_exti(i32) -define i32 @_Z5test2v() personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) { +define i32 @_Z5test2v() personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) !dbg !10 { entry: %exn.slot = alloca i8* %ehselector.slot = alloca i32 @@ -144,13 +144,13 @@ attributes #2 = { nounwind } !1 = !DIFile(filename: "<unknown>", directory: "") !2 = !{} !3 = !{!4, !10} -!4 = distinct !DISubprogram(name: "test", linkageName: "_Z4testi", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !5, scope: !6, type: !7, function: i32 (i32)* @_Z4testi, variables: !2) +!4 = distinct !DISubprogram(name: "test", linkageName: "_Z4testi", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !5, scope: !6, type: !7, variables: !2) !5 = !DIFile(filename: "test.cpp", directory: "") !6 = !DIFile(filename: "test.cpp", directory: "") !7 = !DISubroutineType(types: !8) !8 = !{!9, !9} !9 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!10 = distinct !DISubprogram(name: "test2", linkageName: "_Z5test2v", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 11, file: !5, scope: !6, type: !11, function: i32 ()* @_Z5test2v, variables: !2) +!10 = distinct !DISubprogram(name: "test2", linkageName: "_Z5test2v", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 11, file: !5, scope: !6, type: !11, variables: !2) !11 = !DISubroutineType(types: !12) !12 = !{!9} !13 = !DILocalVariable(name: "k", line: 4, arg: 1, scope: !4, file: !6, type: !9) diff --git a/test/DebugInfo/Generic/inline-no-debug-info.ll b/test/DebugInfo/Generic/inline-no-debug-info.ll index a46146761a2..443ba9da6b5 100644 --- a/test/DebugInfo/Generic/inline-no-debug-info.ll +++ b/test/DebugInfo/Generic/inline-no-debug-info.ll @@ -43,7 +43,7 @@ entry: } ; Function Attrs: nounwind uwtable -define void @caller() #0 { +define void @caller() #0 !dbg !4 { entry: tail call void @callee(), !dbg !12 ret void, !dbg !12 @@ -59,7 +59,7 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe !1 = !DIFile(filename: "test.c", directory: "/code/llvm/build0") !2 = !{} !3 = !{!4, !7} -!4 = distinct !DISubprogram(name: "caller", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 4, file: !1, scope: !5, type: !6, function: void ()* @caller, variables: !2) +!4 = distinct !DISubprogram(name: "caller", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 4, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "test.c", directory: "/code/llvm/build0") !6 = !DISubroutineType(types: !2) !7 = distinct !DISubprogram(name: "callee2", line: 2, isLocal: true, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) diff --git a/test/DebugInfo/Generic/inline-scopes.ll b/test/DebugInfo/Generic/inline-scopes.ll index 266d03e93e0..432c58b79e1 100644 --- a/test/DebugInfo/Generic/inline-scopes.ll +++ b/test/DebugInfo/Generic/inline-scopes.ll @@ -37,7 +37,7 @@ ; CHECK: DW_AT_abstract_origin ; Function Attrs: uwtable -define i32 @main() #0 { +define i32 @main() #0 !dbg !4 { entry: %retval.i2 = alloca i32, align 4 %b.i3 = alloca i8, align 1 @@ -99,7 +99,7 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !1 = !DIFile(filename: "inline-scopes.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4, !10, !12} -!4 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !5, scope: !6, type: !7, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !5, scope: !6, type: !7, variables: !2) !5 = !DIFile(filename: "y.cc", directory: "/tmp/dbginfo") !6 = !DIFile(filename: "y.cc", directory: "/tmp/dbginfo") !7 = !DISubroutineType(types: !8) diff --git a/test/DebugInfo/Generic/inlined-arguments.ll b/test/DebugInfo/Generic/inlined-arguments.ll index 69825faa8b9..af4820845a0 100644 --- a/test/DebugInfo/Generic/inlined-arguments.ll +++ b/test/DebugInfo/Generic/inlined-arguments.ll @@ -23,7 +23,7 @@ ; CHECK: DW_AT_name{{.*}}"y" ; Function Attrs: uwtable -define void @_Z2f2v() #0 { +define void @_Z2f2v() #0 !dbg !4 { tail call void @llvm.dbg.value(metadata i32 undef, i64 0, metadata !16, metadata !DIExpression()), !dbg !18 tail call void @llvm.dbg.value(metadata i32 2, i64 0, metadata !20, metadata !DIExpression()), !dbg !18 tail call void @_Z2f3i(i32 2), !dbg !21 @@ -31,7 +31,7 @@ define void @_Z2f2v() #0 { } ; Function Attrs: uwtable -define void @_Z2f1ii(i32 %x, i32 %y) #0 { +define void @_Z2f1ii(i32 %x, i32 %y) #0 !dbg !8 { tail call void @llvm.dbg.value(metadata i32 %x, i64 0, metadata !13, metadata !DIExpression()), !dbg !23 tail call void @llvm.dbg.value(metadata i32 %y, i64 0, metadata !14, metadata !DIExpression()), !dbg !23 tail call void @_Z2f3i(i32 %y), !dbg !24 @@ -54,11 +54,11 @@ attributes #2 = { nounwind readnone } !1 = !DIFile(filename: "exp.cpp", directory: "/usr/local/google/home/blaikie/dev/scratch") !2 = !{} !3 = !{!4, !8} -!4 = distinct !DISubprogram(name: "f2", linkageName: "_Z2f2v", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !5, type: !6, function: void ()* @_Z2f2v, variables: !2) +!4 = distinct !DISubprogram(name: "f2", linkageName: "_Z2f2v", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "exp.cpp", directory: "/usr/local/google/home/blaikie/dev/scratch") !6 = !DISubroutineType(types: !7) !7 = !{null} -!8 = distinct !DISubprogram(name: "f1", linkageName: "_Z2f1ii", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 6, file: !1, scope: !5, type: !9, function: void (i32, i32)* @_Z2f1ii, variables: !12) +!8 = distinct !DISubprogram(name: "f1", linkageName: "_Z2f1ii", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 6, file: !1, scope: !5, type: !9, variables: !12) !9 = !DISubroutineType(types: !10) !10 = !{null, !11, !11} !11 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/DebugInfo/Generic/inlined-vars.ll b/test/DebugInfo/Generic/inlined-vars.ll index 05e7f7d2beb..a294380bb5c 100644 --- a/test/DebugInfo/Generic/inlined-vars.ll +++ b/test/DebugInfo/Generic/inlined-vars.ll @@ -2,7 +2,7 @@ ; RUN: %llc_dwarf -O0 < %s | FileCheck %s -check-prefix VARIABLE ; PR 13202 -define i32 @main() uwtable { +define i32 @main() uwtable !dbg !5 { entry: tail call void @llvm.dbg.value(metadata i32 0, i64 0, metadata !18, metadata !DIExpression()), !dbg !21 tail call void @llvm.dbg.value(metadata i32 0, i64 0, metadata !22, metadata !DIExpression()), !dbg !23 @@ -22,7 +22,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !1 = !{i32 0} !2 = !{} !3 = !{!5, !10} -!5 = distinct !DISubprogram(name: "main", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 10, file: !26, scope: !6, type: !7, function: i32 ()* @main, variables: !2) +!5 = distinct !DISubprogram(name: "main", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 10, file: !26, scope: !6, type: !7, variables: !2) !6 = !DIFile(filename: "inline-bug.cc", directory: "/tmp/dbginfo/pr13202") !7 = !DISubroutineType(types: !8) !8 = !{!9} diff --git a/test/DebugInfo/Generic/location-verifier.ll b/test/DebugInfo/Generic/location-verifier.ll index a767ab903c3..aa725a2369a 100644 --- a/test/DebugInfo/Generic/location-verifier.ll +++ b/test/DebugInfo/Generic/location-verifier.ll @@ -4,7 +4,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-apple-macosx10.10.0" ; Function Attrs: nounwind ssp uwtable -define i32 @foo() #0 { +define i32 @foo() #0 !dbg !4 { entry: ret i32 42, !dbg !13 } @@ -19,7 +19,7 @@ attributes #0 = { nounwind ssp uwtable } !1 = !DIFile(filename: "test.c", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 ()* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "test.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/DebugInfo/Generic/lto-comp-dir.ll b/test/DebugInfo/Generic/lto-comp-dir.ll index f20383d5636..8d5da504a82 100644 --- a/test/DebugInfo/Generic/lto-comp-dir.ll +++ b/test/DebugInfo/Generic/lto-comp-dir.ll @@ -40,13 +40,13 @@ ; } ; Function Attrs: nounwind uwtable -define void @_Z4funcv() #0 { +define void @_Z4funcv() #0 !dbg !4 { entry: ret void, !dbg !19 } ; Function Attrs: uwtable -define i32 @main() #1 { +define i32 @main() #1 !dbg !11 { entry: call void @_Z4funcv(), !dbg !20 ret i32 0, !dbg !21 @@ -63,14 +63,14 @@ attributes #1 = { uwtable "less-precise-fpmad"="false" "no-frame-pointer-elim"=" !1 = !DIFile(filename: "a.cpp", directory: "/tmp/dbginfo/a") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "func", linkageName: "_Z4funcv", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: void ()* @_Z4funcv, variables: !2) +!4 = distinct !DISubprogram(name: "func", linkageName: "_Z4funcv", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "a.cpp", directory: "/tmp/dbginfo/a") !6 = !DISubroutineType(types: !7) !7 = !{null} !8 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.5.0 ", isOptimized: false, emissionKind: 1, file: !9, enums: !2, retainedTypes: !2, subprograms: !10, globals: !2, imports: !2) !9 = !DIFile(filename: "b.cpp", directory: "/tmp/dbginfo/b") !10 = !{!11} -!11 = distinct !DISubprogram(name: "main", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !9, scope: !12, type: !13, function: i32 ()* @main, variables: !2) +!11 = distinct !DISubprogram(name: "main", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !9, scope: !12, type: !13, variables: !2) !12 = !DIFile(filename: "b.cpp", directory: "/tmp/dbginfo/b") !13 = !DISubroutineType(types: !14) !14 = !{!15} diff --git a/test/DebugInfo/Generic/member-order.ll b/test/DebugInfo/Generic/member-order.ll index 4c1f6b6c0ba..55ada4f829b 100644 --- a/test/DebugInfo/Generic/member-order.ll +++ b/test/DebugInfo/Generic/member-order.ll @@ -25,7 +25,7 @@ %struct.foo = type { i8 } ; Function Attrs: nounwind uwtable -define void @_ZN3foo2f1Ev(%struct.foo* %this) #0 align 2 { +define void @_ZN3foo2f1Ev(%struct.foo* %this) #0 align 2 !dbg !14 { entry: %this.addr = alloca %struct.foo*, align 8 store %struct.foo* %this, %struct.foo** %this.addr, align 8 @@ -57,7 +57,7 @@ attributes #1 = { nounwind readnone } !11 = !DISubprogram(name: "f2", linkageName: "_ZN3foo2f2Ev", line: 3, isLocal: false, isDefinition: false, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !4, type: !7) !12 = !{i32 786468} !13 = !{!14} -!14 = distinct !DISubprogram(name: "f1", linkageName: "_ZN3foo2f1Ev", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: null, type: !7, function: void (%struct.foo*)* @_ZN3foo2f1Ev, declaration: !6, variables: !2) +!14 = distinct !DISubprogram(name: "f1", linkageName: "_ZN3foo2f1Ev", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: null, type: !7, declaration: !6, variables: !2) !15 = !{i32 2, !"Dwarf Version", i32 4} !16 = !DILocalVariable(name: "this", arg: 1, flags: DIFlagArtificial | DIFlagObjectPointer, scope: !14, type: !17) !17 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !"_ZTS3foo") diff --git a/test/DebugInfo/Generic/missing-abstract-variable.ll b/test/DebugInfo/Generic/missing-abstract-variable.ll index 0ebb5a28edc..ee4f1666d2b 100644 --- a/test/DebugInfo/Generic/missing-abstract-variable.ll +++ b/test/DebugInfo/Generic/missing-abstract-variable.ll @@ -97,7 +97,7 @@ @t = external global i32 ; Function Attrs: uwtable -define void @_Z1bv() #0 { +define void @_Z1bv() #0 !dbg !4 { entry: tail call void @llvm.dbg.value(metadata i1 false, i64 0, metadata !25, metadata !DIExpression()), !dbg !27 tail call void @_Z1fi(i32 0), !dbg !28 @@ -105,7 +105,7 @@ entry: } ; Function Attrs: uwtable -define void @_Z1ab(i1 zeroext %u) #0 { +define void @_Z1ab(i1 zeroext %u) #0 !dbg !8 { entry: tail call void @llvm.dbg.value(metadata i1 %u, i64 0, metadata !13, metadata !DIExpression()), !dbg !30 tail call void @llvm.dbg.value(metadata i1 %u, i64 0, metadata !31, metadata !DIExpression()), !dbg !33 @@ -139,11 +139,11 @@ attributes #2 = { nounwind readnone } !1 = !DIFile(filename: "missing-abstract-variables.cc", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4, !8, !14} -!4 = distinct !DISubprogram(name: "b", linkageName: "_Z1bv", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 13, file: !1, scope: !5, type: !6, function: void ()* @_Z1bv, variables: !2) +!4 = distinct !DISubprogram(name: "b", linkageName: "_Z1bv", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 13, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "missing-abstract-variables.cc", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !7) !7 = !{null} -!8 = distinct !DISubprogram(name: "a", linkageName: "_Z1ab", line: 17, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 17, file: !1, scope: !5, type: !9, function: void (i1)* @_Z1ab, variables: !12) +!8 = distinct !DISubprogram(name: "a", linkageName: "_Z1ab", line: 17, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 17, file: !1, scope: !5, type: !9, variables: !12) !9 = !DISubroutineType(types: !10) !10 = !{null, !11} !11 = !DIBasicType(tag: DW_TAG_base_type, name: "bool", size: 8, align: 8, encoding: DW_ATE_boolean) diff --git a/test/DebugInfo/Generic/multiline.ll b/test/DebugInfo/Generic/multiline.ll index aaad0326477..7740bb6918a 100644 --- a/test/DebugInfo/Generic/multiline.ll +++ b/test/DebugInfo/Generic/multiline.ll @@ -42,7 +42,7 @@ ; Function Attrs: nounwind uwtable -define void @f2() #0 { +define void @f2() #0 !dbg !4 { entry: call void (...) @f1(), !dbg !11 call void (...) @f1(), !dbg !12 @@ -66,7 +66,7 @@ attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !1 = !DIFile(filename: "multiline.c", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f2", line: 2, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, function: void ()* @f2, variables: !2) +!4 = distinct !DISubprogram(name: "f2", line: 2, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "multiline.c", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !7) !7 = !{null} diff --git a/test/DebugInfo/Generic/namespace.ll b/test/DebugInfo/Generic/namespace.ll index 5554c9ff48e..e446806249f 100644 --- a/test/DebugInfo/Generic/namespace.ll +++ b/test/DebugInfo/Generic/namespace.ll @@ -205,13 +205,13 @@ @llvm.global_ctors = appending global [1 x { i32, void ()*, i8* }] [{ i32, void ()*, i8* } { i32 65535, void ()* @_GLOBAL__sub_I_debug_info_namespace.cpp, i8* null }] ; Function Attrs: nounwind ssp uwtable -define i32 @_ZN1A1B2f1Ev() #0 { +define i32 @_ZN1A1B2f1Ev() #0 !dbg !10 { entry: ret i32 0, !dbg !60 } ; Function Attrs: nounwind ssp uwtable -define void @_ZN1A1B2f1Ei(i32) #0 { +define void @_ZN1A1B2f1Ei(i32) #0 !dbg !14 { entry: %.addr = alloca i32, align 4 store i32 %0, i32* %.addr, align 4 @@ -222,7 +222,7 @@ entry: ; Function Attrs: nounwind readnone declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 -define internal void @__cxx_global_var_init() section "__TEXT,__StaticInit,regular,pure_instructions" { +define internal void @__cxx_global_var_init() section "__TEXT,__StaticInit,regular,pure_instructions" !dbg !17 { entry: %call = call i32 @_ZN1A1B2f1Ev(), !dbg !65 store i32 %call, i32* @_ZN1A1B1iE, align 4, !dbg !65 @@ -230,7 +230,7 @@ entry: } ; Function Attrs: nounwind ssp uwtable -define i32 @_Z4funcb(i1 zeroext %b) #0 { +define i32 @_Z4funcb(i1 zeroext %b) #0 !dbg !21 { entry: %retval = alloca i32, align 4 %b.addr = alloca i8, align 1 @@ -260,7 +260,7 @@ return: ; preds = %if.end, %if.then ret i32 %5, !dbg !71 } -define internal void @__cxx_global_var_init1() section "__TEXT,__StaticInit,regular,pure_instructions" { +define internal void @__cxx_global_var_init1() section "__TEXT,__StaticInit,regular,pure_instructions" !dbg !25 { entry: %0 = load i32, i32* @_ZN1A1B1iE, align 4, !dbg !72 store i32 %0, i32* @_ZN1A1B7var_fwdE, align 4, !dbg !72 @@ -268,7 +268,7 @@ entry: } ; Function Attrs: nounwind ssp uwtable -define void @_ZN1A1B8func_fwdEv() #0 { +define void @_ZN1A1B8func_fwdEv() #0 !dbg !26 { entry: ret void, !dbg !73 } @@ -297,24 +297,24 @@ attributes #1 = { nounwind readnone } !7 = !DINamespace(name: "A", line: 5, file: !1, scope: null) !8 = !DICompositeType(tag: DW_TAG_structure_type, name: "bar", line: 6, size: 8, align: 8, file: !5, scope: !6, elements: !2, identifier: "_ZTSN1A1B3barE") !9 = !{!10, !14, !17, !21, !25, !26, !27} -!10 = distinct !DISubprogram(name: "f1", linkageName: "_ZN1A1B2f1Ev", line: 3, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !5, scope: !6, type: !11, function: i32 ()* @_ZN1A1B2f1Ev, variables: !2) +!10 = distinct !DISubprogram(name: "f1", linkageName: "_ZN1A1B2f1Ev", line: 3, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !5, scope: !6, type: !11, variables: !2) !11 = !DISubroutineType(types: !12) !12 = !{!13} !13 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!14 = distinct !DISubprogram(name: "f1", linkageName: "_ZN1A1B2f1Ei", line: 4, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !5, scope: !6, type: !15, function: void (i32)* @_ZN1A1B2f1Ei, variables: !2) +!14 = distinct !DISubprogram(name: "f1", linkageName: "_ZN1A1B2f1Ei", line: 4, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !5, scope: !6, type: !15, variables: !2) !15 = !DISubroutineType(types: !16) !16 = !{null, !13} -!17 = distinct !DISubprogram(name: "__cxx_global_var_init", line: 20, isLocal: true, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 20, file: !5, scope: !18, type: !19, function: void ()* @__cxx_global_var_init, variables: !2) +!17 = distinct !DISubprogram(name: "__cxx_global_var_init", line: 20, isLocal: true, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 20, file: !5, scope: !18, type: !19, variables: !2) !18 = !DIFile(filename: "foo.cpp", directory: "/tmp") !19 = !DISubroutineType(types: !20) !20 = !{null} -!21 = distinct !DISubprogram(name: "func", linkageName: "_Z4funcb", line: 21, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 21, file: !5, scope: !18, type: !22, function: i32 (i1)* @_Z4funcb, variables: !2) +!21 = distinct !DISubprogram(name: "func", linkageName: "_Z4funcb", line: 21, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 21, file: !5, scope: !18, type: !22, variables: !2) !22 = !DISubroutineType(types: !23) !23 = !{!13, !24} !24 = !DIBasicType(tag: DW_TAG_base_type, name: "bool", size: 8, align: 8, encoding: DW_ATE_boolean) -!25 = distinct !DISubprogram(name: "__cxx_global_var_init1", line: 44, isLocal: true, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 44, file: !5, scope: !18, type: !19, function: void ()* @__cxx_global_var_init1, variables: !2) -!26 = distinct !DISubprogram(name: "func_fwd", linkageName: "_ZN1A1B8func_fwdEv", line: 47, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 47, file: !5, scope: !6, type: !19, function: void ()* @_ZN1A1B8func_fwdEv, variables: !2) -!27 = distinct !DISubprogram(name: "", linkageName: "_GLOBAL__sub_I_debug_info_namespace.cpp", isLocal: true, isDefinition: true, flags: DIFlagArtificial, isOptimized: false, file: !1, scope: !28, type: !29, function: void ()* @_GLOBAL__sub_I_debug_info_namespace.cpp, variables: !2) +!25 = distinct !DISubprogram(name: "__cxx_global_var_init1", line: 44, isLocal: true, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 44, file: !5, scope: !18, type: !19, variables: !2) +!26 = distinct !DISubprogram(name: "func_fwd", linkageName: "_ZN1A1B8func_fwdEv", line: 47, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 47, file: !5, scope: !6, type: !19, variables: !2) +!27 = distinct !DISubprogram(name: "", linkageName: "_GLOBAL__sub_I_debug_info_namespace.cpp", isLocal: true, isDefinition: true, flags: DIFlagArtificial, isOptimized: false, file: !1, scope: !28, type: !29, variables: !2) !28 = !DIFile(filename: "debug-info-namespace.cpp", directory: "/tmp") !29 = !DISubroutineType(types: !2) !30 = !{!31, !32} diff --git a/test/DebugInfo/Generic/namespace_function_definition.ll b/test/DebugInfo/Generic/namespace_function_definition.ll index f7a34c1827d..58a144fb118 100644 --- a/test/DebugInfo/Generic/namespace_function_definition.ll +++ b/test/DebugInfo/Generic/namespace_function_definition.ll @@ -19,7 +19,7 @@ ; CHECK: NULL ; Function Attrs: nounwind uwtable -define void @_ZN2ns4funcEv() #0 { +define void @_ZN2ns4funcEv() #0 !dbg !4 { entry: ret void, !dbg !11 } @@ -34,7 +34,7 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe !1 = !DIFile(filename: "namespace_function_definition.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "func", linkageName: "_ZN2ns4funcEv", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, function: void ()* @_ZN2ns4funcEv, variables: !2) +!4 = distinct !DISubprogram(name: "func", linkageName: "_ZN2ns4funcEv", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) !5 = !DINamespace(name: "ns", line: 1, file: !1, scope: null) !6 = !DISubroutineType(types: !7) !7 = !{null} diff --git a/test/DebugInfo/Generic/namespace_inline_function_definition.ll b/test/DebugInfo/Generic/namespace_inline_function_definition.ll index bc606198ce9..cca5e19db44 100644 --- a/test/DebugInfo/Generic/namespace_inline_function_definition.ll +++ b/test/DebugInfo/Generic/namespace_inline_function_definition.ll @@ -35,7 +35,7 @@ @x = external global i32 ; Function Attrs: uwtable -define i32 @main() #0 { +define i32 @main() #0 !dbg !4 { entry: %i.addr.i = alloca i32, align 4 %retval = alloca i32, align 4 @@ -49,7 +49,7 @@ entry: } ; Function Attrs: alwaysinline nounwind uwtable -define i32 @_ZN2ns4funcEi(i32 %i) #1 { +define i32 @_ZN2ns4funcEi(i32 %i) #1 !dbg !9 { entry: %i.addr = alloca i32, align 4 store i32 %i, i32* %i.addr, align 4 @@ -74,12 +74,12 @@ attributes #2 = { nounwind readnone } !1 = !DIFile(filename: "namespace_inline_function_definition.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4, !9} -!4 = distinct !DISubprogram(name: "main", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "namespace_inline_function_definition.cpp", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !7) !7 = !{!8} !8 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!9 = distinct !DISubprogram(name: "func", linkageName: "_ZN2ns4funcEi", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: !10, type: !11, function: i32 (i32)* @_ZN2ns4funcEi, variables: !2) +!9 = distinct !DISubprogram(name: "func", linkageName: "_ZN2ns4funcEi", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: !10, type: !11, variables: !2) !10 = !DINamespace(name: "ns", line: 1, file: !1, scope: null) !11 = !DISubroutineType(types: !12) !12 = !{!8, !8} diff --git a/test/DebugInfo/Generic/piece-verifier.ll b/test/DebugInfo/Generic/piece-verifier.ll index 20d8e897e66..e1f5c24a21d 100644 --- a/test/DebugInfo/Generic/piece-verifier.ll +++ b/test/DebugInfo/Generic/piece-verifier.ll @@ -3,7 +3,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-apple-macosx10.9.0" ; Function Attrs: nounwind ssp uwtable -define i32 @foo(i64 %s.coerce0, i32 %s.coerce1) #0 { +define i32 @foo(i64 %s.coerce0, i32 %s.coerce1) #0 !dbg !4 { entry: call void @llvm.dbg.value(metadata i64 %s.coerce0, i64 0, metadata !20, metadata !24), !dbg !21 call void @llvm.dbg.value(metadata i32 %s.coerce1, i64 0, metadata !22, metadata !27), !dbg !21 @@ -27,7 +27,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "pieces.c", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !5, type: !6, function: i32 (i64, i32)* @foo, variables: !15) +!4 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !15) !5 = !DIFile(filename: "pieces.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8, !9} diff --git a/test/DebugInfo/Generic/recursive_inlining.ll b/test/DebugInfo/Generic/recursive_inlining.ll index c1fc70b689b..02c147e7aa6 100644 --- a/test/DebugInfo/Generic/recursive_inlining.ll +++ b/test/DebugInfo/Generic/recursive_inlining.ll @@ -91,7 +91,7 @@ @x = global %struct.C* null, align 8 ; Function Attrs: nounwind -define void @_Z3fn6v() #0 { +define void @_Z3fn6v() #0 !dbg !14 { entry: tail call void @_Z3fn8v() #3, !dbg !31 %0 = load %struct.C*, %struct.C** @x, align 8, !dbg !32, !tbaa !33 @@ -114,7 +114,7 @@ _ZN1C5m_fn2Ev.exit: ; preds = %entry, %if.then.i declare void @_Z3fn8v() #1 ; Function Attrs: nounwind -define linkonce_odr void @_ZN1C5m_fn2Ev(%struct.C* nocapture readonly %this) #0 align 2 { +define linkonce_odr void @_ZN1C5m_fn2Ev(%struct.C* nocapture readonly %this) #0 align 2 !dbg !22 { entry: tail call void @llvm.dbg.value(metadata %struct.C* %this, i64 0, metadata !24, metadata !DIExpression()), !dbg !49 tail call void @_Z3fn8v() #3, !dbg !50 @@ -147,7 +147,7 @@ _Z3fn6v.exit: ; preds = %if.end, %if.then.i. } ; Function Attrs: nounwind -define void @_Z3fn3v() #0 { +define void @_Z3fn3v() #0 !dbg !18 { entry: br label %tailrecurse @@ -170,7 +170,7 @@ if.then.i.i: ; preds = %tailrecurse } ; Function Attrs: nounwind -define void @_Z3fn4v() #0 { +define void @_Z3fn4v() #0 !dbg !19 { entry: %0 = load %struct.C*, %struct.C** @x, align 8, !dbg !72, !tbaa !33 tail call void @_ZN1C5m_fn2Ev(%struct.C* %0), !dbg !72 @@ -178,7 +178,7 @@ entry: } ; Function Attrs: nounwind -define void @_Z3fn5v() #0 { +define void @_Z3fn5v() #0 !dbg !20 { entry: %0 = load %struct.C*, %struct.C** @x, align 8, !dbg !73, !tbaa !33 tail call void @_ZN1C5m_fn2Ev(%struct.C* %0), !dbg !73 @@ -213,15 +213,15 @@ attributes #3 = { nounwind } !11 = !{null, !12} !12 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS1C") !13 = !{!14, !18, !19, !20, !21, !22} -!14 = distinct !DISubprogram(name: "fn6", linkageName: "_Z3fn6v", line: 15, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 15, file: !5, scope: !15, type: !16, function: void ()* @_Z3fn6v, variables: !2) +!14 = distinct !DISubprogram(name: "fn6", linkageName: "_Z3fn6v", line: 15, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 15, file: !5, scope: !15, type: !16, variables: !2) !15 = !DIFile(filename: "recursive_inlining.cpp", directory: "/usr/local/google/home/blaikie/dev/scratch/missing_concrete_variable_on_darwin/reduce") !16 = !DISubroutineType(types: !17) !17 = !{null} -!18 = distinct !DISubprogram(name: "fn3", linkageName: "_Z3fn3v", line: 20, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 20, file: !5, scope: !15, type: !16, function: void ()* @_Z3fn3v, variables: !2) -!19 = distinct !DISubprogram(name: "fn4", linkageName: "_Z3fn4v", line: 21, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 21, file: !5, scope: !15, type: !16, function: void ()* @_Z3fn4v, variables: !2) -!20 = distinct !DISubprogram(name: "fn5", linkageName: "_Z3fn5v", line: 22, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 22, file: !5, scope: !15, type: !16, function: void ()* @_Z3fn5v, variables: !2) +!18 = distinct !DISubprogram(name: "fn3", linkageName: "_Z3fn3v", line: 20, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 20, file: !5, scope: !15, type: !16, variables: !2) +!19 = distinct !DISubprogram(name: "fn4", linkageName: "_Z3fn4v", line: 21, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 21, file: !5, scope: !15, type: !16, variables: !2) +!20 = distinct !DISubprogram(name: "fn5", linkageName: "_Z3fn5v", line: 22, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 22, file: !5, scope: !15, type: !16, variables: !2) !21 = distinct !DISubprogram(name: "fn7", linkageName: "_Z3fn7v", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 14, file: !5, scope: !15, type: !16, variables: !2) -!22 = distinct !DISubprogram(name: "m_fn2", linkageName: "_ZN1C5m_fn2Ev", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 7, file: !5, scope: !"_ZTS1C", type: !10, function: void (%struct.C*)* @_ZN1C5m_fn2Ev, declaration: !9, variables: !23) +!22 = distinct !DISubprogram(name: "m_fn2", linkageName: "_ZN1C5m_fn2Ev", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 7, file: !5, scope: !"_ZTS1C", type: !10, declaration: !9, variables: !23) !23 = !{!24} !24 = !DILocalVariable(name: "this", arg: 1, flags: DIFlagArtificial | DIFlagObjectPointer, scope: !22, type: !25) !25 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !"_ZTS1C") diff --git a/test/DebugInfo/Generic/restrict.ll b/test/DebugInfo/Generic/restrict.ll index 49401712ccd..b0536acd03c 100644 --- a/test/DebugInfo/Generic/restrict.ll +++ b/test/DebugInfo/Generic/restrict.ll @@ -17,7 +17,7 @@ ; Function Attrs: nounwind uwtable -define void @_Z3fooPv(i8* noalias %dst) #0 { +define void @_Z3fooPv(i8* noalias %dst) #0 !dbg !4 { entry: %dst.addr = alloca i8*, align 8 store i8* %dst, i8** %dst.addr, align 8 @@ -39,7 +39,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "restrict.c", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooPv", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: void (i8*)* @_Z3fooPv, variables: !2) +!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooPv", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "restrict.c", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !7) !7 = !{null, !8} diff --git a/test/DebugInfo/Generic/sugared-constants.ll b/test/DebugInfo/Generic/sugared-constants.ll index 7a344736e43..5e32b794afd 100644 --- a/test/DebugInfo/Generic/sugared-constants.ll +++ b/test/DebugInfo/Generic/sugared-constants.ll @@ -22,7 +22,7 @@ ; CHECK: DW_AT_const_value [DW_FORM_udata] (7) ; Function Attrs: uwtable -define i32 @main() #0 { +define i32 @main() #0 !dbg !4 { entry: tail call void @llvm.dbg.value(metadata i32 42, i64 0, metadata !10, metadata !DIExpression()), !dbg !21 tail call void @_Z4funci(i32 42), !dbg !22 @@ -54,7 +54,7 @@ attributes #2 = { nounwind readnone } !1 = !DIFile(filename: "const.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 4, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !9) +!4 = distinct !DISubprogram(name: "main", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 4, file: !1, scope: !5, type: !6, variables: !9) !5 = !DIFile(filename: "const.cpp", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/DebugInfo/Generic/tu-composite.ll b/test/DebugInfo/Generic/tu-composite.ll index 4df4ea8219d..77f99d2f897 100644 --- a/test/DebugInfo/Generic/tu-composite.ll +++ b/test/DebugInfo/Generic/tu-composite.ll @@ -87,7 +87,7 @@ @_ZTI1C = unnamed_addr constant { i8*, i8* } { i8* bitcast (i8** getelementptr inbounds (i8*, i8** @_ZTVN10__cxxabiv117__class_type_infoE, i64 2) to i8*), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @_ZTS1C, i32 0, i32 0) } ; Function Attrs: nounwind ssp uwtable -define void @_ZN1C3fooEv(%struct.C* %this) unnamed_addr #0 align 2 { +define void @_ZN1C3fooEv(%struct.C* %this) unnamed_addr #0 align 2 !dbg !31 { entry: %this.addr = alloca %struct.C*, align 8 store %struct.C* %this, %struct.C** %this.addr, align 8 @@ -100,7 +100,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: nounwind ssp uwtable -define void @_Z4testv() #0 { +define void @_Z4testv() #0 !dbg !32 { entry: %B = alloca %struct.bar, align 1 %A = alloca [3 x %struct.bar], align 1 @@ -153,8 +153,8 @@ attributes #1 = { nounwind readnone } !28 = !{!29} !29 = !DITemplateTypeParameter(name: "T", type: !"_ZTS3bar") !30 = !{!31, !32} -!31 = distinct !DISubprogram(name: "foo", linkageName: "_ZN1C3fooEv", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: null, type: !14, function: void (%struct.C*)* @_ZN1C3fooEv, declaration: !13, variables: !2) -!32 = distinct !DISubprogram(name: "test", linkageName: "_Z4testv", line: 20, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 20, file: !1, scope: !7, type: !33, function: void ()* @_Z4testv, variables: !2) +!31 = distinct !DISubprogram(name: "foo", linkageName: "_ZN1C3fooEv", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: null, type: !14, declaration: !13, variables: !2) +!32 = distinct !DISubprogram(name: "test", linkageName: "_Z4testv", line: 20, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 20, file: !1, scope: !7, type: !33, variables: !2) !33 = !DISubroutineType(types: !34) !34 = !{null} !35 = !{i32 2, !"Dwarf Version", i32 2} diff --git a/test/DebugInfo/Generic/two-cus-from-same-file.ll b/test/DebugInfo/Generic/two-cus-from-same-file.ll index 4aeaaac22d2..65d376c814d 100644 --- a/test/DebugInfo/Generic/two-cus-from-same-file.ll +++ b/test/DebugInfo/Generic/two-cus-from-same-file.ll @@ -13,7 +13,7 @@ @str = private unnamed_addr constant [4 x i8] c"FOO\00" @str1 = private unnamed_addr constant [6 x i8] c"Main!\00" -define void @foo() nounwind { +define void @foo() nounwind !dbg !5 { entry: %puts = tail call i32 @puts(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @str, i32 0, i32 0)), !dbg !23 ret void, !dbg !25 @@ -21,7 +21,7 @@ entry: declare i32 @puts(i8* nocapture) nounwind -define i32 @main(i32 %argc, i8** nocapture %argv) nounwind { +define i32 @main(i32 %argc, i8** nocapture %argv) nounwind !dbg !12 { entry: tail call void @llvm.dbg.value(metadata i32 %argc, i64 0, metadata !21, metadata !DIExpression()), !dbg !26 tail call void @llvm.dbg.value(metadata i8** %argv, i64 0, metadata !22, metadata !DIExpression()), !dbg !27 @@ -38,13 +38,13 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.2 (trunk 156513)", isOptimized: true, emissionKind: 1, file: !32, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "foo", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !32, scope: !6, type: !7, function: void ()* @foo, variables: !1) +!5 = distinct !DISubprogram(name: "foo", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !32, scope: !6, type: !7, variables: !1) !6 = !DIFile(filename: "foo.c", directory: "/tmp") !7 = !DISubroutineType(types: !8) !8 = !{null} !9 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.2 (trunk 156513)", isOptimized: true, emissionKind: 1, file: !32, enums: !1, retainedTypes: !1, subprograms: !10, globals: !1, imports: !1) !10 = !{!12} -!12 = distinct !DISubprogram(name: "main", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 11, file: !32, scope: !6, type: !13, function: i32 (i32, i8**)* @main, variables: !19) +!12 = distinct !DISubprogram(name: "main", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 11, file: !32, scope: !6, type: !13, variables: !19) !13 = !DISubroutineType(types: !14) !14 = !{!15, !15, !16} !15 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/DebugInfo/Generic/unconditional-branch.ll b/test/DebugInfo/Generic/unconditional-branch.ll index d4d7fb82741..9325e1b27ad 100644 --- a/test/DebugInfo/Generic/unconditional-branch.ll +++ b/test/DebugInfo/Generic/unconditional-branch.ll @@ -18,7 +18,7 @@ ;} ; Function Attrs: nounwind -define void @foo(i32 %i) #0 { +define void @foo(i32 %i) #0 !dbg !4 { entry: %i.addr = alloca i32, align 4 store i32 %i, i32* %i.addr, align 4 @@ -49,7 +49,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "test.c", directory: "D:\5Cwork\5CEPRs\5C396363") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: void (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "test.c", directory: "D:CworkCEPRsC396363") !6 = !DISubroutineType(types: !7) !7 = !{null, !8} diff --git a/test/DebugInfo/Generic/varargs.ll b/test/DebugInfo/Generic/varargs.ll index 1b5a921ad53..8567bf71514 100644 --- a/test/DebugInfo/Generic/varargs.ll +++ b/test/DebugInfo/Generic/varargs.ll @@ -50,7 +50,7 @@ %struct.A = type { i8 } ; Function Attrs: nounwind ssp uwtable -define void @_Z1biz(i32 %c, ...) #0 { +define void @_Z1biz(i32 %c, ...) #0 !dbg !14 { %1 = alloca i32, align 4 %a = alloca %struct.A, align 1 %fptr = alloca void (i32, ...)*, align 8 @@ -84,7 +84,7 @@ attributes #1 = { nounwind readnone } !9 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS1A") !10 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !13 = !{!14} -!14 = distinct !DISubprogram(name: "b", linkageName: "_Z1biz", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 13, file: !1, scope: !15, type: !16, function: void (i32, ...)* @_Z1biz, variables: !2) +!14 = distinct !DISubprogram(name: "b", linkageName: "_Z1biz", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 13, file: !1, scope: !15, type: !16, variables: !2) !15 = !DIFile(filename: "llvm/tools/clang/test/CodeGenCXX/debug-info-varargs.cpp", directory: "radar/13690847") !16 = !DISubroutineType(types: !17) !17 = !{null, !10, null} diff --git a/test/DebugInfo/Generic/version.ll b/test/DebugInfo/Generic/version.ll index d0caa295cc2..936e0887223 100644 --- a/test/DebugInfo/Generic/version.ll +++ b/test/DebugInfo/Generic/version.ll @@ -6,7 +6,7 @@ ; Make sure we are generating DWARF version 3 when module flag says so. ; CHECK: Compile Unit: length = {{.*}} version = 0x0003 -define i32 @main() #0 { +define i32 @main() #0 !dbg !4 { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval @@ -22,7 +22,7 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe !1 = !DIFile(filename: "CodeGen/dwarf-version.c", directory: "test") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "CodeGen/dwarf-version.c", directory: "test") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/DebugInfo/Inputs/gmlt.ll b/test/DebugInfo/Inputs/gmlt.ll index d73fef3b1de..b03a80b4dea 100644 --- a/test/DebugInfo/Inputs/gmlt.ll +++ b/test/DebugInfo/Inputs/gmlt.ll @@ -98,26 +98,26 @@ ; CHECK: .apple{{.*}} contents: ; Function Attrs: nounwind uwtable -define void @_Z2f1v() #0 { +define void @_Z2f1v() #0 !dbg !4 { entry: ret void, !dbg !13 } ; Function Attrs: nounwind uwtable -define void @_Z2f2v() #0 section "__TEXT,__bar" { +define void @_Z2f2v() #0 section "__TEXT,__bar" !dbg !7 { entry: ret void, !dbg !14 } ; Function Attrs: alwaysinline nounwind uwtable -define void @_Z2f3v() #1 { +define void @_Z2f3v() #1 !dbg !8 { entry: call void @_Z2f1v(), !dbg !15 ret void, !dbg !16 } ; Function Attrs: nounwind uwtable -define void @_Z2f4v() #0 { +define void @_Z2f4v() #0 !dbg !9 { entry: call void @_Z2f1v() #2, !dbg !17 ret void, !dbg !19 @@ -135,12 +135,12 @@ attributes #2 = { nounwind } !1 = !DIFile(filename: "gmlt.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4, !7, !8, !9} -!4 = distinct !DISubprogram(name: "f1", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: void ()* @_Z2f1v, variables: !2) +!4 = distinct !DISubprogram(name: "f1", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "gmlt.cpp", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !2) -!7 = distinct !DISubprogram(name: "f2", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, function: void ()* @_Z2f2v, variables: !2) -!8 = distinct !DISubprogram(name: "f3", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, function: void ()* @_Z2f3v, variables: !2) -!9 = distinct !DISubprogram(name: "f4", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !5, type: !6, function: void ()* @_Z2f4v, variables: !2) +!7 = distinct !DISubprogram(name: "f2", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) +!8 = distinct !DISubprogram(name: "f3", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !2) +!9 = distinct !DISubprogram(name: "f4", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !5, type: !6, variables: !2) !10 = !{i32 2, !"Dwarf Version", i32 4} !11 = !{i32 2, !"Debug Info Version", i32 3} !12 = !{!"clang version 3.6.0 "} diff --git a/test/DebugInfo/Inputs/line.ll b/test/DebugInfo/Inputs/line.ll index 156f26217ba..5bdd3b9eb34 100644 --- a/test/DebugInfo/Inputs/line.ll +++ b/test/DebugInfo/Inputs/line.ll @@ -12,7 +12,7 @@ ; CHECK: cmp ; Function Attrs: nounwind uwtable -define i32 @_Z1fii(i32 %a, i32 %b) #0 { +define i32 @_Z1fii(i32 %a, i32 %b) #0 !dbg !4 { entry: %a.addr = alloca i32, align 4 %b.addr = alloca i32, align 4 @@ -43,7 +43,7 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe !1 = !DIFile(filename: "line.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f", line: 1, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 (i32, i32)* @_Z1fii, variables: !2) +!4 = distinct !DISubprogram(name: "f", line: 1, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "line.cpp", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !2) !7 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/DebugInfo/Mips/InlinedFnLocalVar.ll b/test/DebugInfo/Mips/InlinedFnLocalVar.ll index f59b799535a..fe661522da7 100644 --- a/test/DebugInfo/Mips/InlinedFnLocalVar.ll +++ b/test/DebugInfo/Mips/InlinedFnLocalVar.ll @@ -12,7 +12,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnone -define i32 @bar() nounwind ssp { +define i32 @bar() nounwind ssp !dbg !6 { entry: %0 = load i32, i32* @i, align 4, !dbg !17 ; <i32> [#uses=2] tail call void @llvm.dbg.value(metadata i32 %0, i64 0, metadata !59, metadata !DIExpression()), !dbg !19 @@ -31,7 +31,7 @@ entry: !3 = !DISubroutineType(types: !4) !4 = !{!5, !5} !5 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!6 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !27, scope: !1, type: !7, function: i32 ()* @bar) +!6 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !27, scope: !1, type: !7) !7 = !DISubroutineType(types: !8) !8 = !{!5} !9 = !DILocalVariable(name: "j", line: 9, arg: 1, scope: !0, file: !1, type: !5) diff --git a/test/DebugInfo/Mips/delay-slot.ll b/test/DebugInfo/Mips/delay-slot.ll index 98bf0da4ef9..e4cb9eac7ce 100644 --- a/test/DebugInfo/Mips/delay-slot.ll +++ b/test/DebugInfo/Mips/delay-slot.ll @@ -26,7 +26,7 @@ target datalayout = "E-m:m-p:32:32-i8:8:32-i16:16:32-i64:64-n32-S64" target triple = "mips--linux-gnu" ; Function Attrs: nounwind -define i32 @foo(i32 %x) #0 { +define i32 @foo(i32 %x) #0 !dbg !4 { entry: call void @llvm.dbg.value(metadata i32 %x, i64 0, metadata !12, metadata !DIExpression()), !dbg !13 %tobool = icmp ne i32 %x, 0, !dbg !14 @@ -60,7 +60,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "test.c", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "test.c", directory: "/tmp") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} diff --git a/test/DebugInfo/Mips/fn-call-line.ll b/test/DebugInfo/Mips/fn-call-line.ll index fc66a48998d..a3130ce8c6e 100644 --- a/test/DebugInfo/Mips/fn-call-line.ll +++ b/test/DebugInfo/Mips/fn-call-line.ll @@ -52,7 +52,7 @@ ; Function Attrs: nounwind uwtable -define void @f2() #0 { +define void @f2() #0 !dbg !4 { entry: call void (...) @f1(), !dbg !11 call void (...) @f1(), !dbg !12 @@ -72,7 +72,7 @@ attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !1 = !DIFile(filename: "fn-call-line.c", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f2", line: 2, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, function: void ()* @f2, variables: !2) +!4 = distinct !DISubprogram(name: "f2", line: 2, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "fn-call-line.c", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !7) !7 = !{null} diff --git a/test/DebugInfo/Mips/prologue_end.ll b/test/DebugInfo/Mips/prologue_end.ll index 0bac36ec8ba..d93836d8498 100644 --- a/test/DebugInfo/Mips/prologue_end.ll +++ b/test/DebugInfo/Mips/prologue_end.ll @@ -12,7 +12,7 @@ @.str = private unnamed_addr constant [15 x i8] c"Hello, World!\0A\00", align 1 -define void @hello_world() #0 { +define void @hello_world() #0 !dbg !4 { entry: ; STATIC: addiu $sp, $sp, -{{[0-9]+}} ; STATIC: sw $ra, {{[0-9]+}}($sp) @@ -60,7 +60,7 @@ attributes #0 = { nounwind } !1 = !DIFile(filename: "test.c", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "hello_world", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: false, function: void ()* @hello_world, variables: !2) +!4 = distinct !DISubprogram(name: "hello_world", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/DebugInfo/Sparc/gnu-window-save.ll b/test/DebugInfo/Sparc/gnu-window-save.ll index edfc7bb27ef..d94cc7505f3 100644 --- a/test/DebugInfo/Sparc/gnu-window-save.ll +++ b/test/DebugInfo/Sparc/gnu-window-save.ll @@ -38,7 +38,7 @@ @.str = private unnamed_addr constant [14 x i8] c"hello, world\0A\00", align 1 ; Function Attrs: nounwind -define signext i32 @main() #0 { +define signext i32 @main() #0 !dbg !4 { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval @@ -59,7 +59,7 @@ attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !1 = !DIFile(filename: "hello.c", directory: "/home/venkatra/work/benchmarks/test/hello") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "hello.c", directory: "/home/venkatra/work/benchmarks/test/hello") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/DebugInfo/Sparc/prologue_end.ll b/test/DebugInfo/Sparc/prologue_end.ll index 213b368592e..43b1140620e 100644 --- a/test/DebugInfo/Sparc/prologue_end.ll +++ b/test/DebugInfo/Sparc/prologue_end.ll @@ -6,7 +6,7 @@ ; func(); ; } -define void @prologue_end_test() nounwind uwtable { +define void @prologue_end_test() nounwind uwtable !dbg !4 { ; CHECK: prologue_end_test: ; CHECK: .cfi_startproc ; CHECK: save %sp @@ -29,7 +29,7 @@ declare i32 @func() !1 = !DIFile(filename: "foo.c", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "prologue_end_test", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: false, function: void ()* @prologue_end_test, variables: !2) +!4 = distinct !DISubprogram(name: "prologue_end_test", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = !{i32 2, !"Dwarf Version", i32 2} diff --git a/test/DebugInfo/SystemZ/prologue_end.ll b/test/DebugInfo/SystemZ/prologue_end.ll index 8c1d0d54316..a62a8a75521 100644 --- a/test/DebugInfo/SystemZ/prologue_end.ll +++ b/test/DebugInfo/SystemZ/prologue_end.ll @@ -6,7 +6,7 @@ ; func(); ; } -define void @prologue_end_test() nounwind uwtable { +define void @prologue_end_test() nounwind uwtable !dbg !4 { ; CHECK: prologue_end_test: ; CHECK: .cfi_startproc ; CHECK: aghi @@ -30,7 +30,7 @@ declare i32 @func() !1 = !DIFile(filename: "foo.c", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "prologue_end_test", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: false, function: void ()* @prologue_end_test, variables: !2) +!4 = distinct !DISubprogram(name: "prologue_end_test", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = !{i32 2, !"Dwarf Version", i32 2} diff --git a/test/DebugInfo/SystemZ/variable-loc.ll b/test/DebugInfo/SystemZ/variable-loc.ll index fe66a8e3f9b..6ace1b61424 100644 --- a/test/DebugInfo/SystemZ/variable-loc.ll +++ b/test/DebugInfo/SystemZ/variable-loc.ll @@ -29,7 +29,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone declare i32 @sum_array(i32*, i32) nounwind -define i32 @main() nounwind { +define i32 @main() nounwind !dbg !14 { entry: %retval = alloca i32, align 4 %main_arr = alloca [100 x i32], align 4 @@ -55,16 +55,16 @@ declare i32 @printf(i8*, ...) !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.2 ", isOptimized: false, emissionKind: 0, file: !29, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5, !11, !14} -!5 = distinct !DISubprogram(name: "populate_array", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !29, scope: !6, type: !7, function: void (i32*, i32)* @populate_array, variables: !1) +!5 = distinct !DISubprogram(name: "populate_array", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !29, scope: !6, type: !7, variables: !1) !6 = !DIFile(filename: "simple.c", directory: "/home/timnor01/a64-trunk/build") !7 = !DISubroutineType(types: !8) !8 = !{null, !9, !10} !9 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !10) !10 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!11 = distinct !DISubprogram(name: "sum_array", line: 9, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 9, file: !29, scope: !6, type: !12, function: i32 (i32*, i32)* @sum_array, variables: !1) +!11 = distinct !DISubprogram(name: "sum_array", line: 9, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 9, file: !29, scope: !6, type: !12, variables: !1) !12 = !DISubroutineType(types: !13) !13 = !{!10, !9, !10} -!14 = distinct !DISubprogram(name: "main", line: 18, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 18, file: !29, scope: !6, type: !15, function: i32 ()* @main, variables: !1) +!14 = distinct !DISubprogram(name: "main", line: 18, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 18, file: !29, scope: !6, type: !15, variables: !1) !15 = !DISubroutineType(types: !16) !16 = !{!10} !17 = !DILocalVariable(name: "main_arr", line: 19, scope: !18, file: !6, type: !19) diff --git a/test/DebugInfo/X86/2010-04-13-PubType.ll b/test/DebugInfo/X86/2010-04-13-PubType.ll index 01dcac6c2eb..4688f959fbd 100644 --- a/test/DebugInfo/X86/2010-04-13-PubType.ll +++ b/test/DebugInfo/X86/2010-04-13-PubType.ll @@ -5,7 +5,7 @@ %struct.X = type opaque %struct.Y = type { i32 } -define i32 @foo(%struct.X* %x, %struct.Y* %y) nounwind ssp { +define i32 @foo(%struct.X* %x, %struct.Y* %y) nounwind ssp !dbg !1 { entry: %x_addr = alloca %struct.X* ; <%struct.X**> [#uses=1] %y_addr = alloca %struct.Y* ; <%struct.Y**> [#uses=1] @@ -32,7 +32,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !llvm.module.flags = !{!20} !0 = !DILocalVariable(name: "x", line: 7, arg: 1, scope: !1, file: !2, type: !7) -!1 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 7, file: !18, scope: !2, type: !4, function: i32 (%struct.X*, %struct.Y*)* @foo) +!1 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 7, file: !18, scope: !2, type: !4) !2 = !DIFile(filename: "a.c", directory: "/tmp/") !3 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: false, emissionKind: 0, file: !18, enums: !19, retainedTypes: !19, subprograms: !17, imports: null) !4 = !DISubroutineType(types: !5) diff --git a/test/DebugInfo/X86/2011-09-26-GlobalVarContext.ll b/test/DebugInfo/X86/2011-09-26-GlobalVarContext.ll index 82505760ae9..aaf72311cb4 100644 --- a/test/DebugInfo/X86/2011-09-26-GlobalVarContext.ll +++ b/test/DebugInfo/X86/2011-09-26-GlobalVarContext.ll @@ -5,7 +5,7 @@ @GLB = common global i32 0, align 4 -define i32 @f() nounwind { +define i32 @f() nounwind !dbg !5 { %LOC = alloca i32, align 4 call void @llvm.dbg.declare(metadata i32* %LOC, metadata !15, metadata !DIExpression()), !dbg !17 %1 = load i32, i32* @GLB, align 4, !dbg !18 @@ -22,7 +22,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 (trunk)", isOptimized: false, emissionKind: 0, file: !20, enums: !1, retainedTypes: !1, subprograms: !3, globals: !12, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "f", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !6, scope: !6, type: !7, function: i32 ()* @f) +!5 = distinct !DISubprogram(name: "f", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !6, scope: !6, type: !7) !6 = !DIFile(filename: "test.c", directory: "/work/llvm/vanilla/test/DebugInfo") !7 = !DISubroutineType(types: !8) !8 = !{!9} diff --git a/test/DebugInfo/X86/2011-12-16-BadStructRef.ll b/test/DebugInfo/X86/2011-12-16-BadStructRef.ll index 6031bdd9445..2319c0b7088 100644 --- a/test/DebugInfo/X86/2011-12-16-BadStructRef.ll +++ b/test/DebugInfo/X86/2011-12-16-BadStructRef.ll @@ -7,7 +7,7 @@ %struct.bar = type { %struct.baz, %struct.baz* } %struct.baz = type { i32 } -define i32 @main(i32 %argc, i8** %argv) uwtable ssp { +define i32 @main(i32 %argc, i8** %argv) uwtable ssp !dbg !29 { entry: %retval = alloca i32, align 4 %argc.addr = alloca i32, align 4 @@ -25,7 +25,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone -define linkonce_odr void @_ZN3barC1Ei(%struct.bar* %this, i32 %x) unnamed_addr uwtable ssp align 2 { +define linkonce_odr void @_ZN3barC1Ei(%struct.bar* %this, i32 %x) unnamed_addr uwtable ssp align 2 !dbg !37 { entry: %this.addr = alloca %struct.bar*, align 8 %x.addr = alloca i32, align 4 @@ -39,7 +39,7 @@ entry: ret void, !dbg !62 } -define linkonce_odr void @_ZN3barC2Ei(%struct.bar* %this, i32 %x) unnamed_addr uwtable ssp align 2 { +define linkonce_odr void @_ZN3barC2Ei(%struct.bar* %this, i32 %x) unnamed_addr uwtable ssp align 2 !dbg !40 { entry: %this.addr = alloca %struct.bar*, align 8 %x.addr = alloca i32, align 4 @@ -57,7 +57,7 @@ entry: ret void, !dbg !68 } -define linkonce_odr void @_ZN3bazC1Ei(%struct.baz* %this, i32 %a) unnamed_addr uwtable ssp align 2 { +define linkonce_odr void @_ZN3bazC1Ei(%struct.baz* %this, i32 %a) unnamed_addr uwtable ssp align 2 !dbg !43 { entry: %this.addr = alloca %struct.baz*, align 8 %a.addr = alloca i32, align 4 @@ -71,7 +71,7 @@ entry: ret void, !dbg !74 } -define linkonce_odr void @_ZN3bazC2Ei(%struct.baz* %this, i32 %a) unnamed_addr nounwind uwtable ssp align 2 { +define linkonce_odr void @_ZN3bazC2Ei(%struct.baz* %this, i32 %a) unnamed_addr nounwind uwtable ssp align 2 !dbg !46 { entry: %this.addr = alloca %struct.baz*, align 8 %a.addr = alloca i32, align 4 @@ -111,7 +111,7 @@ entry: !23 = !{null, !24, !12} !24 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial, baseType: !5) !27 = !{!29, !37, !40, !43, !46} -!29 = distinct !DISubprogram(name: "main", line: 17, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !82, scope: !6, type: !30, function: i32 (i32, i8**)* @main) +!29 = distinct !DISubprogram(name: "main", line: 17, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !82, scope: !6, type: !30) !30 = !DISubroutineType(types: !31) !31 = !{!12, !12, !32} !32 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !33) @@ -119,16 +119,16 @@ entry: !34 = !DIBasicType(tag: DW_TAG_base_type, name: "char", size: 8, align: 8, encoding: DW_ATE_signed_char) !35 = !{!36} !36 = !{} ; previously: invalid DW_TAG_base_type -!37 = distinct !DISubprogram(name: "bar", linkageName: "_ZN3barC1Ei", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !82, scope: null, type: !22, function: void (%struct.bar*, i32)* @_ZN3barC1Ei, declaration: !21) +!37 = distinct !DISubprogram(name: "bar", linkageName: "_ZN3barC1Ei", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !82, scope: null, type: !22, declaration: !21) !38 = !{!39} !39 = !{} ; previously: invalid DW_TAG_base_type -!40 = distinct !DISubprogram(name: "bar", linkageName: "_ZN3barC2Ei", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !82, scope: null, type: !22, function: void (%struct.bar*, i32)* @_ZN3barC2Ei, declaration: !21) +!40 = distinct !DISubprogram(name: "bar", linkageName: "_ZN3barC2Ei", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !82, scope: null, type: !22, declaration: !21) !41 = !{!42} !42 = !{} ; previously: invalid DW_TAG_base_type -!43 = distinct !DISubprogram(name: "baz", linkageName: "_ZN3bazC1Ei", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !82, scope: null, type: !14, function: void (%struct.baz*, i32)* @_ZN3bazC1Ei, declaration: !13) +!43 = distinct !DISubprogram(name: "baz", linkageName: "_ZN3bazC1Ei", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !82, scope: null, type: !14, declaration: !13) !44 = !{!45} !45 = !{} ; previously: invalid DW_TAG_base_type -!46 = distinct !DISubprogram(name: "baz", linkageName: "_ZN3bazC2Ei", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !82, scope: null, type: !14, function: void (%struct.baz*, i32)* @_ZN3bazC2Ei, declaration: !13) +!46 = distinct !DISubprogram(name: "baz", linkageName: "_ZN3bazC2Ei", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !82, scope: null, type: !14, declaration: !13) !49 = !DILocalVariable(name: "argc", line: 16, arg: 1, scope: !29, file: !6, type: !12) !50 = !DILocation(line: 16, column: 14, scope: !29) !51 = !DILocalVariable(name: "argv", line: 16, arg: 2, scope: !29, file: !6, type: !32) diff --git a/test/DebugInfo/X86/DW_AT_byte_size.ll b/test/DebugInfo/X86/DW_AT_byte_size.ll index d2a03ce5f3b..d879f6732e7 100644 --- a/test/DebugInfo/X86/DW_AT_byte_size.ll +++ b/test/DebugInfo/X86/DW_AT_byte_size.ll @@ -10,7 +10,7 @@ %struct.A = type { i32 } -define i32 @_Z3fooP1A(%struct.A* %a) nounwind uwtable ssp { +define i32 @_Z3fooP1A(%struct.A* %a) nounwind uwtable ssp !dbg !5 { entry: %a.addr = alloca %struct.A*, align 8 store %struct.A* %a, %struct.A** %a.addr, align 8 @@ -29,7 +29,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.1 (trunk 150996)", isOptimized: false, emissionKind: 0, file: !20, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooP1A", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !20, scope: !6, type: !7, function: i32 (%struct.A*)* @_Z3fooP1A) +!5 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooP1A", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !20, scope: !6, type: !7) !6 = !DIFile(filename: "foo.cpp", directory: "/Users/echristo") !7 = !DISubroutineType(types: !8) !8 = !{!9, !10} diff --git a/test/DebugInfo/X86/DW_AT_linkage_name.ll b/test/DebugInfo/X86/DW_AT_linkage_name.ll index 7759e2ed5f6..a3f3da2298e 100644 --- a/test/DebugInfo/X86/DW_AT_linkage_name.ll +++ b/test/DebugInfo/X86/DW_AT_linkage_name.ll @@ -34,7 +34,7 @@ target triple = "x86_64-apple-macosx10.9.0" %struct.A = type { i8 } ; Function Attrs: nounwind ssp uwtable -define void @_ZN1AD2Ev(%struct.A* %this) unnamed_addr #0 align 2 { +define void @_ZN1AD2Ev(%struct.A* %this) unnamed_addr #0 align 2 !dbg !17 { entry: %this.addr = alloca %struct.A*, align 8 store %struct.A* %this, %struct.A** %this.addr, align 8 @@ -47,7 +47,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: nounwind ssp uwtable -define void @_ZN1AD1Ev(%struct.A* %this) unnamed_addr #0 align 2 { +define void @_ZN1AD1Ev(%struct.A* %this) unnamed_addr #0 align 2 !dbg !18 { entry: %this.addr = alloca %struct.A*, align 8 store %struct.A* %this, %struct.A** %this.addr, align 8 @@ -58,7 +58,7 @@ entry: } ; Function Attrs: ssp uwtable -define void @_Z3foov() #2 { +define void @_Z3foov() #2 !dbg !19 { entry: %a = alloca %struct.A, align 1 call void @llvm.dbg.declare(metadata %struct.A* %a, metadata !34, metadata !DIExpression()), !dbg !35 @@ -92,9 +92,9 @@ attributes #2 = { ssp uwtable } !13 = !DISubroutineType(types: !14) !14 = !{null, !9} !16 = !{!17, !18, !19} -!17 = distinct !DISubprogram(name: "~A", linkageName: "_ZN1AD2Ev", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: !"_ZTS1A", type: !13, function: void (%struct.A*)* @_ZN1AD2Ev, declaration: !12, variables: !2) -!18 = distinct !DISubprogram(name: "~A", linkageName: "_ZN1AD1Ev", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: !"_ZTS1A", type: !13, function: void (%struct.A*)* @_ZN1AD1Ev, declaration: !12, variables: !2) -!19 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foov", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !1, scope: !20, type: !21, function: void ()* @_Z3foov, variables: !2) +!17 = distinct !DISubprogram(name: "~A", linkageName: "_ZN1AD2Ev", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: !"_ZTS1A", type: !13, declaration: !12, variables: !2) +!18 = distinct !DISubprogram(name: "~A", linkageName: "_ZN1AD1Ev", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: !"_ZTS1A", type: !13, declaration: !12, variables: !2) +!19 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foov", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !1, scope: !20, type: !21, variables: !2) !20 = !DIFile(filename: "linkage-name.cpp", directory: "") !21 = !DISubroutineType(types: !22) !22 = !{null} diff --git a/test/DebugInfo/X86/DW_AT_location-reference.ll b/test/DebugInfo/X86/DW_AT_location-reference.ll index fee2e24ca65..593611d76bc 100644 --- a/test/DebugInfo/X86/DW_AT_location-reference.ll +++ b/test/DebugInfo/X86/DW_AT_location-reference.ll @@ -60,7 +60,7 @@ target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f3 @a = external global i32 -define void @f() nounwind { +define void @f() nounwind !dbg !0 { entry: %call = tail call i32 @g(i32 0, i32 0) nounwind, !dbg !8 store i32 %call, i32* @a, align 4, !dbg !8 @@ -102,7 +102,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!24} -!0 = distinct !DISubprogram(name: "f", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 4, file: !23, scope: !1, type: !3, function: void ()* @f, variables: !22) +!0 = distinct !DISubprogram(name: "f", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 4, file: !23, scope: !1, type: !3, variables: !22) !1 = !DIFile(filename: "simple.c", directory: "/home/rengol01/temp/tests/dwarf/relocation") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 (trunk)", isOptimized: true, emissionKind: 1, file: !23, enums: !{}, retainedTypes: !{}, subprograms: !21, imports: null) !3 = !DISubroutineType(types: !4) diff --git a/test/DebugInfo/X86/DW_AT_object_pointer.ll b/test/DebugInfo/X86/DW_AT_object_pointer.ll index 715bf113fa3..4e6c7c83d1f 100644 --- a/test/DebugInfo/X86/DW_AT_object_pointer.ll +++ b/test/DebugInfo/X86/DW_AT_object_pointer.ll @@ -12,7 +12,7 @@ %class.A = type { i32 } -define i32 @_Z3fooi(i32) nounwind uwtable ssp { +define i32 @_Z3fooi(i32) nounwind uwtable ssp !dbg !5 { entry: %.addr = alloca i32, align 4 %a = alloca %class.A, align 4 @@ -27,7 +27,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone -define linkonce_odr void @_ZN1AC1Ev(%class.A* %this) unnamed_addr nounwind uwtable ssp align 2 { +define linkonce_odr void @_ZN1AC1Ev(%class.A* %this) unnamed_addr nounwind uwtable ssp align 2 !dbg !10 { entry: %this.addr = alloca %class.A*, align 8 store %class.A* %this, %class.A** %this.addr, align 8 @@ -37,7 +37,7 @@ entry: ret void, !dbg !29 } -define linkonce_odr void @_ZN1AC2Ev(%class.A* %this) unnamed_addr nounwind uwtable ssp align 2 { +define linkonce_odr void @_ZN1AC2Ev(%class.A* %this) unnamed_addr nounwind uwtable ssp align 2 !dbg !20 { entry: %this.addr = alloca %class.A*, align 8 store %class.A* %this, %class.A** %this.addr, align 8 @@ -54,12 +54,12 @@ entry: !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.2 (trunk 163586) (llvm/trunk 163570)", isOptimized: false, emissionKind: 0, file: !37, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5, !10, !20} -!5 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooi", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !6, scope: !6, type: !7, function: i32 (i32)* @_Z3fooi, variables: !1) +!5 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooi", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !6, scope: !6, type: !7, variables: !1) !6 = !DIFile(filename: "bar.cpp", directory: "/Users/echristo/debug-tests") !7 = !DISubroutineType(types: !8) !8 = !{!9} !9 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!10 = distinct !DISubprogram(name: "A", linkageName: "_ZN1AC1Ev", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !6, scope: null, type: !11, function: void (%class.A*)* @_ZN1AC1Ev, declaration: !17, variables: !1) +!10 = distinct !DISubprogram(name: "A", linkageName: "_ZN1AC1Ev", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !6, scope: null, type: !11, declaration: !17, variables: !1) !11 = !DISubroutineType(types: !12) !12 = !{null, !13} !13 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !14) @@ -67,7 +67,7 @@ entry: !15 = !{!16, !17} !16 = !DIDerivedType(tag: DW_TAG_member, name: "m_a", line: 4, size: 32, align: 32, file: !37, scope: !14, baseType: !9) !17 = !DISubprogram(name: "A", line: 3, isLocal: false, isDefinition: false, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !6, scope: !14, type: !11) -!20 = distinct !DISubprogram(name: "A", linkageName: "_ZN1AC2Ev", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !6, scope: null, type: !11, function: void (%class.A*)* @_ZN1AC2Ev, declaration: !17, variables: !1) +!20 = distinct !DISubprogram(name: "A", linkageName: "_ZN1AC2Ev", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !6, scope: null, type: !11, declaration: !17, variables: !1) !21 = !DILocalVariable(name: "a", line: 8, scope: !22, file: !6, type: !14) !22 = distinct !DILexicalBlock(line: 7, column: 11, file: !6, scope: !5) !23 = !DILocation(line: 8, column: 5, scope: !22) diff --git a/test/DebugInfo/X86/DW_AT_specification.ll b/test/DebugInfo/X86/DW_AT_specification.ll index ba3e6e5534a..2b8345b66b7 100644 --- a/test/DebugInfo/X86/DW_AT_specification.ll +++ b/test/DebugInfo/X86/DW_AT_specification.ll @@ -12,7 +12,7 @@ @_ZZN3foo3barEvE1x = constant i32 0, align 4 -define void @_ZN3foo3barEv() { +define void @_ZN3foo3barEv() !dbg !5 { entry: ret void, !dbg !25 } @@ -23,7 +23,7 @@ entry: !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.0 ()", isOptimized: false, emissionKind: 0, file: !27, enums: !1, retainedTypes: !1, subprograms: !3, globals: !18, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "bar", linkageName: "_ZN3foo3barEv", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !6, scope: null, type: !7, function: void ()* @_ZN3foo3barEv, declaration: !11) +!5 = distinct !DISubprogram(name: "bar", linkageName: "_ZN3foo3barEv", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !6, scope: null, type: !7, declaration: !11) !6 = !DIFile(filename: "nsNativeAppSupportBase.ii", directory: "/Users/espindola/mozilla-central/obj-x86_64-apple-darwin11.2.0/toolkit/library") !7 = !DISubroutineType(types: !8) !8 = !{null, !9} diff --git a/test/DebugInfo/X86/DW_AT_stmt_list_sec_offset.ll b/test/DebugInfo/X86/DW_AT_stmt_list_sec_offset.ll index d4b6311f1a5..988a2b7daf4 100644 --- a/test/DebugInfo/X86/DW_AT_stmt_list_sec_offset.ll +++ b/test/DebugInfo/X86/DW_AT_stmt_list_sec_offset.ll @@ -18,7 +18,7 @@ target datalayout = "e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f3 target triple = "i686-pc-win32" ; Function Attrs: nounwind -define i32 @main() #0 { +define i32 @main() #0 !dbg !4 { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval @@ -34,7 +34,7 @@ attributes #0 = { nounwind "less-precise-fpmad"="false" "no-frame-pointer-elim"= !1 = !DIFile(filename: "test.c", directory: "C:\5CProjects") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "test.c", directory: "C:CProjects") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/DebugInfo/X86/InlinedFnLocalVar.ll b/test/DebugInfo/X86/InlinedFnLocalVar.ll index d140d023a50..a262fc8e88c 100644 --- a/test/DebugInfo/X86/InlinedFnLocalVar.ll +++ b/test/DebugInfo/X86/InlinedFnLocalVar.ll @@ -12,7 +12,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnone -define i32 @bar() nounwind ssp { +define i32 @bar() nounwind ssp !dbg !6 { entry: %0 = load i32, i32* @i, align 4, !dbg !17 ; <i32> [#uses=2] tail call void @llvm.dbg.value(metadata i32 %0, i64 0, metadata !109, metadata !DIExpression()), !dbg !19 @@ -31,7 +31,7 @@ entry: !3 = !DISubroutineType(types: !4) !4 = !{!5, !5} !5 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!6 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !27, scope: !1, type: !7, function: i32 ()* @bar) +!6 = distinct !DISubprogram(name: "bar", linkageName: "bar", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !27, scope: !1, type: !7) !7 = !DISubroutineType(types: !8) !8 = !{!5} !9 = !DILocalVariable(name: "j", line: 9, arg: 1, scope: !0, file: !1, type: !5) diff --git a/test/DebugInfo/X86/aligned_stack_var.ll b/test/DebugInfo/X86/aligned_stack_var.ll index acc8196afa5..02a51f346ee 100644 --- a/test/DebugInfo/X86/aligned_stack_var.ll +++ b/test/DebugInfo/X86/aligned_stack_var.ll @@ -15,7 +15,7 @@ ; CHECK-NOT: {{DW_AT_location.*DW_FORM_block1.*0x.*91}} ; CHECK: NULL -define void @_Z3runv() nounwind uwtable { +define void @_Z3runv() nounwind uwtable !dbg !5 { entry: %x = alloca i32, align 32 call void @llvm.dbg.declare(metadata i32* %x, metadata !9, metadata !DIExpression()), !dbg !12 @@ -30,7 +30,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.2 (trunk 155696:155697) (llvm/trunk 155696)", isOptimized: false, emissionKind: 0, file: !14, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "run", linkageName: "_Z3runv", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !14, scope: !6, type: !7, function: void ()* @_Z3runv, variables: !1) +!5 = distinct !DISubprogram(name: "run", linkageName: "_Z3runv", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !14, scope: !6, type: !7, variables: !1) !6 = !DIFile(filename: "test.cc", directory: "/home/samsonov/debuginfo") !7 = !DISubroutineType(types: !8) !8 = !{null} diff --git a/test/DebugInfo/X86/arange-and-stub.ll b/test/DebugInfo/X86/arange-and-stub.ll index 5e35e5e84ca..599c1e5a2bc 100644 --- a/test/DebugInfo/X86/arange-and-stub.ll +++ b/test/DebugInfo/X86/arange-and-stub.ll @@ -12,11 +12,11 @@ target triple = "x86_64-linux-gnu" @_ZTId = external constant i8* @zed = global [1 x void ()*] [void ()* @bar] -define void @foo() { +define void @foo() !dbg !4 { ret void } -define void @bar() personality i8* bitcast (void ()* @foo to i8*) { +define void @bar() personality i8* bitcast (void ()* @foo to i8*) !dbg !9 { invoke void @foo() to label %invoke.cont unwind label %lpad @@ -36,12 +36,12 @@ lpad: ; preds = %0 !1 = !DIFile(filename: "/Users/espindola/llvm/<stdin>", directory: "/Users/espindola/llvm/build") !2 = !{} !3 = !{!4, !9} -!4 = distinct !DISubprogram(name: "foo", linkageName: "foo", scope: !5, file: !5, line: 1, type: !6, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: false, function: void ()* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", linkageName: "foo", scope: !5, file: !5, line: 1, type: !6, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DIFile(filename: "/Users/espindola/llvm/test.cpp", directory: "/Users/espindola/llvm/build") !6 = !DISubroutineType(types: !7) !7 = !{null, !8} !8 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!9 = distinct !DISubprogram(name: "bar_d", linkageName: "bar", scope: !5, file: !5, line: 3, type: !6, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, function: void ()* @bar, variables: !2) +!9 = distinct !DISubprogram(name: "bar_d", linkageName: "bar", scope: !5, file: !5, line: 3, type: !6, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !10 = !{!11} !11 = !DIGlobalVariable(name: "zed", scope: !0, file: !5, line: 6, type: !12, isLocal: false, isDefinition: true, variable: [1 x void ()*]* @zed) !12 = !DICompositeType(tag: DW_TAG_array_type, baseType: !13, size: 64, align: 64, elements: !15) diff --git a/test/DebugInfo/X86/arguments.ll b/test/DebugInfo/X86/arguments.ll index 3288fcaf382..8b3902765bb 100644 --- a/test/DebugInfo/X86/arguments.ll +++ b/test/DebugInfo/X86/arguments.ll @@ -29,7 +29,7 @@ %struct.foo = type { i32 } ; Function Attrs: nounwind uwtable -define void @_Z4func3fooS_(%struct.foo* %f, %struct.foo* %g) #0 { +define void @_Z4func3fooS_(%struct.foo* %f, %struct.foo* %g) #0 !dbg !4 { entry: call void @llvm.dbg.declare(metadata %struct.foo* %f, metadata !19, metadata !DIExpression()), !dbg !20 call void @llvm.dbg.declare(metadata %struct.foo* %g, metadata !21, metadata !DIExpression()), !dbg !20 @@ -53,7 +53,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "scratch.cpp", directory: "/usr/local/google/home/blaikie/dev/scratch") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "func", linkageName: "_Z4func3fooS_", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: !5, type: !6, function: void (%struct.foo*, %struct.foo*)* @_Z4func3fooS_, variables: !2) +!4 = distinct !DISubprogram(name: "func", linkageName: "_Z4func3fooS_", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "scratch.cpp", directory: "/usr/local/google/home/blaikie/dev/scratch") !6 = !DISubroutineType(types: !7) !7 = !{null, !8, !8} diff --git a/test/DebugInfo/X86/array.ll b/test/DebugInfo/X86/array.ll index 70006dddd76..3e0180e62d5 100644 --- a/test/DebugInfo/X86/array.ll +++ b/test/DebugInfo/X86/array.ll @@ -24,14 +24,14 @@ target triple = "x86_64-apple-macosx10.9.0" @main.array = private unnamed_addr constant [4 x i32] [i32 0, i32 1, i32 2, i32 3], align 16 ; Function Attrs: nounwind ssp uwtable -define void @f(i32* nocapture %p) #0 { +define void @f(i32* nocapture %p) #0 !dbg !4 { tail call void @llvm.dbg.value(metadata i32* %p, i64 0, metadata !11, metadata !DIExpression()), !dbg !28 store i32 42, i32* %p, align 4, !dbg !29, !tbaa !30 ret void, !dbg !34 } ; Function Attrs: nounwind ssp uwtable -define i32 @main(i32 %argc, i8** nocapture readnone %argv) #0 { +define i32 @main(i32 %argc, i8** nocapture readnone %argv) #0 !dbg !12 { %array = alloca [4 x i32], align 16 tail call void @llvm.dbg.value(metadata i32 %argc, i64 0, metadata !19, metadata !DIExpression()), !dbg !35 tail call void @llvm.dbg.value(metadata i8** %argv, i64 0, metadata !20, metadata !DIExpression()), !dbg !35 @@ -64,7 +64,7 @@ attributes #2 = { nounwind readnone } !1 = !DIFile(filename: "array.c", directory: "") !2 = !{} !3 = !{!4, !12} -!4 = distinct !DISubprogram(name: "f", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !1, scope: !5, type: !6, function: void (i32*)* @f, variables: !10) +!4 = distinct !DISubprogram(name: "f", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !10) !5 = !DIFile(filename: "array.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{null, !8} @@ -72,7 +72,7 @@ attributes #2 = { nounwind readnone } !9 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !10 = !{!11} !11 = !DILocalVariable(name: "p", line: 1, arg: 1, scope: !4, file: !5, type: !8) -!12 = distinct !DISubprogram(name: "main", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !1, scope: !5, type: !13, function: i32 (i32, i8**)* @main, variables: !18) +!12 = distinct !DISubprogram(name: "main", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !1, scope: !5, type: !13, variables: !18) !13 = !DISubroutineType(types: !14) !14 = !{!9, !9, !15} !15 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !16) diff --git a/test/DebugInfo/X86/array2.ll b/test/DebugInfo/X86/array2.ll index 22cb3362c81..f456aae2e25 100644 --- a/test/DebugInfo/X86/array2.ll +++ b/test/DebugInfo/X86/array2.ll @@ -25,7 +25,7 @@ target triple = "x86_64-apple-macosx10.9.0" @main.array = private unnamed_addr constant [4 x i32] [i32 0, i32 1, i32 2, i32 3], align 16 ; Function Attrs: nounwind ssp uwtable -define void @f(i32* %p) #0 { +define void @f(i32* %p) #0 !dbg !4 { entry: %p.addr = alloca i32*, align 8 store i32* %p, i32** %p.addr, align 8 @@ -40,7 +40,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: nounwind ssp uwtable -define i32 @main(i32 %argc, i8** %argv) #0 { +define i32 @main(i32 %argc, i8** %argv) #0 !dbg !10 { entry: %retval = alloca i32, align 4 %argc.addr = alloca i32, align 4 @@ -76,13 +76,13 @@ attributes #2 = { nounwind } !1 = !DIFile(filename: "array.c", directory: "") !2 = !{} !3 = !{!4, !10} -!4 = distinct !DISubprogram(name: "f", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: void (i32*)* @f, variables: !2) +!4 = distinct !DISubprogram(name: "f", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "array.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{null, !8} !8 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !9) !9 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!10 = distinct !DISubprogram(name: "main", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !11, function: i32 (i32, i8**)* @main, variables: !2) +!10 = distinct !DISubprogram(name: "main", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !11, variables: !2) !11 = !DISubroutineType(types: !12) !12 = !{!9, !9, !13} !13 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !14) diff --git a/test/DebugInfo/X86/block-capture.ll b/test/DebugInfo/X86/block-capture.ll index 032da0be93d..640973ed2a6 100644 --- a/test/DebugInfo/X86/block-capture.ll +++ b/test/DebugInfo/X86/block-capture.ll @@ -27,7 +27,7 @@ target triple = "x86_64-apple-darwin" declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: ssp uwtable -define internal void @__foo_block_invoke(i8* %.block_descriptor) #2 { +define internal void @__foo_block_invoke(i8* %.block_descriptor) #2 !dbg !8 { entry: %.block_descriptor.addr = alloca i8*, align 8 %block.addr = alloca <{ i8*, i32, i32, i8*, %struct.__block_descriptor*, void (...)* }>*, align 8 @@ -69,7 +69,7 @@ attributes #3 = { nounwind } !5 = !DIFile(filename: "foo.m", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{null} -!8 = distinct !DISubprogram(name: "__foo_block_invoke", line: 2, isLocal: true, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !9, function: void (i8*)* @__foo_block_invoke, variables: !2) +!8 = distinct !DISubprogram(name: "__foo_block_invoke", line: 2, isLocal: true, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !9, variables: !2) !9 = !DISubroutineType(types: !10) !10 = !{null, !11} !11 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: null) diff --git a/test/DebugInfo/X86/byvalstruct.ll b/test/DebugInfo/X86/byvalstruct.ll index 002e523de04..422789ae77b 100644 --- a/test/DebugInfo/X86/byvalstruct.ll +++ b/test/DebugInfo/X86/byvalstruct.ll @@ -58,7 +58,7 @@ target triple = "x86_64-apple-macosx10.8.0" @llvm.used = appending global [5 x i8*] [i8* getelementptr inbounds ([7 x i8], [7 x i8]* @"\01L_OBJC_CLASS_NAME_", i32 0, i32 0), i8* getelementptr inbounds ([32 x i8], [32 x i8]* @"\01L_OBJC_METH_VAR_NAME_", i32 0, i32 0), i8* getelementptr inbounds ([23 x i8], [23 x i8]* @"\01L_OBJC_METH_VAR_TYPE_", i32 0, i32 0), i8* bitcast ({ i32, i32, [1 x %struct._objc_method] }* @"\01l_OBJC_$_INSTANCE_METHODS_Bitmap" to i8*), i8* bitcast ([1 x i8*]* @"\01L_OBJC_LABEL_CLASS_$" to i8*)], section "llvm.metadata" ; Function Attrs: ssp uwtable -define internal i8* @"\01-[Bitmap initWithCopy:andInfo:andLength:]"(%0* %self, i8* %_cmd, %0* %otherBitmap, %struct.ImageInfo* byval align 8 %info, i64 %length) #0 { +define internal i8* @"\01-[Bitmap initWithCopy:andInfo:andLength:]"(%0* %self, i8* %_cmd, %0* %otherBitmap, %struct.ImageInfo* byval align 8 %info, i64 %length) #0 !dbg !7 { entry: %retval = alloca i8*, align 8 %self.addr = alloca %0*, align 8 @@ -94,7 +94,7 @@ attributes #1 = { nounwind readnone } !4 = !DICompositeType(tag: DW_TAG_structure_type, name: "Bitmap", line: 8, size: 8, align: 8, flags: DIFlagObjcClassComplete, runtimeLang: DW_LANG_ObjC_plus_plus, file: !1, scope: !5, elements: !2) !5 = !DIFile(filename: "t.mm", directory: "") !6 = !{!7} -!7 = distinct !DISubprogram(name: "-[Bitmap initWithCopy:andInfo:andLength:]", line: 9, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 9, file: !1, scope: !5, type: !8, function: i8* (%0*, i8*, %0*, %struct.ImageInfo*, i64)* @"\01-[Bitmap initWithCopy:andInfo:andLength:]", variables: !2) +!7 = distinct !DISubprogram(name: "-[Bitmap initWithCopy:andInfo:andLength:]", line: 9, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 9, file: !1, scope: !5, type: !8, variables: !2) !8 = !DISubroutineType(types: !9) !9 = !{!4, !10, !11, !14, !15, !19} !10 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !4) diff --git a/test/DebugInfo/X86/coff_debug_info_type.ll b/test/DebugInfo/X86/coff_debug_info_type.ll index f06f4897af0..cede74d5dc6 100644 --- a/test/DebugInfo/X86/coff_debug_info_type.ll +++ b/test/DebugInfo/X86/coff_debug_info_type.ll @@ -19,7 +19,7 @@ ; return 0; ; } -define i32 @main() #0 { +define i32 @main() #0 !dbg !4 { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval @@ -35,7 +35,7 @@ attributes #0 = { nounwind "less-precise-fpmad"="false" "no-frame-pointer-elim"= !1 = !DIFile(filename: "test.c", directory: "C:\5CProjects") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "test.c", directory: "C:CProjects") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/DebugInfo/X86/coff_relative_names.ll b/test/DebugInfo/X86/coff_relative_names.ll index 7c0824923ab..7ca4b04a871 100644 --- a/test/DebugInfo/X86/coff_relative_names.ll +++ b/test/DebugInfo/X86/coff_relative_names.ll @@ -11,7 +11,7 @@ ; } ; Function Attrs: nounwind -define i32 @main() #0 { +define i32 @main() #0 !dbg !4 { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval @@ -27,7 +27,7 @@ attributes #0 = { nounwind "less-precise-fpmad"="false" "no-frame-pointer-elim"= !1 = !DIFile(filename: "test.c", directory: "C:\5CProjects") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "test.c", directory: "C:CProjects") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/DebugInfo/X86/concrete_out_of_line.ll b/test/DebugInfo/X86/concrete_out_of_line.ll index 173fa11dbfe..d34c1ae37e3 100644 --- a/test/DebugInfo/X86/concrete_out_of_line.ll +++ b/test/DebugInfo/X86/concrete_out_of_line.ll @@ -60,14 +60,14 @@ ; CHECK-NEXT: DW_AT_abstract_origin {{.*}} "_ZN17nsAutoRefCntD2Ev" -define i32 @_ZN17nsAutoRefCnt7ReleaseEv() { +define i32 @_ZN17nsAutoRefCnt7ReleaseEv() !dbg !5 { entry: store i32 1, i32* null, align 4, !dbg !50 tail call void @_Z8moz_freePv(i8* null) nounwind, !dbg !54 ret i32 0 } -define void @_ZN17nsAutoRefCntD1Ev() { +define void @_ZN17nsAutoRefCntD1Ev() !dbg !23 { entry: tail call void @_Z8moz_freePv(i8* null) nounwind, !dbg !57 ret void @@ -81,7 +81,7 @@ declare void @_Z8moz_freePv(i8*) !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.1 ()", isOptimized: true, emissionKind: 0, file: !59, enums: !1, retainedTypes: !1, subprograms: !3, globals: !47, imports: !1) !1 = !{} !3 = !{!5, !23, !27, !31} -!5 = distinct !DISubprogram(name: "Release", linkageName: "_ZN17nsAutoRefCnt7ReleaseEv", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 14, file: !6, scope: null, type: !7, function: i32 ()* @_ZN17nsAutoRefCnt7ReleaseEv , declaration: !12, variables: !20) +!5 = distinct !DISubprogram(name: "Release", linkageName: "_ZN17nsAutoRefCnt7ReleaseEv", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 14, file: !6, scope: null, type: !7 , declaration: !12, variables: !20) !6 = !DIFile(filename: "nsAutoRefCnt.ii", directory: "/Users/espindola/mozilla-central/obj-x86_64-apple-darwin11.2.0/netwerk/base/src") !7 = !DISubroutineType(types: !8) !8 = !{!9, !10} @@ -97,10 +97,10 @@ declare void @_Z8moz_freePv(i8*) !18 = !{} !20 = !{!22} !22 = !DILocalVariable(name: "this", line: 14, arg: 1, flags: DIFlagArtificial, scope: !5, file: !6, type: !10) -!23 = distinct !DISubprogram(name: "~nsAutoRefCnt", linkageName: "_ZN17nsAutoRefCntD1Ev", line: 18, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 18, file: !6, scope: null, type: !16, function: void ()* @_ZN17nsAutoRefCntD1Ev, declaration: !15, variables: !24) +!23 = distinct !DISubprogram(name: "~nsAutoRefCnt", linkageName: "_ZN17nsAutoRefCntD1Ev", line: 18, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 18, file: !6, scope: null, type: !16, declaration: !15, variables: !24) !24 = !{!26} !26 = !DILocalVariable(name: "this", line: 18, arg: 1, flags: DIFlagArtificial, scope: !23, file: !6, type: !10) -!27 = distinct !DISubprogram(name: "~nsAutoRefCnt", linkageName: "_ZN17nsAutoRefCntD2Ev", line: 18, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 18, file: !6, scope: null, type: !16, function: i32 ()* null, declaration: !15, variables: !28) +!27 = distinct !DISubprogram(name: "~nsAutoRefCnt", linkageName: "_ZN17nsAutoRefCntD2Ev", line: 18, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 18, file: !6, scope: null, type: !16, declaration: !15, variables: !28) !28 = !{!30} !30 = !DILocalVariable(name: "this", line: 18, arg: 1, flags: DIFlagArtificial, scope: !27, file: !6, type: !10) !31 = distinct !DISubprogram(name: "operator=", linkageName: "_ZN12nsAutoRefCntaSEi", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 4, file: !6, scope: null, type: !32, declaration: !36, variables: !43) diff --git a/test/DebugInfo/X86/constant-aggregate.ll b/test/DebugInfo/X86/constant-aggregate.ll index aeee68b6ab1..35bf9a51680 100644 --- a/test/DebugInfo/X86/constant-aggregate.ll +++ b/test/DebugInfo/X86/constant-aggregate.ll @@ -40,7 +40,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-apple-macosx10.10.0" ; Function Attrs: nounwind readnone ssp uwtable -define i32 @_Z3foo1S(i32 %s.coerce) #0 { +define i32 @_Z3foo1S(i32 %s.coerce) #0 !dbg !12 { entry: tail call void @llvm.dbg.value(metadata i32 %s.coerce, i64 0, metadata !18, metadata !37), !dbg !38 tail call void @llvm.dbg.value(metadata i32 1, i64 0, metadata !18, metadata !37), !dbg !38 @@ -48,7 +48,7 @@ entry: } ; Function Attrs: nounwind readnone ssp uwtable -define i32 @_Z3foo1C(i32 %c.coerce) #0 { +define i32 @_Z3foo1C(i32 %c.coerce) #0 !dbg !19 { entry: tail call void @llvm.dbg.value(metadata i32 %c.coerce, i64 0, metadata !23, metadata !37), !dbg !40 tail call void @llvm.dbg.value(metadata i32 2, i64 0, metadata !23, metadata !37), !dbg !40 @@ -56,7 +56,7 @@ entry: } ; Function Attrs: nounwind readnone ssp uwtable -define i32 @_Z3barv() #0 { +define i32 @_Z3barv() #0 !dbg !24 { entry: tail call void @llvm.dbg.value(metadata i32 3, i64 0, metadata !28, metadata !37), !dbg !42 ret i32 3, !dbg !43 @@ -84,19 +84,19 @@ attributes #1 = { nounwind readnone } !9 = !{!10} !10 = !DIDerivedType(tag: DW_TAG_member, name: "i", line: 8, size: 32, align: 32, flags: DIFlagPublic, file: !1, scope: !"_ZTS1C", baseType: !7) !11 = !{!12, !19, !24} -!12 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foo1S", line: 3, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !13, type: !14, function: i32 (i32)* @_Z3foo1S, variables: !17) +!12 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foo1S", line: 3, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !13, type: !14, variables: !17) !13 = !DIFile(filename: "sroasplit-4.cpp", directory: "") !14 = !DISubroutineType(types: !15) !15 = !{!7, !16} !16 = !DIDerivedType(tag: DW_TAG_typedef, name: "S", line: 1, file: !1, baseType: !"_ZTS1S") !17 = !{!18} !18 = !DILocalVariable(name: "s", line: 3, arg: 1, scope: !12, file: !13, type: !16) -!19 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foo1C", line: 10, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 10, file: !1, scope: !13, type: !20, function: i32 (i32)* @_Z3foo1C, variables: !22) +!19 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foo1C", line: 10, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 10, file: !1, scope: !13, type: !20, variables: !22) !20 = !DISubroutineType(types: !21) !21 = !{!7, !"_ZTS1C"} !22 = !{!23} !23 = !DILocalVariable(name: "c", line: 10, arg: 1, scope: !19, file: !13, type: !"_ZTS1C") -!24 = distinct !DISubprogram(name: "bar", linkageName: "_Z3barv", line: 15, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 15, file: !1, scope: !13, type: !25, function: i32 ()* @_Z3barv, variables: !27) +!24 = distinct !DISubprogram(name: "bar", linkageName: "_Z3barv", line: 15, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 15, file: !1, scope: !13, type: !25, variables: !27) !25 = !DISubroutineType(types: !26) !26 = !{!7} !27 = !{!28} diff --git a/test/DebugInfo/X86/cu-ranges-odr.ll b/test/DebugInfo/X86/cu-ranges-odr.ll index 11c44b25e51..67da59a0e4b 100644 --- a/test/DebugInfo/X86/cu-ranges-odr.ll +++ b/test/DebugInfo/X86/cu-ranges-odr.ll @@ -23,14 +23,14 @@ @a = global %class.A zeroinitializer, align 4 @llvm.global_ctors = appending global [1 x { i32, void ()* }] [{ i32, void ()* } { i32 65535, void ()* @_GLOBAL__I_a }] -define internal void @__cxx_global_var_init() section ".text.startup" { +define internal void @__cxx_global_var_init() section ".text.startup" !dbg !14 { entry: call void @_ZN1AC2Ei(%class.A* @a, i32 0), !dbg !26 ret void, !dbg !26 } ; Function Attrs: nounwind uwtable -define linkonce_odr void @_ZN1AC2Ei(%class.A* %this, i32 %i) unnamed_addr #0 align 2 { +define linkonce_odr void @_ZN1AC2Ei(%class.A* %this, i32 %i) unnamed_addr #0 align 2 !dbg !18 { entry: %this.addr = alloca %class.A*, align 8 %i.addr = alloca i32, align 4 @@ -48,7 +48,7 @@ entry: ; Function Attrs: nounwind readnone declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 -define internal void @_GLOBAL__I_a() section ".text.startup" { +define internal void @_GLOBAL__I_a() section ".text.startup" !dbg !19 { entry: call void @__cxx_global_var_init(), !dbg !32 ret void, !dbg !32 @@ -74,12 +74,12 @@ attributes #1 = { nounwind readnone } !10 = !{null, !11, !7} !11 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS1A") !13 = !{!14, !18, !19} -!14 = distinct !DISubprogram(name: "__cxx_global_var_init", line: 8, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 8, file: !1, scope: !15, type: !16, function: void ()* @__cxx_global_var_init, variables: !2) +!14 = distinct !DISubprogram(name: "__cxx_global_var_init", line: 8, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 8, file: !1, scope: !15, type: !16, variables: !2) !15 = !DIFile(filename: "baz.cpp", directory: "/usr/local/google/home/echristo/tmp") !16 = !DISubroutineType(types: !17) !17 = !{null} -!18 = distinct !DISubprogram(name: "A", linkageName: "_ZN1AC2Ei", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !"_ZTS1A", type: !9, function: void (%class.A*, i32)* @_ZN1AC2Ei, declaration: !8, variables: !2) -!19 = distinct !DISubprogram(name: "", linkageName: "_GLOBAL__I_a", line: 3, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagArtificial, isOptimized: false, scopeLine: 3, file: !1, scope: !15, type: !20, function: void ()* @_GLOBAL__I_a, variables: !2) +!18 = distinct !DISubprogram(name: "A", linkageName: "_ZN1AC2Ei", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !"_ZTS1A", type: !9, declaration: !8, variables: !2) +!19 = distinct !DISubprogram(name: "", linkageName: "_GLOBAL__I_a", line: 3, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagArtificial, isOptimized: false, scopeLine: 3, file: !1, scope: !15, type: !20, variables: !2) !20 = !DISubroutineType(types: !2) !21 = !{!22} !22 = !DIGlobalVariable(name: "a", line: 8, isLocal: false, isDefinition: true, scope: null, file: !15, type: !4, variable: %class.A* @a) diff --git a/test/DebugInfo/X86/cu-ranges.ll b/test/DebugInfo/X86/cu-ranges.ll index c5730d1d981..543684596d9 100644 --- a/test/DebugInfo/X86/cu-ranges.ll +++ b/test/DebugInfo/X86/cu-ranges.ll @@ -25,7 +25,7 @@ ; NO-FUNCTION-SECTIONS-NOT: DW_AT_ranges ; Function Attrs: nounwind uwtable -define i32 @foo(i32 %a) #0 { +define i32 @foo(i32 %a) #0 !dbg !4 { entry: %a.addr = alloca i32, align 4 store i32 %a, i32* %a.addr, align 4 @@ -39,7 +39,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: nounwind uwtable -define i32 @bar(i32 %b) #0 { +define i32 @bar(i32 %b) #0 !dbg !9 { entry: %b.addr = alloca i32, align 4 store i32 %b, i32* %b.addr, align 4 @@ -60,12 +60,12 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "z.c", directory: "/usr/local/google/home/echristo") !2 = !{} !3 = !{!4, !9} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "z.c", directory: "/usr/local/google/home/echristo") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} !8 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!9 = distinct !DISubprogram(name: "bar", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, function: i32 (i32)* @bar, variables: !2) +!9 = distinct !DISubprogram(name: "bar", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) !10 = !{i32 2, !"Dwarf Version", i32 4} !11 = !{i32 1, !"Debug Info Version", i32 3} !12 = !{!"clang version 3.5.0 (trunk 204164) (llvm/trunk 204183)"} diff --git a/test/DebugInfo/X86/dbg-byval-parameter.ll b/test/DebugInfo/X86/dbg-byval-parameter.ll index 319e852f9a8..c80f8d90ca8 100644 --- a/test/DebugInfo/X86/dbg-byval-parameter.ll +++ b/test/DebugInfo/X86/dbg-byval-parameter.ll @@ -4,7 +4,7 @@ %struct.Pt = type { double, double } %struct.Rect = type { %struct.Pt, %struct.Pt } -define double @foo(%struct.Rect* byval %my_r0) nounwind ssp { +define double @foo(%struct.Rect* byval %my_r0) nounwind ssp !dbg !1 { entry: %retval = alloca double ; <double*> [#uses=2] %0 = alloca double ; <double*> [#uses=2] @@ -29,7 +29,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !llvm.module.flags = !{!21} !0 = !DILocalVariable(name: "my_r0", line: 11, arg: 1, scope: !1, file: !2, type: !7) -!1 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !19, scope: !2, type: !4, function: double (%struct.Rect*)* @foo) +!1 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !19, scope: !2, type: !4) !2 = !DIFile(filename: "b2.c", directory: "/tmp/") !3 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: false, emissionKind: 0, file: !19, enums: !20, retainedTypes: !20, subprograms: !18, imports: null) !4 = !DISubroutineType(types: !5) diff --git a/test/DebugInfo/X86/dbg-const-int.ll b/test/DebugInfo/X86/dbg-const-int.ll index 8b50a22a577..7e90a14c21a 100644 --- a/test/DebugInfo/X86/dbg-const-int.ll +++ b/test/DebugInfo/X86/dbg-const-int.ll @@ -10,7 +10,7 @@ target triple = "x86_64-apple-macosx10.6.7" ; CHECK-NOT: DW_TAG ; CHECK: DW_AT_name {{.*}} "i" -define i32 @foo() nounwind uwtable readnone optsize ssp { +define i32 @foo() nounwind uwtable readnone optsize ssp !dbg !1 { entry: tail call void @llvm.dbg.value(metadata i32 42, i64 0, metadata !6, metadata !DIExpression()), !dbg !9 ret i32 42, !dbg !10 @@ -22,7 +22,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.module.flags = !{!15} !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 (trunk 132191)", isOptimized: true, emissionKind: 0, file: !13, enums: !14, retainedTypes: !14, subprograms: !11, imports: null) -!1 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !13, scope: !2, type: !3, function: i32 ()* @foo, variables: !12) +!1 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !13, scope: !2, type: !3, variables: !12) !2 = !DIFile(filename: "a.c", directory: "/private/tmp") !3 = !DISubroutineType(types: !4) !4 = !{!5} diff --git a/test/DebugInfo/X86/dbg-const.ll b/test/DebugInfo/X86/dbg-const.ll index 31aaecd4465..6d710c512fd 100644 --- a/test/DebugInfo/X86/dbg-const.ll +++ b/test/DebugInfo/X86/dbg-const.ll @@ -15,7 +15,7 @@ target triple = "x86_64-apple-darwin10.0.0" ;CHECK: ## DW_OP_consts ;CHECK-NEXT: .byte 42 -define i32 @foobar() nounwind readonly noinline ssp { +define i32 @foobar() nounwind readonly noinline ssp !dbg !0 { entry: tail call void @llvm.dbg.value(metadata i32 42, i64 0, metadata !6, metadata !DIExpression()), !dbg !9 %call = tail call i32 @bar(), !dbg !11 @@ -31,7 +31,7 @@ declare i32 @bar() nounwind readnone !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!17} -!0 = distinct !DISubprogram(name: "foobar", linkageName: "foobar", line: 12, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !15, scope: !1, type: !3, function: i32 ()* @foobar, variables: !14) +!0 = distinct !DISubprogram(name: "foobar", linkageName: "foobar", line: 12, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !15, scope: !1, type: !3, variables: !14) !1 = !DIFile(filename: "mu.c", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 2.9 (trunk 114183)", isOptimized: true, emissionKind: 1, file: !15, enums: !16, retainedTypes: !16, subprograms: !13, imports: null) !3 = !DISubroutineType(types: !4) diff --git a/test/DebugInfo/X86/dbg-declare-arg.ll b/test/DebugInfo/X86/dbg-declare-arg.ll index 70e1738fdbf..c35bc8c5f62 100644 --- a/test/DebugInfo/X86/dbg-declare-arg.ll +++ b/test/DebugInfo/X86/dbg-declare-arg.ll @@ -7,7 +7,7 @@ target triple = "x86_64-apple-macosx10.6.7" %class.A = type { i32, i32, i32, i32 } -define void @_Z3fooi(%class.A* sret %agg.result, i32 %i) ssp { +define void @_Z3fooi(%class.A* sret %agg.result, i32 %i) ssp !dbg !19 { entry: %i.addr = alloca i32, align 4 %j = alloca i32, align 4 @@ -48,7 +48,7 @@ nrvo.skipdtor: ; preds = %nrvo.unused, %if.en declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone -define linkonce_odr void @_ZN1AD1Ev(%class.A* %this) unnamed_addr ssp align 2 { +define linkonce_odr void @_ZN1AD1Ev(%class.A* %this) unnamed_addr ssp align 2 !dbg !22 { entry: %this.addr = alloca %class.A*, align 8 store %class.A* %this, %class.A** %this.addr, align 8 @@ -58,7 +58,7 @@ entry: ret void, !dbg !45 } -define linkonce_odr void @_ZN1AD2Ev(%class.A* %this) unnamed_addr nounwind ssp align 2 { +define linkonce_odr void @_ZN1AD2Ev(%class.A* %this) unnamed_addr nounwind ssp align 2 !dbg !25 { entry: %this.addr = alloca %class.A*, align 8 store %class.A* %this, %class.A** %this.addr, align 8 @@ -91,13 +91,13 @@ entry: !16 = !{null, !13, !17} !17 = !DIDerivedType(tag: DW_TAG_reference_type, scope: !2, baseType: !18) !18 = !DIDerivedType(tag: DW_TAG_const_type, file: !3, baseType: !1) -!19 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooi", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !51, scope: !3, type: !20, function: void (%class.A*, i32)* @_Z3fooi) +!19 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooi", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !51, scope: !3, type: !20) !20 = !DISubroutineType(types: !21) !21 = !{!1} -!22 = distinct !DISubprogram(name: "~A", linkageName: "_ZN1AD1Ev", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !51, scope: !3, type: !23, function: void (%class.A*)* @_ZN1AD1Ev) +!22 = distinct !DISubprogram(name: "~A", linkageName: "_ZN1AD1Ev", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !51, scope: !3, type: !23) !23 = !DISubroutineType(types: !24) !24 = !{null} -!25 = distinct !DISubprogram(name: "~A", linkageName: "_ZN1AD2Ev", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !51, scope: !3, type: !23, function: void (%class.A*)* @_ZN1AD2Ev) +!25 = distinct !DISubprogram(name: "~A", linkageName: "_ZN1AD2Ev", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !51, scope: !3, type: !23) !26 = !DILocalVariable(name: "i", line: 4, arg: 1, scope: !19, file: !3, type: !6) !27 = !DILocation(line: 4, column: 11, scope: !19) !28 = !DILocalVariable(name: "j", line: 5, scope: !29, file: !3, type: !6) diff --git a/test/DebugInfo/X86/dbg-declare.ll b/test/DebugInfo/X86/dbg-declare.ll index c35d6d200df..1d6cfe85959 100644 --- a/test/DebugInfo/X86/dbg-declare.ll +++ b/test/DebugInfo/X86/dbg-declare.ll @@ -1,7 +1,7 @@ ; RUN: llc < %s -O0 -mtriple x86_64-apple-darwin ; <rdar://problem/11134152> -define i32 @foo(i32* %x) nounwind uwtable ssp { +define i32 @foo(i32* %x) nounwind uwtable ssp !dbg !5 { entry: %x.addr = alloca i32*, align 8 %saved_stack = alloca i8* @@ -33,7 +33,7 @@ declare void @llvm.stackrestore(i8*) nounwind !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.1 (trunk 153698)", isOptimized: false, emissionKind: 0, file: !26, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "foo", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !26, scope: !0, type: !7, function: i32 (i32*)* @foo) +!5 = distinct !DISubprogram(name: "foo", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !26, scope: !0, type: !7) !6 = !DIFile(filename: "20020104-2.c", directory: "/Volumes/Sandbox/llvm") !7 = !DISubroutineType(types: !8) !8 = !{!9, !10} diff --git a/test/DebugInfo/X86/dbg-file-name.ll b/test/DebugInfo/X86/dbg-file-name.ll index edb08685dca..60954b9746b 100644 --- a/test/DebugInfo/X86/dbg-file-name.ll +++ b/test/DebugInfo/X86/dbg-file-name.ll @@ -5,7 +5,7 @@ declare i32 @printf(i8*, ...) nounwind -define i32 @main() nounwind { +define i32 @main() nounwind !dbg !6 { ret i32 0 } @@ -15,7 +15,7 @@ define i32 @main() nounwind { !1 = !DIFile(filename: "simple.c", directory: "/Users/manav/one/two") !2 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "LLVM build 00", isOptimized: true, emissionKind: 0, file: !10, enums: !11, retainedTypes: !11, subprograms: !9) !5 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!6 = distinct !DISubprogram(name: "main", linkageName: "main", line: 9, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !10, scope: !1, type: !7, function: i32 ()* @main) +!6 = distinct !DISubprogram(name: "main", linkageName: "main", line: 9, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !10, scope: !1, type: !7) !7 = !DISubroutineType(types: !8) !8 = !{!5} !9 = !{!6} diff --git a/test/DebugInfo/X86/dbg-i128-const.ll b/test/DebugInfo/X86/dbg-i128-const.ll index f8c6b7c1982..80ea1769b60 100644 --- a/test/DebugInfo/X86/dbg-i128-const.ll +++ b/test/DebugInfo/X86/dbg-i128-const.ll @@ -4,7 +4,7 @@ ; CHECK: DW_AT_const_value ; CHECK-NEXT: 42 -define i128 @__foo(i128 %a, i128 %b) nounwind { +define i128 @__foo(i128 %a, i128 %b) nounwind !dbg !3 { entry: tail call void @llvm.dbg.value(metadata i128 42 , i64 0, metadata !1, metadata !DIExpression()), !dbg !11 %add = add i128 %a, %b, !dbg !11 @@ -19,7 +19,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !0 = !{i128 42 } !1 = !DILocalVariable(name: "MAX", line: 29, scope: !2, file: !4, type: !8) !2 = distinct !DILexicalBlock(line: 26, column: 0, file: !13, scope: !3) -!3 = distinct !DISubprogram(name: "__foo", linkageName: "__foo", line: 26, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 26, file: !13, scope: !4, type: !6, function: i128 (i128, i128)* @__foo) +!3 = distinct !DISubprogram(name: "__foo", linkageName: "__foo", line: 26, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 26, file: !13, scope: !4, type: !6) !4 = !DIFile(filename: "foo.c", directory: "/tmp") !5 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "clang", isOptimized: true, emissionKind: 0, file: !13, enums: !15, retainedTypes: !15, subprograms: !12, imports: null) !6 = !DISubroutineType(types: !7) diff --git a/test/DebugInfo/X86/dbg-merge-loc-entry.ll b/test/DebugInfo/X86/dbg-merge-loc-entry.ll index 708a9e930b0..fc5c1bbd529 100644 --- a/test/DebugInfo/X86/dbg-merge-loc-entry.ll +++ b/test/DebugInfo/X86/dbg-merge-loc-entry.ll @@ -12,7 +12,7 @@ target triple = "x86_64-apple-darwin8" @__clz_tab = external constant [256 x i8] -define hidden i128 @__divti3(i128 %u, i128 %v) nounwind readnone { +define hidden i128 @__divti3(i128 %u, i128 %v) nounwind readnone !dbg !9 { entry: tail call void @llvm.dbg.value(metadata i128 %u, i64 0, metadata !14, metadata !DIExpression()), !dbg !15 tail call void @llvm.dbg.value(metadata i64 0, i64 0, metadata !17, metadata !DIExpression()), !dbg !21 @@ -49,7 +49,7 @@ declare %0 @llvm.uadd.with.overflow.i64(i64, i64) nounwind readnone !6 = !DIFile(filename: "foobar.h", directory: "/tmp") !7 = !DIBasicType(tag: DW_TAG_base_type, size: 128, align: 128, encoding: DW_ATE_unsigned) !8 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, file: !29, scope: !1, baseType: !5) -!9 = distinct !DISubprogram(name: "__divti3", linkageName: "__divti3", line: 1094, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1094, file: !29, scope: !1, type: !10, function: i128 (i128, i128)* @__divti3) +!9 = distinct !DISubprogram(name: "__divti3", linkageName: "__divti3", line: 1094, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1094, file: !29, scope: !1, type: !10) !10 = !DISubroutineType(types: !11) !11 = !{!12, !12, !12} !12 = !DIDerivedType(tag: DW_TAG_typedef, name: "TItype", line: 160, file: !30, scope: !6, baseType: !13) diff --git a/test/DebugInfo/X86/dbg-prolog-end.ll b/test/DebugInfo/X86/dbg-prolog-end.ll index 79df7269e4f..c3802b9bfa5 100644 --- a/test/DebugInfo/X86/dbg-prolog-end.ll +++ b/test/DebugInfo/X86/dbg-prolog-end.ll @@ -3,7 +3,7 @@ target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f3 target triple = "x86_64-apple-macosx10.6.7" ;CHECK: .loc 1 2 11 prologue_end -define i32 @foo(i32 %i) nounwind ssp { +define i32 @foo(i32 %i) nounwind ssp !dbg !1 { entry: %i.addr = alloca i32, align 4 %j = alloca i32, align 4 @@ -24,7 +24,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone -define i32 @main() nounwind ssp { +define i32 @main() nounwind ssp !dbg !6 { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval @@ -37,12 +37,12 @@ entry: !18 = !{!1, !6} !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 (trunk 131100)", isOptimized: false, emissionKind: 0, file: !19, enums: !20, retainedTypes: !20, subprograms: !18, imports: null) -!1 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !19, scope: !2, type: !3, function: i32 (i32)* @foo) +!1 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !19, scope: !2, type: !3) !2 = !DIFile(filename: "/tmp/a.c", directory: "/private/tmp") !3 = !DISubroutineType(types: !4) !4 = !{!5} !5 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!6 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 7, file: !19, scope: !2, type: !3, function: i32 ()* @main) +!6 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 7, file: !19, scope: !2, type: !3) !7 = !DILocalVariable(name: "i", line: 1, arg: 1, scope: !1, file: !2, type: !5) !8 = !DILocation(line: 1, column: 13, scope: !1) !9 = !DILocalVariable(name: "j", line: 2, scope: !10, file: !2, type: !5) diff --git a/test/DebugInfo/X86/dbg-subrange.ll b/test/DebugInfo/X86/dbg-subrange.ll index 6b4ce6af563..5239daea800 100644 --- a/test/DebugInfo/X86/dbg-subrange.ll +++ b/test/DebugInfo/X86/dbg-subrange.ll @@ -6,7 +6,7 @@ target triple = "x86_64-apple-macosx10.7.2" @s = common global [4294967296 x i8] zeroinitializer, align 16 ; CHECK: .quad 4294967296 ## DW_AT_count -define void @bar() nounwind uwtable ssp { +define void @bar() nounwind uwtable ssp !dbg !5 { entry: store i8 97, i8* getelementptr inbounds ([4294967296 x i8], [4294967296 x i8]* @s, i32 0, i64 0), align 1, !dbg !18 ret void, !dbg !20 @@ -18,7 +18,7 @@ entry: !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.1 (trunk 144833)", isOptimized: false, emissionKind: 0, file: !21, enums: !1, retainedTypes: !1, subprograms: !3, globals: !11, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "bar", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !21, scope: !6, type: !7, function: void ()* @bar) +!5 = distinct !DISubprogram(name: "bar", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !21, scope: !6, type: !7) !6 = !DIFile(filename: "small.c", directory: "/private/tmp") !7 = !DISubroutineType(types: !8) !8 = !{null} diff --git a/test/DebugInfo/X86/dbg-value-const-byref.ll b/test/DebugInfo/X86/dbg-value-const-byref.ll index 9a0b3471c29..e231da876b4 100644 --- a/test/DebugInfo/X86/dbg-value-const-byref.ll +++ b/test/DebugInfo/X86/dbg-value-const-byref.ll @@ -47,7 +47,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-apple-macosx10.9.0" ; Function Attrs: nounwind ssp uwtable -define i32 @foo() #0 { +define i32 @foo() #0 !dbg !4 { entry: %i = alloca i32, align 4 call void @llvm.dbg.value(metadata i32 3, i64 0, metadata !10, metadata !DIExpression()), !dbg !15 @@ -82,7 +82,7 @@ attributes #3 = { nounwind } !1 = !DIFile(filename: "dbg-value-const-byref.c", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 5, file: !1, scope: !5, type: !6, function: i32 ()* @foo, variables: !9) +!4 = distinct !DISubprogram(name: "foo", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 5, file: !1, scope: !5, type: !6, variables: !9) !5 = !DIFile(filename: "dbg-value-const-byref.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/DebugInfo/X86/dbg-value-dag-combine.ll b/test/DebugInfo/X86/dbg-value-dag-combine.ll index da79a8173ac..ffbec19fa12 100644 --- a/test/DebugInfo/X86/dbg-value-dag-combine.ll +++ b/test/DebugInfo/X86/dbg-value-dag-combine.ll @@ -6,7 +6,7 @@ target triple = "x86_64-apple-darwin10.0.0" declare <4 x i32> @__amdil_get_global_id_int() declare void @llvm.dbg.value(metadata, i64, metadata, metadata) -define void @__OpenCL_test_kernel(i32 addrspace(1)* %ip) nounwind { +define void @__OpenCL_test_kernel(i32 addrspace(1)* %ip) nounwind !dbg !0 { entry: call void @llvm.dbg.value(metadata i32 addrspace(1)* %ip, i64 0, metadata !7, metadata !DIExpression()), !dbg !8 %0 = call <4 x i32> @__amdil_get_global_id_int() nounwind @@ -24,7 +24,7 @@ entry: !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!20} -!0 = distinct !DISubprogram(name: "__OpenCL_test_kernel", linkageName: "__OpenCL_test_kernel", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !19, scope: !1, type: !3, function: void (i32 addrspace(1)*)* @__OpenCL_test_kernel) +!0 = distinct !DISubprogram(name: "__OpenCL_test_kernel", linkageName: "__OpenCL_test_kernel", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !19, scope: !1, type: !3) !1 = !DIFile(filename: "OCL6368.tmp.cl", directory: "E:CUsersCmvillmow.AMDCAppDataCLocalCTemp") !2 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "clc", isOptimized: false, emissionKind: 1, file: !19, enums: !12, retainedTypes: !12, subprograms: !18, imports: null) !3 = !DISubroutineType(types: !4) diff --git a/test/DebugInfo/X86/dbg-value-inlined-parameter.ll b/test/DebugInfo/X86/dbg-value-inlined-parameter.ll index a77f4e3fc26..7ec21f8cf7c 100644 --- a/test/DebugInfo/X86/dbg-value-inlined-parameter.ll +++ b/test/DebugInfo/X86/dbg-value-inlined-parameter.ll @@ -43,7 +43,7 @@ @p = common global %struct.S1 zeroinitializer, align 8 -define i32 @foo(%struct.S1* nocapture %sp, i32 %nums) nounwind optsize ssp { +define i32 @foo(%struct.S1* nocapture %sp, i32 %nums) nounwind optsize ssp !dbg !0 { entry: tail call void @llvm.dbg.value(metadata %struct.S1* %sp, i64 0, metadata !9, metadata !DIExpression()), !dbg !20 tail call void @llvm.dbg.value(metadata i32 %nums, i64 0, metadata !18, metadata !DIExpression()), !dbg !21 @@ -59,7 +59,7 @@ entry: declare float* @bar(i32) optsize -define void @foobar() nounwind optsize ssp { +define void @foobar() nounwind optsize ssp !dbg !6 { entry: tail call void @llvm.dbg.value(metadata %struct.S1* @p, i64 0, metadata !9, metadata !DIExpression()) nounwind, !dbg !31 tail call void @llvm.dbg.value(metadata i32 1, i64 0, metadata !18, metadata !DIExpression()) nounwind, !dbg !35 @@ -74,13 +74,13 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!43} -!0 = distinct !DISubprogram(name: "foo", line: 8, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 8, file: !1, scope: !1, type: !3, function: i32 (%struct.S1*, i32)* @foo, variables: !41) +!0 = distinct !DISubprogram(name: "foo", line: 8, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 8, file: !1, scope: !1, type: !3, variables: !41) !1 = !DIFile(filename: "nm2.c", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 2.9 (trunk 125693)", isOptimized: true, emissionKind: 1, file: !42, enums: !{}, retainedTypes: !{}, subprograms: !39, globals: !40, imports: !44) !3 = !DISubroutineType(types: !4) !4 = !{!5} !5 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!6 = distinct !DISubprogram(name: "foobar", line: 15, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !1, scope: !1, type: !7, function: void ()* @foobar) +!6 = distinct !DISubprogram(name: "foobar", line: 15, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !1, scope: !1, type: !7) !7 = !DISubroutineType(types: !8) !8 = !{null} !9 = !DILocalVariable(name: "sp", line: 7, arg: 1, scope: !0, file: !1, type: !10) diff --git a/test/DebugInfo/X86/dbg-value-isel.ll b/test/DebugInfo/X86/dbg-value-isel.ll index 0a8e7ba239e..ae76beb8140 100644 --- a/test/DebugInfo/X86/dbg-value-isel.ll +++ b/test/DebugInfo/X86/dbg-value-isel.ll @@ -11,7 +11,7 @@ target triple = "x86_64-apple-darwin10.0.0" @lvgv = internal constant [0 x i8*] zeroinitializer @llvm.global.annotations = appending global [1 x %0] [%0 { i8* bitcast (void (i32 addrspace(1)*)* @__OpenCL_nbt02_kernel to i8*), i8* addrspacecast ([1 x i8] addrspace(2)* @sgv to i8*), i8* addrspacecast ([1 x i8] addrspace(2)* @fgv to i8*), i8* bitcast ([0 x i8*]* @lvgv to i8*), i32 0 }], section "llvm.metadata" -define void @__OpenCL_nbt02_kernel(i32 addrspace(1)* %ip) nounwind { +define void @__OpenCL_nbt02_kernel(i32 addrspace(1)* %ip) nounwind !dbg !0 { entry: call void @llvm.dbg.value(metadata i32 addrspace(1)* %ip, i64 0, metadata !8, metadata !DIExpression()), !dbg !9 %0 = call <4 x i32> @__amdil_get_local_id_int() nounwind @@ -81,7 +81,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!22} -!0 = distinct !DISubprogram(name: "__OpenCL_nbt02_kernel", linkageName: "__OpenCL_nbt02_kernel", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !20, scope: !1, type: !3, function: void (i32 addrspace(1)*)* @__OpenCL_nbt02_kernel) +!0 = distinct !DISubprogram(name: "__OpenCL_nbt02_kernel", linkageName: "__OpenCL_nbt02_kernel", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !20, scope: !1, type: !3) !1 = !DIFile(filename: "OCLlLwTXZ.cl", directory: "/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "clc", isOptimized: false, emissionKind: 1, file: !20, enums: !21, retainedTypes: !21, subprograms: !19, imports: null) !3 = !DISubroutineType(types: !4) diff --git a/test/DebugInfo/X86/dbg-value-location.ll b/test/DebugInfo/X86/dbg-value-location.ll index 6c73f12c08b..df9b4085bf3 100644 --- a/test/DebugInfo/X86/dbg-value-location.ll +++ b/test/DebugInfo/X86/dbg-value-location.ll @@ -16,7 +16,7 @@ target triple = "x86_64-apple-darwin10.0.0" declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone -define i32 @foo(i32 %dev, i64 %cmd, i8* %data, i32 %data2) nounwind optsize ssp { +define i32 @foo(i32 %dev, i64 %cmd, i8* %data, i32 %data2) nounwind optsize ssp !dbg !0 { entry: call void @llvm.dbg.value(metadata i32 %dev, i64 0, metadata !12, metadata !DIExpression()), !dbg !13 %tmp.i = load i32, i32* @dfm, align 4, !dbg !14 @@ -50,15 +50,15 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!29} -!0 = distinct !DISubprogram(name: "foo", line: 19510, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 19510, file: !26, scope: !1, type: !3, function: i32 (i32, i64, i8*, i32)* @foo) +!0 = distinct !DISubprogram(name: "foo", line: 19510, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 19510, file: !26, scope: !1, type: !3) !1 = !DIFile(filename: "/tmp/f.c", directory: "/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 2.9 (trunk 124753)", isOptimized: true, emissionKind: 0, file: !27, enums: !28, retainedTypes: !28, subprograms: !24, imports: null) !3 = !DISubroutineType(types: !4) !4 = !{!5} !5 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!6 = distinct !DISubprogram(name: "bar3", line: 14827, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !26, scope: !1, type: !3, function: i32 (i32)* @bar3) -!7 = distinct !DISubprogram(name: "bar2", line: 15397, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !26, scope: !1, type: !3, function: i32 (i32)* @bar2) -!8 = distinct !DISubprogram(name: "bar", line: 12382, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !26, scope: !1, type: !9, function: i32 (i32, i32*)* @bar) +!6 = distinct !DISubprogram(name: "bar3", line: 14827, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !26, scope: !1, type: !3) +!7 = distinct !DISubprogram(name: "bar2", line: 15397, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !26, scope: !1, type: !3) +!8 = distinct !DISubprogram(name: "bar", line: 12382, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !26, scope: !1, type: !9) !9 = !DISubroutineType(types: !10) !10 = !{!11} !11 = !DIBasicType(tag: DW_TAG_base_type, name: "unsigned char", size: 8, align: 8, encoding: DW_ATE_unsigned_char) diff --git a/test/DebugInfo/X86/dbg-value-range.ll b/test/DebugInfo/X86/dbg-value-range.ll index c927510a473..2bb5e021036 100644 --- a/test/DebugInfo/X86/dbg-value-range.ll +++ b/test/DebugInfo/X86/dbg-value-range.ll @@ -2,7 +2,7 @@ %struct.a = type { i32 } -define i32 @bar(%struct.a* nocapture %b) nounwind ssp { +define i32 @bar(%struct.a* nocapture %b) nounwind ssp !dbg !0 { entry: tail call void @llvm.dbg.value(metadata %struct.a* %b, i64 0, metadata !6, metadata !DIExpression()), !dbg !13 %tmp1 = getelementptr inbounds %struct.a, %struct.a* %b, i64 0, i32 0, !dbg !14 @@ -20,7 +20,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!24} -!0 = distinct !DISubprogram(name: "bar", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !22, scope: !1, type: !3, function: i32 (%struct.a*)* @bar, variables: !21) +!0 = distinct !DISubprogram(name: "bar", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !22, scope: !1, type: !3, variables: !21) !1 = !DIFile(filename: "bar.c", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 2.9 (trunk 122997)", isOptimized: true, emissionKind: 1, file: !22, enums: !23, retainedTypes: !23, subprograms: !20, imports: null) !3 = !DISubroutineType(types: !4) diff --git a/test/DebugInfo/X86/dbg-value-terminator.ll b/test/DebugInfo/X86/dbg-value-terminator.ll index 15aa0ab067e..8b8bdec18ab 100644 --- a/test/DebugInfo/X86/dbg-value-terminator.ll +++ b/test/DebugInfo/X86/dbg-value-terminator.ll @@ -9,7 +9,7 @@ ; CHECK: ##DEBUG_VALUE: foo:i %a = type { i32, i32 } -define hidden fastcc %a* @test() #1 { +define hidden fastcc %a* @test() #1 !dbg !1 { entry: %0 = icmp eq %a* undef, null, !dbg !12 br i1 %0, label %"14", label %return, !dbg !12 @@ -114,7 +114,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.module.flags = !{!22} !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "Apple clang version", isOptimized: true, emissionKind: 1, file: !20, enums: !21, retainedTypes: !21, subprograms: !18, imports: null) -!1 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !20, scope: !2, type: !3, function: %a* ()* @test, variables: !19) +!1 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !20, scope: !2, type: !3, variables: !19) !2 = !DIFile(filename: "a.c", directory: "/private/tmp") !3 = !DISubroutineType(types: !4) !4 = !{!5} diff --git a/test/DebugInfo/X86/dbg_value_direct.ll b/test/DebugInfo/X86/dbg_value_direct.ll index 3f3d922ad08..b7f1ec8ccaa 100644 --- a/test/DebugInfo/X86/dbg_value_direct.ll +++ b/test/DebugInfo/X86/dbg_value_direct.ll @@ -23,7 +23,7 @@ target triple = "x86_64-unknown-linux-gnu" @__asan_gen_ = private unnamed_addr constant [16 x i8] c"1 32 4 5 .addr \00", align 1 ; Function Attrs: sanitize_address uwtable -define void @_Z4funci(%struct.A* noalias sret %agg.result, i32) #0 "stack-protector-buffer-size"="1" { +define void @_Z4funci(%struct.A* noalias sret %agg.result, i32) #0 "stack-protector-buffer-size"="1" !dbg !4 { entry: %MyAlloca = alloca [96 x i8], align 32 %1 = ptrtoint [96 x i8]* %MyAlloca to i64 @@ -151,7 +151,7 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !1 = !DIFile(filename: "crash.cpp", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "func", linkageName: "_Z4funci", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: !5, type: !6, function: void (%struct.A*, i32)* @_Z4funci, variables: !2) +!4 = distinct !DISubprogram(name: "func", linkageName: "_Z4funci", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "crash.cpp", directory: "/tmp") !6 = !DISubroutineType(types: !7) !7 = !{!8, !21} diff --git a/test/DebugInfo/X86/debug-dead-local-var.ll b/test/DebugInfo/X86/debug-dead-local-var.ll index 0572a7bc4a5..9a2872aeb0a 100644 --- a/test/DebugInfo/X86/debug-dead-local-var.ll +++ b/test/DebugInfo/X86/debug-dead-local-var.ll @@ -16,7 +16,7 @@ ; CHECK: DW_TAG_structure_type ; Function Attrs: nounwind readnone uwtable -define i32 @bar() #0 { +define i32 @bar() #0 !dbg !4 { entry: ret i32 1, !dbg !21 } @@ -31,7 +31,7 @@ attributes #0 = { nounwind readnone uwtable "less-precise-fpmad"="false" "no-fra !1 = !DIFile(filename: "debug-dead-local-var.c", directory: "/usr/local/google/home/echristo") !2 = !{} !3 = !{!4, !9} -!4 = distinct !DISubprogram(name: "bar", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 11, file: !1, scope: !5, type: !6, function: i32 ()* @bar, variables: !2) +!4 = distinct !DISubprogram(name: "bar", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 11, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "debug-dead-local-var.c", directory: "/usr/local/google/home/echristo") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/DebugInfo/X86/debug-info-access.ll b/test/DebugInfo/X86/debug-info-access.ll index f71ec0f2a7c..c9a50395c71 100644 --- a/test/DebugInfo/X86/debug-info-access.ll +++ b/test/DebugInfo/X86/debug-info-access.ll @@ -96,7 +96,7 @@ target triple = "x86_64-apple-macosx10.10.0" @u = global %union.U zeroinitializer, align 4 ; Function Attrs: nounwind ssp uwtable -define void @_Z4freev() #0 { +define void @_Z4freev() #0 !dbg !30 { ret void, !dbg !41 } @@ -136,7 +136,7 @@ attributes #0 = { nounwind ssp uwtable } !27 = !{null, !28} !28 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS1U") !29 = !{!30} -!30 = distinct !DISubprogram(name: "free", linkageName: "_Z4freev", line: 35, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 35, file: !1, scope: !31, type: !32, function: void ()* @_Z4freev, variables: !2) +!30 = distinct !DISubprogram(name: "free", linkageName: "_Z4freev", line: 35, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 35, file: !1, scope: !31, type: !32, variables: !2) !31 = !DIFile(filename: "/llvm/tools/clang/test/CodeGenCXX/debug-info-access.cpp", directory: "") !32 = !DISubroutineType(types: !33) !33 = !{null} diff --git a/test/DebugInfo/X86/debug-info-block-captured-self.ll b/test/DebugInfo/X86/debug-info-block-captured-self.ll index 406f70a6c59..1c3dc24b324 100644 --- a/test/DebugInfo/X86/debug-info-block-captured-self.ll +++ b/test/DebugInfo/X86/debug-info-block-captured-self.ll @@ -64,14 +64,14 @@ %0 = type opaque %struct.__block_descriptor = type { i64, i64 } declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 -define internal void @"__24-[Main initWithContext:]_block_invoke"(i8* %.block_descriptor, i8* %obj) #0 { +define internal void @"__24-[Main initWithContext:]_block_invoke"(i8* %.block_descriptor, i8* %obj) #0 !dbg !38 { %block = bitcast i8* %.block_descriptor to <{ i8*, i32, i32, i8*, %struct.__block_descriptor*, %0* }>*, !dbg !84 %block.captured-self = getelementptr inbounds <{ i8*, i32, i32, i8*, %struct.__block_descriptor*, %0* }>, <{ i8*, i32, i32, i8*, %struct.__block_descriptor*, %0* }>* %block, i32 0, i32 5, !dbg !84 call void @llvm.dbg.declare(metadata <{ i8*, i32, i32, i8*, %struct.__block_descriptor*, %0* }>* %block, metadata !86, metadata !110), !dbg !87 ret void, !dbg !87 } -define internal void @"__24-[Main initWithContext:]_block_invoke_2"(i8* %.block_descriptor, i8* %object) #0 { +define internal void @"__24-[Main initWithContext:]_block_invoke_2"(i8* %.block_descriptor, i8* %object) #0 !dbg !42 { %block = bitcast i8* %.block_descriptor to <{ i8*, i32, i32, i8*, %struct.__block_descriptor*, %0* }>*, !dbg !103 %block.captured-self = getelementptr inbounds <{ i8*, i32, i32, i8*, %struct.__block_descriptor*, %0* }>, <{ i8*, i32, i32, i8*, %struct.__block_descriptor*, %0* }>* %block, i32 0, i32 5, !dbg !103 call void @llvm.dbg.declare(metadata <{ i8*, i32, i32, i8*, %struct.__block_descriptor*, %0* }>* %block, metadata !105, metadata !109), !dbg !106 @@ -95,11 +95,11 @@ define internal void @"__24-[Main initWithContext:]_block_invoke_2"(i8* %.block_ !32 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, baseType: !33) !33 = !DICompositeType(tag: DW_TAG_structure_type, name: "objc_class", flags: DIFlagFwdDecl, file: !107) !34 = !DICompositeType(tag: DW_TAG_structure_type, name: "Main", line: 23, flags: DIFlagArtificial | DIFlagObjectPointer, runtimeLang: DW_LANG_ObjC, file: !107) -!38 = distinct !DISubprogram(name: "__24-[Main initWithContext:]_block_invoke", line: 33, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 33, file: !1, scope: !1, type: !39, function: void (i8*, i8*)* @"__24-[Main initWithContext:]_block_invoke", variables: !15) +!38 = distinct !DISubprogram(name: "__24-[Main initWithContext:]_block_invoke", line: 33, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 33, file: !1, scope: !1, type: !39, variables: !15) !39 = !DISubroutineType(types: !40) !40 = !{null, !41, !27} !41 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: null) -!42 = distinct !DISubprogram(name: "__24-[Main initWithContext:]_block_invoke_2", line: 35, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 35, file: !1, scope: !1, type: !39, function: void (i8*, i8*)* @"__24-[Main initWithContext:]_block_invoke_2", variables: !15) +!42 = distinct !DISubprogram(name: "__24-[Main initWithContext:]_block_invoke_2", line: 35, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 35, file: !1, scope: !1, type: !39, variables: !15) !84 = !DILocation(line: 33, scope: !38) !86 = !DILocalVariable(name: "self", line: 41, scope: !38, file: !1, type: !34) !87 = !DILocation(line: 41, scope: !38) diff --git a/test/DebugInfo/X86/debug-info-blocks.ll b/test/DebugInfo/X86/debug-info-blocks.ll index 7a404719a28..8a929491f28 100644 --- a/test/DebugInfo/X86/debug-info-blocks.ll +++ b/test/DebugInfo/X86/debug-info-blocks.ll @@ -95,7 +95,7 @@ target triple = "x86_64-apple-darwin" @"\01L_OBJC_LABEL_CLASS_$" = internal global [1 x i8*] [i8* bitcast (%struct._class_t* @"OBJC_CLASS_$_A" to i8*)], section "__DATA, __objc_classlist, regular, no_dead_strip", align 8 @llvm.used = appending global [14 x i8*] [i8* bitcast (%struct._class_t** @"\01L_OBJC_CLASSLIST_SUP_REFS_$_" to i8*), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @"\01L_OBJC_METH_VAR_NAME_", i32 0, i32 0), i8* bitcast (i8** @"\01L_OBJC_SELECTOR_REFERENCES_" to i8*), i8* bitcast (%struct._class_t** @"\01L_OBJC_CLASSLIST_REFERENCES_$_" to i8*), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @"\01L_OBJC_METH_VAR_NAME_1", i32 0, i32 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @"\01L_OBJC_METH_VAR_NAME_2", i32 0, i32 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @"\01L_OBJC_CLASS_NAME_", i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @"\01L_OBJC_METH_VAR_TYPE_", i32 0, i32 0), i8* bitcast ({ i32, i32, [1 x %struct._objc_method] }* @"\01l_OBJC_$_INSTANCE_METHODS_A" to i8*), i8* getelementptr inbounds ([5 x i8], [5 x i8]* @"\01L_OBJC_METH_VAR_NAME_3", i32 0, i32 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @"\01L_OBJC_METH_VAR_TYPE_4", i32 0, i32 0), i8* bitcast ({ i32, i32, [1 x %struct._ivar_t] }* @"\01l_OBJC_$_INSTANCE_VARIABLES_A" to i8*), i8* bitcast (%struct._class_t** @"\01L_OBJC_CLASSLIST_REFERENCES_$_5" to i8*), i8* bitcast ([1 x i8*]* @"\01L_OBJC_LABEL_CLASS_$" to i8*)], section "llvm.metadata" -define internal i8* @"\01-[A init]"(%0* %self, i8* %_cmd) #0 { +define internal i8* @"\01-[A init]"(%0* %self, i8* %_cmd) #0 !dbg !13 { %1 = alloca %0*, align 8 %2 = alloca i8*, align 8 %3 = alloca %struct._objc_super @@ -147,7 +147,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 declare i8* @objc_msgSendSuper2(%struct._objc_super*, i8*, ...) -define internal void @run(void ()* %block) #0 { +define internal void @run(void ()* %block) #0 !dbg !39 { %1 = alloca void ()*, align 8 store void ()* %block, void ()** %1, align 8 call void @llvm.dbg.declare(metadata void ()** %1, metadata !72, metadata !DIExpression()), !dbg !73 @@ -161,7 +161,7 @@ define internal void @run(void ()* %block) #0 { ret void, !dbg !75 } -define internal void @"__9-[A init]_block_invoke"(i8* %.block_descriptor) #0 { +define internal void @"__9-[A init]_block_invoke"(i8* %.block_descriptor) #0 !dbg !27 { %1 = alloca i8*, align 8 %2 = alloca <{ i8*, i32, i32, i8*, %struct.__block_descriptor*, %0* }>*, align 8 %d = alloca %1*, align 8 @@ -206,7 +206,7 @@ declare i8* @objc_msgSend_fixup(i8*, %struct._message_ref_t*, ...) declare i8* @objc_msgSend(i8*, i8*, ...) #2 -define internal void @__copy_helper_block_(i8*, i8*) { +define internal void @__copy_helper_block_(i8*, i8*) !dbg !31 { %3 = alloca i8*, align 8 %4 = alloca i8*, align 8 store i8* %0, i8** %3, align 8 @@ -228,7 +228,7 @@ define internal void @__copy_helper_block_(i8*, i8*) { declare void @_Block_object_assign(i8*, i8*, i32) -define internal void @__destroy_helper_block_(i8*) { +define internal void @__destroy_helper_block_(i8*) !dbg !35 { %2 = alloca i8*, align 8 store i8* %0, i8** %2, align 8 call void @llvm.dbg.declare(metadata i8** %2, metadata !105, metadata !DIExpression()), !dbg !106 @@ -243,7 +243,7 @@ define internal void @__destroy_helper_block_(i8*) { declare void @_Block_object_dispose(i8*, i32) -define i32 @main() #0 { +define i32 @main() #0 !dbg !36 { %1 = alloca i32, align 4 %a = alloca %0*, align 8 store i32 0, i32* %1 @@ -283,7 +283,7 @@ attributes #3 = { nounwind } !10 = !DIDerivedType(tag: DW_TAG_member, name: "ivar", line: 35, size: 32, align: 32, file: !5, scope: !6, baseType: !11) !11 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !12 = !{!13, !27, !31, !35, !36, !39} -!13 = distinct !DISubprogram(name: "-[A init]", line: 46, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 46, file: !5, scope: !6, type: !14, function: i8* (%0*, i8*)* @"\01-[A init]", variables: !2) +!13 = distinct !DISubprogram(name: "-[A init]", line: 46, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 46, file: !5, scope: !6, type: !14, variables: !2) !14 = !DISubroutineType(types: !15) !15 = !{!16, !23, !24} !16 = !DIDerivedType(tag: DW_TAG_typedef, name: "id", line: 46, file: !5, baseType: !17) @@ -297,19 +297,19 @@ attributes #3 = { nounwind } !24 = !DIDerivedType(tag: DW_TAG_typedef, name: "SEL", line: 46, flags: DIFlagArtificial, file: !5, baseType: !25) !25 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !26) !26 = !DICompositeType(tag: DW_TAG_structure_type, name: "objc_selector", flags: DIFlagFwdDecl, file: !1) -!27 = distinct !DISubprogram(name: "__9-[A init]_block_invoke", line: 49, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 49, file: !5, scope: !6, type: !28, function: void (i8*)* @"__9-[A init]_block_invoke", variables: !2) +!27 = distinct !DISubprogram(name: "__9-[A init]_block_invoke", line: 49, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 49, file: !5, scope: !6, type: !28, variables: !2) !28 = !DISubroutineType(types: !29) !29 = !{null, !30} !30 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: null) -!31 = distinct !DISubprogram(name: "__copy_helper_block_", line: 52, isLocal: true, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 52, file: !1, scope: !32, type: !33, function: void (i8*, i8*)* @__copy_helper_block_, variables: !2) +!31 = distinct !DISubprogram(name: "__copy_helper_block_", line: 52, isLocal: true, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 52, file: !1, scope: !32, type: !33, variables: !2) !32 = !DIFile(filename: "llvm/tools/clang/test/CodeGenObjC/<unknown>", directory: "llvm/_build.ninja.Debug") !33 = !DISubroutineType(types: !34) !34 = !{null, !30, !30} -!35 = distinct !DISubprogram(name: "__destroy_helper_block_", line: 52, isLocal: true, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 52, file: !1, scope: !32, type: !28, function: void (i8*)* @__destroy_helper_block_, variables: !2) -!36 = distinct !DISubprogram(name: "main", line: 59, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 60, file: !5, scope: !6, type: !37, function: i32 ()* @main, variables: !2) +!35 = distinct !DISubprogram(name: "__destroy_helper_block_", line: 52, isLocal: true, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 52, file: !1, scope: !32, type: !28, variables: !2) +!36 = distinct !DISubprogram(name: "main", line: 59, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 60, file: !5, scope: !6, type: !37, variables: !2) !37 = !DISubroutineType(types: !38) !38 = !{!11} -!39 = distinct !DISubprogram(name: "run", line: 39, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 40, file: !5, scope: !6, type: !40, function: void (void ()*)* @run, variables: !2) +!39 = distinct !DISubprogram(name: "run", line: 39, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 40, file: !5, scope: !6, type: !40, variables: !2) !40 = !DISubroutineType(types: !41) !41 = !{null, !42} !42 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, baseType: !43) diff --git a/test/DebugInfo/X86/debug-info-static-member.ll b/test/DebugInfo/X86/debug-info-static-member.ll index 7797d01ad78..a42279b0a4a 100644 --- a/test/DebugInfo/X86/debug-info-static-member.ll +++ b/test/DebugInfo/X86/debug-info-static-member.ll @@ -42,7 +42,7 @@ @_ZN1C1bE = global i32 2, align 4 @_ZN1C1cE = global i32 1, align 4 -define i32 @main() nounwind uwtable { +define i32 @main() nounwind uwtable !dbg !5 { entry: %retval = alloca i32, align 4 %instance_C = alloca %class.C, align 4 @@ -62,7 +62,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.3 (trunk 171914)", isOptimized: false, emissionKind: 0, file: !33, enums: !1, retainedTypes: !1, subprograms: !3, globals: !10, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "main", line: 18, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 23, file: !33, scope: !6, type: !7, function: i32 ()* @main, variables: !1) +!5 = distinct !DISubprogram(name: "main", line: 18, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 23, file: !33, scope: !6, type: !7, variables: !1) !6 = !DIFile(filename: "/usr/local/google/home/blaikie/Development/llvm/src/tools/clang/test/CodeGenCXX/debug-info-static-member.cpp", directory: "/home/blaikie/local/Development/llvm/build/clang/x86-64/Debug/llvm") !7 = !DISubroutineType(types: !8) !8 = !{!9} diff --git a/test/DebugInfo/X86/debug-loc-asan.ll b/test/DebugInfo/X86/debug-loc-asan.ll index a40a90dafbc..7f25f015a34 100644 --- a/test/DebugInfo/X86/debug-loc-asan.ll +++ b/test/DebugInfo/X86/debug-loc-asan.ll @@ -42,7 +42,7 @@ target triple = "x86_64-unknown-linux-gnu" @__asan_gen_ = private unnamed_addr constant [16 x i8] c"1 32 4 6 y.addr\00", align 1 ; Function Attrs: nounwind sanitize_address uwtable -define i32 @_Z3bari(i32 %y) #0 { +define i32 @_Z3bari(i32 %y) #0 !dbg !4 { entry: %MyAlloca = alloca [64 x i8], align 32 %0 = ptrtoint [64 x i8]* %MyAlloca to i64 @@ -169,7 +169,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "test.cc", directory: "/llvm_cmake_gcc") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "bar", linkageName: "_Z3bari", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 (i32)* @_Z3bari, variables: !2) +!4 = distinct !DISubprogram(name: "bar", linkageName: "_Z3bari", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "test.cc", directory: "/llvm_cmake_gcc") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} diff --git a/test/DebugInfo/X86/debug-loc-empty-entries.ll b/test/DebugInfo/X86/debug-loc-empty-entries.ll index 586b944c965..776bdbddfb0 100644 --- a/test/DebugInfo/X86/debug-loc-empty-entries.ll +++ b/test/DebugInfo/X86/debug-loc-empty-entries.ll @@ -24,7 +24,7 @@ ;; } ; Function Attrs: noreturn nounwind readnone -define void @_Z3fn1v() #0 { +define void @_Z3fn1v() #0 !dbg !4 { entry: tail call void @llvm.dbg.value(metadata float 1.000000e+00, i64 0, metadata !9, metadata !14), !dbg !15 br label %for.cond, !dbg !16 @@ -48,7 +48,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "<stdin>", directory: "/Users/dexonsmith/data/llvm/bootstrap/play/delta2/testcase") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "fn1", linkageName: "_Z3fn1v", scope: !5, file: !5, line: 1, type: !6, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: true, function: void ()* @_Z3fn1v, variables: !8) +!4 = distinct !DISubprogram(name: "fn1", linkageName: "_Z3fn1v", scope: !5, file: !5, line: 1, type: !6, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: true, variables: !8) !5 = !DIFile(filename: "t.cpp", directory: "/Users/dexonsmith/data/llvm/bootstrap/play/delta2/testcase") !6 = !DISubroutineType(types: !7) !7 = !{null} diff --git a/test/DebugInfo/X86/debug-loc-offset.ll b/test/DebugInfo/X86/debug-loc-offset.ll index 36a1f06cd84..d6302a1e424 100644 --- a/test/DebugInfo/X86/debug-loc-offset.ll +++ b/test/DebugInfo/X86/debug-loc-offset.ll @@ -60,7 +60,7 @@ %struct.A = type { i32 (...)**, i32 } ; Function Attrs: nounwind -define i32 @_Z3bari(i32 %b) #0 { +define i32 @_Z3bari(i32 %b) #0 !dbg !4 { entry: %b.addr = alloca i32, align 4 store i32 %b, i32* %b.addr, align 4 @@ -73,7 +73,7 @@ entry: ; Function Attrs: nounwind readnone declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 -define void @_Z3baz1A(%struct.A* %a) #2 { +define void @_Z3baz1A(%struct.A* %a) #2 !dbg !14 { entry: %z = alloca i32, align 4 call void @llvm.dbg.declare(metadata %struct.A* %a, metadata !24, metadata !DIExpression(DW_OP_deref)), !dbg !25 @@ -120,7 +120,7 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !1 = !DIFile(filename: "debug-loc-offset1.cc", directory: "/llvm_cmake_gcc") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "bar", linkageName: "_Z3bari", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 (i32)* @_Z3bari, variables: !2) +!4 = distinct !DISubprogram(name: "bar", linkageName: "_Z3bari", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "debug-loc-offset1.cc", directory: "/llvm_cmake_gcc") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} @@ -130,7 +130,7 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !11 = !{!12} !12 = !DICompositeType(tag: DW_TAG_structure_type, name: "A", line: 1, flags: DIFlagFwdDecl, file: !10, identifier: "_ZTS1A") !13 = !{!14} -!14 = distinct !DISubprogram(name: "baz", linkageName: "_Z3baz1A", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !10, scope: !15, type: !16, function: void (%struct.A*)* @_Z3baz1A, variables: !2) +!14 = distinct !DISubprogram(name: "baz", linkageName: "_Z3baz1A", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !10, scope: !15, type: !16, variables: !2) !15 = !DIFile(filename: "debug-loc-offset2.cc", directory: "/llvm_cmake_gcc") !16 = !DISubroutineType(types: !17) !17 = !{null, !12} diff --git a/test/DebugInfo/X86/debug-ranges-offset.ll b/test/DebugInfo/X86/debug-ranges-offset.ll index f1b9b22a655..520f3c45e18 100644 --- a/test/DebugInfo/X86/debug-ranges-offset.ll +++ b/test/DebugInfo/X86/debug-ranges-offset.ll @@ -19,7 +19,7 @@ @_end = external hidden global i32 ; Function Attrs: sanitize_memory uwtable -define void @_Z1fv() #0 { +define void @_Z1fv() #0 !dbg !4 { entry: %p = alloca i32*, align 8 %0 = ptrtoint i32** %p to i64, !dbg !19 @@ -82,7 +82,7 @@ if.end: ; preds = %16, %if.then declare i8* @_Znwm(i64) #1 ; Function Attrs: sanitize_memory uwtable -define i32 @main() #0 { +define i32 @main() #0 !dbg !13 { entry: %p.i = alloca i32*, align 8 %0 = ptrtoint i32** %p.i to i64, !dbg !30 @@ -206,7 +206,7 @@ attributes #4 = { builtin } !1 = !DIFile(filename: "foo.cpp", directory: "/usr/local/google/home/echristo/tmp") !2 = !{} !3 = !{!4, !13} -!4 = distinct !DISubprogram(name: "f", linkageName: "_Z1fv", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !5, type: !6, function: void ()* @_Z1fv, variables: !8) +!4 = distinct !DISubprogram(name: "f", linkageName: "_Z1fv", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !8) !5 = !DIFile(filename: "foo.cpp", directory: "/usr/local/google/home/echristo/tmp") !6 = !DISubroutineType(types: !7) !7 = !{null} @@ -215,7 +215,7 @@ attributes #4 = { builtin } !10 = !DIDerivedType(tag: DW_TAG_volatile_type, baseType: !11) !11 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !12) !12 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!13 = distinct !DISubprogram(name: "main", line: 9, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 9, file: !1, scope: !5, type: !14, function: i32 ()* @main, variables: !2) +!13 = distinct !DISubprogram(name: "main", line: 9, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 9, file: !1, scope: !5, type: !14, variables: !2) !14 = !DISubroutineType(types: !15) !15 = !{!12} !16 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/DebugInfo/X86/debug_frame.ll b/test/DebugInfo/X86/debug_frame.ll index e616714aace..563406ccaf9 100644 --- a/test/DebugInfo/X86/debug_frame.ll +++ b/test/DebugInfo/X86/debug_frame.ll @@ -4,7 +4,7 @@ ; CHECK: .cfi_sections .debug_frame -define void @f() nounwind { +define void @f() nounwind !dbg !0 { entry: ret void } @@ -13,7 +13,7 @@ entry: !llvm.module.flags = !{!7} !5 = !{!0} -!0 = distinct !DISubprogram(name: "f", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !6, scope: !1, type: !3, function: void ()* @f) +!0 = distinct !DISubprogram(name: "f", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !6, scope: !1, type: !3) !1 = !DIFile(filename: "/home/espindola/llvm/test.c", directory: "/home/espindola/llvm/build") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 ()", isOptimized: true, emissionKind: 0, file: !6, enums: !{}, retainedTypes: !{}, subprograms: !5) !3 = !DISubroutineType(types: !4) diff --git a/test/DebugInfo/X86/decl-derived-member.ll b/test/DebugInfo/X86/decl-derived-member.ll index 6d643dd5b59..5751f243521 100644 --- a/test/DebugInfo/X86/decl-derived-member.ll +++ b/test/DebugInfo/X86/decl-derived-member.ll @@ -33,7 +33,7 @@ $_ZN4baseC2Ev = comdat any @_ZTV4base = external unnamed_addr constant [4 x i8*] @llvm.global_ctors = appending global [1 x { i32, void ()*, i8* }] [{ i32, void ()*, i8* } { i32 65535, void ()* @_GLOBAL__sub_I_decl_derived_member.cpp, i8* null }] -define internal void @__cxx_global_var_init() section ".text.startup" { +define internal void @__cxx_global_var_init() section ".text.startup" !dbg !10 { entry: call void @_ZN3fooC2Ev(%struct.foo* @f) #2, !dbg !33 %0 = call i32 @__cxa_atexit(void (i8*)* bitcast (void (%struct.foo*)* @_ZN3fooD2Ev to void (i8*)*), i8* bitcast (%struct.foo* @f to i8*), i8* @__dso_handle) #2, !dbg !33 @@ -41,7 +41,7 @@ entry: } ; Function Attrs: inlinehint nounwind uwtable -define linkonce_odr void @_ZN3fooC2Ev(%struct.foo* %this) unnamed_addr #0 comdat align 2 { +define linkonce_odr void @_ZN3fooC2Ev(%struct.foo* %this) unnamed_addr #0 comdat align 2 !dbg !14 { entry: %this.addr = alloca %struct.foo*, align 8 store %struct.foo* %this, %struct.foo** %this.addr, align 8 @@ -53,7 +53,7 @@ entry: } ; Function Attrs: inlinehint uwtable -define linkonce_odr void @_ZN3fooD2Ev(%struct.foo* %this) unnamed_addr #1 comdat align 2 { +define linkonce_odr void @_ZN3fooD2Ev(%struct.foo* %this) unnamed_addr #1 comdat align 2 !dbg !24 { entry: %this.addr = alloca %struct.foo*, align 8 store %struct.foo* %this, %struct.foo** %this.addr, align 8 @@ -71,7 +71,7 @@ declare i32 @__cxa_atexit(void (i8*)*, i8*, i8*) #2 declare void @llvm.dbg.declare(metadata, metadata, metadata) #3 ; Function Attrs: inlinehint nounwind uwtable -define linkonce_odr void @_ZN4baseC2Ev(%struct.base* %this) unnamed_addr #0 comdat align 2 { +define linkonce_odr void @_ZN4baseC2Ev(%struct.base* %this) unnamed_addr #0 comdat align 2 !dbg !19 { entry: %this.addr = alloca %struct.base*, align 8 store %struct.base* %this, %struct.base** %this.addr, align 8 @@ -110,23 +110,23 @@ attributes #4 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !7 = !DIDerivedType(tag: DW_TAG_typedef, name: "base_type", line: 4, file: !1, baseType: !"_ZTS4base") !8 = !DICompositeType(tag: DW_TAG_structure_type, name: "base", line: 1, flags: DIFlagFwdDecl, file: !1, identifier: "_ZTS4base") !9 = !{!10, !14, !19, !24, !26} -!10 = distinct !DISubprogram(name: "__cxx_global_var_init", line: 8, isLocal: true, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 8, file: !1, scope: !11, type: !12, function: void ()* @__cxx_global_var_init, variables: !2) +!10 = distinct !DISubprogram(name: "__cxx_global_var_init", line: 8, isLocal: true, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 8, file: !1, scope: !11, type: !12, variables: !2) !11 = !DIFile(filename: "decl-derived-member.cpp", directory: "/tmp/dbginfo") !12 = !DISubroutineType(types: !13) !13 = !{null} -!14 = distinct !DISubprogram(name: "foo", linkageName: "_ZN3fooC2Ev", line: 5, isLocal: false, isDefinition: true, flags: DIFlagArtificial | DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !"_ZTS3foo", type: !15, function: void (%struct.foo*)* @_ZN3fooC2Ev, declaration: !18, variables: !2) +!14 = distinct !DISubprogram(name: "foo", linkageName: "_ZN3fooC2Ev", line: 5, isLocal: false, isDefinition: true, flags: DIFlagArtificial | DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !"_ZTS3foo", type: !15, declaration: !18, variables: !2) !15 = !DISubroutineType(types: !16) !16 = !{null, !17} !17 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS3foo") !18 = !DISubprogram(name: "foo", isLocal: false, isDefinition: false, flags: DIFlagArtificial | DIFlagPrototyped, isOptimized: false, scope: !"_ZTS3foo", type: !15) -!19 = distinct !DISubprogram(name: "base", linkageName: "_ZN4baseC2Ev", line: 1, isLocal: false, isDefinition: true, flags: DIFlagArtificial | DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !"_ZTS4base", type: !20, function: void (%struct.base*)* @_ZN4baseC2Ev, declaration: !23, variables: !2) +!19 = distinct !DISubprogram(name: "base", linkageName: "_ZN4baseC2Ev", line: 1, isLocal: false, isDefinition: true, flags: DIFlagArtificial | DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !"_ZTS4base", type: !20, declaration: !23, variables: !2) !20 = !DISubroutineType(types: !21) !21 = !{null, !22} !22 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS4base") !23 = !DISubprogram(name: "base", isLocal: false, isDefinition: false, flags: DIFlagArtificial | DIFlagPrototyped, isOptimized: false, scope: !"_ZTS4base", type: !20) -!24 = distinct !DISubprogram(name: "~foo", linkageName: "_ZN3fooD2Ev", line: 5, isLocal: false, isDefinition: true, flags: DIFlagArtificial | DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !"_ZTS3foo", type: !15, function: void (%struct.foo*)* @_ZN3fooD2Ev, declaration: !25, variables: !2) +!24 = distinct !DISubprogram(name: "~foo", linkageName: "_ZN3fooD2Ev", line: 5, isLocal: false, isDefinition: true, flags: DIFlagArtificial | DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !"_ZTS3foo", type: !15, declaration: !25, variables: !2) !25 = !DISubprogram(name: "~foo", isLocal: false, isDefinition: false, flags: DIFlagArtificial | DIFlagPrototyped, isOptimized: false, scope: !"_ZTS3foo", type: !15) -!26 = distinct !DISubprogram(name: "", linkageName: "_GLOBAL__sub_I_decl_derived_member.cpp", isLocal: true, isDefinition: true, flags: DIFlagArtificial, isOptimized: false, file: !1, scope: !11, type: !27, function: void ()* @_GLOBAL__sub_I_decl_derived_member.cpp, variables: !2) +!26 = distinct !DISubprogram(name: "", linkageName: "_GLOBAL__sub_I_decl_derived_member.cpp", isLocal: true, isDefinition: true, flags: DIFlagArtificial, isOptimized: false, file: !1, scope: !11, type: !27, variables: !2) !27 = !DISubroutineType(types: !2) !28 = !{!29} !29 = !DIGlobalVariable(name: "f", line: 8, isLocal: false, isDefinition: true, scope: null, file: !11, type: !"_ZTS3foo", variable: %struct.foo* @f) diff --git a/test/DebugInfo/X86/deleted-bit-piece.ll b/test/DebugInfo/X86/deleted-bit-piece.ll index 2abc0547a44..b069cf8e399 100644 --- a/test/DebugInfo/X86/deleted-bit-piece.ll +++ b/test/DebugInfo/X86/deleted-bit-piece.ll @@ -9,7 +9,7 @@ target triple = "x86_64-apple-macosx10.8.0" ; CHECK: __Z3foov: ; CHECK: retq -define void @_Z3foov() { +define void @_Z3foov() !dbg !12 { entry: br i1 undef, label %exit, label %bb @@ -38,7 +38,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) !9 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !10 = !DIDerivedType(tag: DW_TAG_member, name: "b", scope: !"_ZT5Class", baseType: !9, size: 32, align: 32) !11 = !{!12} -!12 = distinct !DISubprogram(name: "foo", scope: null, file: !3, type: !13, isLocal: false, isDefinition: true, isOptimized: false, function: void ()* @_Z3foov) +!12 = distinct !DISubprogram(name: "foo", scope: null, file: !3, type: !13, isLocal: false, isDefinition: true, isOptimized: false) !13 = !DISubroutineType(types: !14) !14 = !{null} !15 = !DILocalVariable(name: "v", scope: !12, type: !"_ZT5Class") diff --git a/test/DebugInfo/X86/discriminator.ll b/test/DebugInfo/X86/discriminator.ll index ced03f035fc..e9d8fa58c60 100644 --- a/test/DebugInfo/X86/discriminator.ll +++ b/test/DebugInfo/X86/discriminator.ll @@ -11,7 +11,7 @@ ; Manually generated debug nodes !14 and !15 to incorporate an ; arbitrary discriminator with value 42. -define i32 @foo(i32 %i) #0 { +define i32 @foo(i32 %i) #0 !dbg !4 { entry: %retval = alloca i32, align 4 %i.addr = alloca i32, align 4 @@ -45,7 +45,7 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe !1 = !DIFile(filename: "discriminator.c", directory: ".") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "discriminator.c", directory: ".") !6 = !DISubroutineType(types: !2) !7 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/DebugInfo/X86/dw_op_minus.ll b/test/DebugInfo/X86/dw_op_minus.ll index f1760b56c49..1c486e06c51 100644 --- a/test/DebugInfo/X86/dw_op_minus.ll +++ b/test/DebugInfo/X86/dw_op_minus.ll @@ -17,7 +17,7 @@ target triple = "x86_64-unknown-linux-gnu" @__safestack_unsafe_stack_ptr = external thread_local(initialexec) global i8* -define void @f() { +define void @f() !dbg !4 { entry: %unsafe_stack_ptr = load i8*, i8** @__safestack_unsafe_stack_ptr %unsafe_stack_static_top = getelementptr i8, i8* %unsafe_stack_ptr, i32 -400 @@ -44,7 +44,7 @@ declare void @Capture(i32*) !1 = !DIFile(filename: "1.cc", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f", scope: !1, file: !1, line: 4, type: !5, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: true, function: void ()* @f, variables: !7) +!4 = distinct !DISubprogram(name: "f", scope: !1, file: !1, line: 4, type: !5, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: true, variables: !7) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = !{!8} diff --git a/test/DebugInfo/X86/dwarf-aranges-no-dwarf-labels.ll b/test/DebugInfo/X86/dwarf-aranges-no-dwarf-labels.ll index 5cf3c8dc7c6..be0d89433e7 100644 --- a/test/DebugInfo/X86/dwarf-aranges-no-dwarf-labels.ll +++ b/test/DebugInfo/X86/dwarf-aranges-no-dwarf-labels.ll @@ -26,21 +26,21 @@ target triple = "x86_64-unknown-linux-gnu" @global = global i32 2, align 4 ; Function Attrs: nounwind readnone uwtable -define i32 @_Z3fooi(i32 %bar) #0 { +define i32 @_Z3fooi(i32 %bar) #0 !dbg !4 { entry: tail call void @llvm.dbg.value(metadata i32 %bar, i64 0, metadata !10, metadata !DIExpression()), !dbg !20 ret i32 %bar, !dbg !20 } ; Function Attrs: nounwind readnone uwtable -define i32 @_Z4foo2i(i32 %bar2) #0 { +define i32 @_Z4foo2i(i32 %bar2) #0 !dbg !11 { entry: tail call void @llvm.dbg.value(metadata i32 %bar2, i64 0, metadata !13, metadata !DIExpression()), !dbg !21 ret i32 %bar2, !dbg !21 } ; Function Attrs: nounwind readonly uwtable -define i32 @main() #1 { +define i32 @main() #1 !dbg !14 { entry: %call = tail call i32 @_Z3fooi(i32 2), !dbg !22 %call1 = tail call i32 @_Z4foo2i(i32 1), !dbg !22 @@ -64,17 +64,17 @@ attributes #2 = { nounwind readnone } !1 = !DIFile(filename: "tmp/debug_ranges/a.cc", directory: "/") !2 = !{} !3 = !{!4, !11, !14} -!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooi", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !1, scope: !5, type: !6, function: i32 (i32)* @_Z3fooi, variables: !9) +!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooi", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !9) !5 = !DIFile(filename: "tmp/debug_ranges/a.cc", directory: "/") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} !8 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !9 = !{!10} !10 = !DILocalVariable(name: "bar", line: 2, arg: 1, scope: !4, file: !5, type: !8) -!11 = distinct !DISubprogram(name: "foo2", linkageName: "_Z4foo2i", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !5, type: !6, function: i32 (i32)* @_Z4foo2i, variables: !12) +!11 = distinct !DISubprogram(name: "foo2", linkageName: "_Z4foo2i", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !12) !12 = !{!13} !13 = !DILocalVariable(name: "bar2", line: 3, arg: 1, scope: !11, file: !5, type: !8) -!14 = distinct !DISubprogram(name: "main", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !1, scope: !5, type: !15, function: i32 ()* @main, variables: !2) +!14 = distinct !DISubprogram(name: "main", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !1, scope: !5, type: !15, variables: !2) !15 = !DISubroutineType(types: !16) !16 = !{!8} !17 = !{!18} diff --git a/test/DebugInfo/X86/dwarf-aranges.ll b/test/DebugInfo/X86/dwarf-aranges.ll index 30db72e6092..cb2e8788128 100644 --- a/test/DebugInfo/X86/dwarf-aranges.ll +++ b/test/DebugInfo/X86/dwarf-aranges.ll @@ -48,7 +48,7 @@ target triple = "x86_64-unknown-linux-gnu" @some_other = global i32 5, section "strange+section", align 4 @some_bss = common global i32 0, align 4 -define void @some_code() { +define void @some_code() !dbg !4 { entry: %0 = load i32, i32* @some_data, align 4, !dbg !14 %1 = load i32, i32* @some_other, align 4, !dbg !14 @@ -66,7 +66,7 @@ entry: !1 = !DIFile(filename: "test.c", directory: "/home/kayamon") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "some_code", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 6, file: !1, scope: !5, type: !6, function: void ()* @some_code, variables: !2) +!4 = distinct !DISubprogram(name: "some_code", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 6, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "test.c", directory: "/home/kayamon") !6 = !DISubroutineType(types: !7) !7 = !{null} diff --git a/test/DebugInfo/X86/dwarf-linkage-names.ll b/test/DebugInfo/X86/dwarf-linkage-names.ll index 6cf79897d82..65cf1914dd4 100644 --- a/test/DebugInfo/X86/dwarf-linkage-names.ll +++ b/test/DebugInfo/X86/dwarf-linkage-names.ll @@ -41,7 +41,7 @@ @_ZN4test10global_varE = global i32 0, align 4 ; Function Attrs: nounwind uwtable -define i32 @_ZN4test3barEv() #0 { +define i32 @_ZN4test3barEv() #0 !dbg !4 { entry: %0 = load i32, i32* @_ZN4test10global_varE, align 4, !dbg !14 ret i32 %0, !dbg !15 @@ -57,7 +57,7 @@ attributes #0 = { nounwind uwtable "disable-tail-calls"="false" "less-precise-fp !1 = !DIFile(filename: "dwarf-linkage-names.cpp", directory: "/home/probinson/projects/scratch") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "bar", linkageName: "_ZN4test3barEv", scope: !5, file: !1, line: 3, type: !6, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, function: i32 ()* @_ZN4test3barEv, variables: !2) +!4 = distinct !DISubprogram(name: "bar", linkageName: "_ZN4test3barEv", scope: !5, file: !1, line: 3, type: !6, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DINamespace(name: "test", scope: null, file: !1, line: 1) !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/DebugInfo/X86/dwarf-public-names.ll b/test/DebugInfo/X86/dwarf-public-names.ll index f63f98438c5..d850899ce85 100644 --- a/test/DebugInfo/X86/dwarf-public-names.ll +++ b/test/DebugInfo/X86/dwarf-public-names.ll @@ -61,7 +61,7 @@ @global_variable = global %struct.C zeroinitializer, align 1 @_ZN2ns25global_namespace_variableE = global i32 1, align 4 -define void @_ZN1C15member_functionEv(%struct.C* %this) nounwind uwtable align 2 { +define void @_ZN1C15member_functionEv(%struct.C* %this) nounwind uwtable align 2 !dbg !3 { entry: %this.addr = alloca %struct.C*, align 8 store %struct.C* %this, %struct.C** %this.addr, align 8 @@ -73,18 +73,18 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone -define i32 @_ZN1C22static_member_functionEv() nounwind uwtable align 2 { +define i32 @_ZN1C22static_member_functionEv() nounwind uwtable align 2 !dbg !18 { entry: %0 = load i32, i32* @_ZN1C22static_member_variableE, align 4, !dbg !33 ret i32 %0, !dbg !33 } -define i32 @_Z15global_functionv() nounwind uwtable { +define i32 @_Z15global_functionv() nounwind uwtable !dbg !19 { entry: ret i32 -1, !dbg !34 } -define void @_ZN2ns25global_namespace_functionEv() nounwind uwtable { +define void @_ZN2ns25global_namespace_functionEv() nounwind uwtable !dbg !20 { entry: call void @_ZN1C15member_functionEv(%struct.C* @global_variable), !dbg !35 ret void, !dbg !36 @@ -99,7 +99,7 @@ attributes #1 = { nounwind readnone } !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.3 (http://llvm.org/git/clang.git a09cd8103a6a719cb2628cdf0c91682250a17bd2) (http://llvm.org/git/llvm.git 47d03cec0afca0c01ae42b82916d1d731716cd20)", isOptimized: false, emissionKind: 0, file: !37, enums: !1, retainedTypes: !1, subprograms: !2, globals: !24, imports: !1) !1 = !{} !2 = !{!3, !18, !19, !20} -!3 = distinct !DISubprogram(name: "member_function", linkageName: "_ZN1C15member_functionEv", line: 9, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 9, file: !4, scope: null, type: !5, function: void (%struct.C*)* @_ZN1C15member_functionEv, declaration: !12, variables: !1) +!3 = distinct !DISubprogram(name: "member_function", linkageName: "_ZN1C15member_functionEv", line: 9, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 9, file: !4, scope: null, type: !5, declaration: !12, variables: !1) !4 = !DIFile(filename: "dwarf-public-names.cpp", directory: "/usr2/kparzysz/s.hex/t") !5 = !DISubroutineType(types: !6) !6 = !{null, !7} @@ -114,9 +114,9 @@ attributes #1 = { nounwind readnone } !15 = !DISubroutineType(types: !16) !16 = !{!11} !17 = !{} ; previously: invalid DW_TAG_base_type -!18 = distinct !DISubprogram(name: "static_member_function", linkageName: "_ZN1C22static_member_functionEv", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 13, file: !4, scope: null, type: !15, function: i32 ()* @_ZN1C22static_member_functionEv, declaration: !14, variables: !1) -!19 = distinct !DISubprogram(name: "global_function", linkageName: "_Z15global_functionv", line: 19, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 19, file: !4, scope: !4, type: !15, function: i32 ()* @_Z15global_functionv, variables: !1) -!20 = distinct !DISubprogram(name: "global_namespace_function", linkageName: "_ZN2ns25global_namespace_functionEv", line: 24, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 24, file: !4, scope: !21, type: !22, function: void ()* @_ZN2ns25global_namespace_functionEv, variables: !1) +!18 = distinct !DISubprogram(name: "static_member_function", linkageName: "_ZN1C22static_member_functionEv", line: 13, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 13, file: !4, scope: null, type: !15, declaration: !14, variables: !1) +!19 = distinct !DISubprogram(name: "global_function", linkageName: "_Z15global_functionv", line: 19, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 19, file: !4, scope: !4, type: !15, variables: !1) +!20 = distinct !DISubprogram(name: "global_namespace_function", linkageName: "_ZN2ns25global_namespace_functionEv", line: 24, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 24, file: !4, scope: !21, type: !22, variables: !1) !21 = !DINamespace(name: "ns", line: 23, file: !4, scope: null) !22 = !DISubroutineType(types: !23) !23 = !{null} diff --git a/test/DebugInfo/X86/dwarf-pubnames-split.ll b/test/DebugInfo/X86/dwarf-pubnames-split.ll index 63ef173e751..a8e4cc6e433 100644 --- a/test/DebugInfo/X86/dwarf-pubnames-split.ll +++ b/test/DebugInfo/X86/dwarf-pubnames-split.ll @@ -12,7 +12,7 @@ ; CHECK-NEXT: .long .Lcu_begin0 # Offset of Compilation Unit Info ; Function Attrs: nounwind uwtable -define i32 @main() #0 { +define i32 @main() #0 !dbg !4 { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval @@ -28,7 +28,7 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe !1 = !DIFile(filename: "foo.c", directory: "/usr/local/google/home/echristo/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "foo.c", directory: "/usr/local/google/home/echristo/tmp") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/DebugInfo/X86/earlydup-crash.ll b/test/DebugInfo/X86/earlydup-crash.ll index 202854447c3..73626597d23 100644 --- a/test/DebugInfo/X86/earlydup-crash.ll +++ b/test/DebugInfo/X86/earlydup-crash.ll @@ -6,7 +6,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnone -define internal i8* @framework_construct_pathname(i8* %fname, %struct.cpp_dir* %dir) nounwind ssp { +define internal i8* @framework_construct_pathname(i8* %fname, %struct.cpp_dir* %dir) nounwind ssp !dbg !2 { entry: br i1 undef, label %bb33, label %bb @@ -46,7 +46,7 @@ declare void @foobar(i32) !llvm.module.flags = !{!47} !0 = !DILocalVariable(name: "frname_len", line: 517, scope: !1, file: !3, type: !38) !1 = distinct !DILexicalBlock(line: 515, column: 0, file: !44, scope: !2) -!2 = distinct !DISubprogram(name: "framework_construct_pathname", line: 515, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !44, scope: null, type: !5, function: i8* (i8*, %struct.cpp_dir*)* @framework_construct_pathname) +!2 = distinct !DISubprogram(name: "framework_construct_pathname", line: 515, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, file: !44, scope: null, type: !5) !3 = !DIFile(filename: "darwin-c.c", directory: "/Users/espindola/llvm/build-llvm-gcc/gcc/../../llvm-gcc-4.2/gcc/config") !4 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: true, emissionKind: 0, file: !44, enums: !46, retainedTypes: !46, subprograms: !45) !5 = !DISubroutineType(types: !6) diff --git a/test/DebugInfo/X86/elf-names.ll b/test/DebugInfo/X86/elf-names.ll index 649e3447cf7..2c857192762 100644 --- a/test/DebugInfo/X86/elf-names.ll +++ b/test/DebugInfo/X86/elf-names.ll @@ -20,7 +20,7 @@ @_ZN1DC1Ev = alias void (%class.D*), void (%class.D*)* @_ZN1DC2Ev @_ZN1DC1ERKS_ = alias void (%class.D*, %class.D*), void (%class.D*, %class.D*)* @_ZN1DC2ERKS_ -define void @_ZN1DC2Ev(%class.D* nocapture %this) unnamed_addr nounwind uwtable align 2 { +define void @_ZN1DC2Ev(%class.D* nocapture %this) unnamed_addr nounwind uwtable align 2 !dbg !5 { entry: tail call void @llvm.dbg.value(metadata %class.D* %this, i64 0, metadata !29, metadata !DIExpression()), !dbg !36 %c1 = getelementptr inbounds %class.D, %class.D* %this, i64 0, i32 0, !dbg !37 @@ -34,7 +34,7 @@ entry: ret void, !dbg !45 } -define void @_ZN1DC2ERKS_(%class.D* nocapture %this, %class.D* nocapture %d) unnamed_addr nounwind uwtable align 2 { +define void @_ZN1DC2ERKS_(%class.D* nocapture %this, %class.D* nocapture %d) unnamed_addr nounwind uwtable align 2 !dbg !31 { entry: tail call void @llvm.dbg.value(metadata %class.D* %this, i64 0, metadata !34, metadata !DIExpression()), !dbg !46 tail call void @llvm.dbg.value(metadata %class.D* %d, i64 0, metadata !35, metadata !DIExpression()), !dbg !46 @@ -65,7 +65,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.2 (trunk 167506) (llvm/trunk 167505)", isOptimized: true, emissionKind: 0, file: !53, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5, !31} -!5 = distinct !DISubprogram(name: "D", linkageName: "_ZN1DC2Ev", line: 12, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 12, file: !6, scope: null, type: !7, function: void (%class.D*)* @_ZN1DC2Ev, declaration: !17, variables: !27) +!5 = distinct !DISubprogram(name: "D", linkageName: "_ZN1DC2Ev", line: 12, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 12, file: !6, scope: null, type: !7, declaration: !17, variables: !27) !6 = !DIFile(filename: "foo.cpp", directory: "/usr/local/google/home/echristo") !7 = !DISubroutineType(types: !8) !8 = !{null, !9} @@ -86,7 +86,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !27 = !{!29} !29 = !DILocalVariable(name: "this", line: 12, arg: 1, flags: DIFlagArtificial | DIFlagObjectPointer, scope: !5, file: !6, type: !30) !30 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !10) -!31 = distinct !DISubprogram(name: "D", linkageName: "_ZN1DC2ERKS_", line: 19, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 19, file: !6, scope: null, type: !21, function: void (%class.D*, %class.D*)* @_ZN1DC2ERKS_, declaration: !20, variables: !32) +!31 = distinct !DISubprogram(name: "D", linkageName: "_ZN1DC2ERKS_", line: 19, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 19, file: !6, scope: null, type: !21, declaration: !20, variables: !32) !32 = !{!34, !35} !34 = !DILocalVariable(name: "this", line: 19, arg: 1, flags: DIFlagArtificial | DIFlagObjectPointer, scope: !31, file: !6, type: !30) !35 = !DILocalVariable(name: "d", line: 19, arg: 2, scope: !31, file: !6, type: !23) diff --git a/test/DebugInfo/X86/empty-and-one-elem-array.ll b/test/DebugInfo/X86/empty-and-one-elem-array.ll index 5af235f6a08..550a231f769 100644 --- a/test/DebugInfo/X86/empty-and-one-elem-array.ll +++ b/test/DebugInfo/X86/empty-and-one-elem-array.ll @@ -5,7 +5,7 @@ %struct.foo = type { i32, [1 x i32] } %struct.bar = type { i32, [0 x i32] } -define i32 @func() nounwind uwtable ssp { +define i32 @func() nounwind uwtable ssp !dbg !5 { entry: %my_foo = alloca %struct.foo, align 4 %my_bar = alloca %struct.bar, align 4 @@ -66,7 +66,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.3 (trunk 169136)", isOptimized: false, emissionKind: 0, file: !32, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "func", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 11, file: !6, scope: !6, type: !7, function: i32 ()* @func, variables: !1) +!5 = distinct !DISubprogram(name: "func", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 11, file: !6, scope: !6, type: !7, variables: !1) !6 = !DIFile(filename: "test.c", directory: "/Volumes/Sandbox/llvm") !7 = !DISubroutineType(types: !8) !8 = !{!9} diff --git a/test/DebugInfo/X86/ending-run.ll b/test/DebugInfo/X86/ending-run.ll index 94196e0559b..efb85aad73b 100644 --- a/test/DebugInfo/X86/ending-run.ll +++ b/test/DebugInfo/X86/ending-run.ll @@ -8,7 +8,7 @@ ; CHECK: 0x0000000000000000 7 0 1 0 ; CHECK: 0x0000000000000004 8 18 1 0 0 is_stmt prologue_end -define i32 @callee(i32 %x) nounwind uwtable ssp { +define i32 @callee(i32 %x) nounwind uwtable ssp !dbg !5 { entry: %x.addr = alloca i32, align 4 %y = alloca i32, align 4 @@ -32,7 +32,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.1 (trunk 153921) (llvm/trunk 153916)", isOptimized: false, emissionKind: 0, file: !19, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "callee", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 7, file: !19, scope: !6, type: !7, function: i32 (i32)* @callee) +!5 = distinct !DISubprogram(name: "callee", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 7, file: !19, scope: !6, type: !7) !6 = !DIFile(filename: "ending-run.c", directory: "/Users/echristo/tmp") !7 = !DISubroutineType(types: !8) !8 = !{!9, !9} diff --git a/test/DebugInfo/X86/fission-inline.ll b/test/DebugInfo/X86/fission-inline.ll index fbee6dcdd52..af7dd95e5b8 100644 --- a/test/DebugInfo/X86/fission-inline.ll +++ b/test/DebugInfo/X86/fission-inline.ll @@ -75,7 +75,7 @@ ; RELOCS-NOT: RELOCATION RECORDS FOR [.rela.debug_ranges] ; Function Attrs: uwtable -define void @_ZN3foo2f3Ez(...) #0 align 2 { +define void @_ZN3foo2f3Ez(...) #0 align 2 !dbg !10 { entry: call void @_Z2f1v(), !dbg !26 call void @_Z2f1v(), !dbg !25 @@ -102,7 +102,7 @@ attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !7 = !DISubroutineType(types: !8) !8 = !{null, null} !9 = !{!10, !11} -!10 = distinct !DISubprogram(name: "f3", linkageName: "_ZN3foo2f3Ez", line: 15, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 15, file: !1, scope: !"_ZTS3foo", type: !7, function: void (...)* @_ZN3foo2f3Ez, declaration: !6, variables: !2) +!10 = distinct !DISubprogram(name: "f3", linkageName: "_ZN3foo2f3Ez", line: 15, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 15, file: !1, scope: !"_ZTS3foo", type: !7, declaration: !6, variables: !2) !11 = distinct !DISubprogram(name: "f2<int>", linkageName: "_ZN3foo2f2IiEEvv", line: 10, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !1, scope: !"_ZTS3foo", type: !12, templateParams: !14, declaration: !17, variables: !2) !12 = !DISubroutineType(types: !13) !13 = !{null} diff --git a/test/DebugInfo/X86/fission-ranges.ll b/test/DebugInfo/X86/fission-ranges.ll index 23e4936e6ce..531024ace9b 100644 --- a/test/DebugInfo/X86/fission-ranges.ll +++ b/test/DebugInfo/X86/fission-ranges.ll @@ -82,14 +82,14 @@ @c = external global i32 ; Function Attrs: nounwind uwtable -define void @bar() #0 { +define void @bar() #0 !dbg !4 { entry: tail call fastcc void @foo(), !dbg !27 ret void, !dbg !28 } ; Function Attrs: nounwind uwtable -define internal fastcc void @foo() #0 { +define internal fastcc void @foo() #0 !dbg !8 { entry: tail call void @llvm.dbg.value(metadata i32 1, i64 0, metadata !13, metadata !DIExpression()), !dbg !30 tail call void @llvm.dbg.value(metadata i32 0, i64 0, metadata !14, metadata !DIExpression()), !dbg !31 @@ -157,11 +157,11 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "small.c", directory: "/usr/local/google/home/echristo/tmp") !2 = !{} !3 = !{!4, !8} -!4 = distinct !DISubprogram(name: "bar", line: 18, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 19, file: !1, scope: !5, type: !6, function: void ()* @bar, variables: !2) +!4 = distinct !DISubprogram(name: "bar", line: 18, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 19, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "small.c", directory: "/usr/local/google/home/echristo/tmp") !6 = !DISubroutineType(types: !7) !7 = !{null} -!8 = distinct !DISubprogram(name: "foo", line: 2, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !5, type: !9, function: void ()* @foo, variables: !12) +!8 = distinct !DISubprogram(name: "foo", line: 2, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !5, type: !9, variables: !12) !9 = !DISubroutineType(types: !10) !10 = !{null, !11} !11 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/DebugInfo/X86/float_const.ll b/test/DebugInfo/X86/float_const.ll index dbdd27f5f19..cd94f74dcbe 100644 --- a/test/DebugInfo/X86/float_const.ll +++ b/test/DebugInfo/X86/float_const.ll @@ -8,7 +8,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-apple-macosx10.10.0" ; Function Attrs: nounwind optsize readnone uwtable -define void @foo() #0 { +define void @foo() #0 !dbg !7 { entry: tail call void @llvm.dbg.declare(metadata float* undef, metadata !13, metadata !19), !dbg !20 tail call void @llvm.dbg.value(metadata i32 1078523331, i64 0, metadata !13, metadata !19), !dbg !20 @@ -38,7 +38,7 @@ attributes #1 = { nounwind readnone } !4 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !5) !5 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !6 = !{!7} -!7 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, isOptimized: true, scopeLine: 1, file: !8, scope: !9, type: !10, function: void ()* @foo, variables: !12) +!7 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, isOptimized: true, scopeLine: 1, file: !8, scope: !9, type: !10, variables: !12) !8 = !DIFile(filename: "foo.c", directory: "") !9 = !DIFile(filename: "foo.c", directory: "") !10 = !DISubroutineType(types: !11) diff --git a/test/DebugInfo/X86/formal_parameter.ll b/test/DebugInfo/X86/formal_parameter.ll index fa7329ce8ef..89be50bbd4a 100644 --- a/test/DebugInfo/X86/formal_parameter.ll +++ b/test/DebugInfo/X86/formal_parameter.ll @@ -24,7 +24,7 @@ target triple = "x86_64-apple-macosx10.9.0" ; CHECK-NOT: DW_AT_name {{.*}}map ; Function Attrs: nounwind ssp uwtable -define void @foo(i32 %map) #0 { +define void @foo(i32 %map) #0 !dbg !4 { entry: %map.addr = alloca i32, align 4 store i32 %map, i32* %map.addr, align 4, !tbaa !15 @@ -63,7 +63,7 @@ attributes #3 = { nounwind } !1 = !DIFile(filename: "formal_parameter.c", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !1, scope: !5, type: !6, function: void (i32)* @foo, variables: !9) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !9) !5 = !DIFile(filename: "formal_parameter.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{null, !8} diff --git a/test/DebugInfo/X86/frame-register.ll b/test/DebugInfo/X86/frame-register.ll index 6ad4f49502d..e7f48597b34 100644 --- a/test/DebugInfo/X86/frame-register.ll +++ b/test/DebugInfo/X86/frame-register.ll @@ -14,7 +14,7 @@ declare i32 @foo(i32 %i) #0 declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: nounwind uwtable -define i32 @main() #0 { +define i32 @main() #0 !dbg !9 { entry: %retval = alloca i32, align 4 %i = alloca i32, align 4 @@ -37,12 +37,12 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "x.c", directory: "") !2 = !{} !3 = !{!4, !9} -!4 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, function: i32 (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "x.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} !8 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!9 = distinct !DISubprogram(name: "main", line: 8, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 9, file: !1, scope: !5, type: !10, function: i32 ()* @main, variables: !2) +!9 = distinct !DISubprogram(name: "main", line: 8, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 9, file: !1, scope: !5, type: !10, variables: !2) !10 = !DISubroutineType(types: !11) !11 = !{!8} !12 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/DebugInfo/X86/generate-odr-hash.ll b/test/DebugInfo/X86/generate-odr-hash.ll index 7f8303bc0ac..51f33e2730a 100644 --- a/test/DebugInfo/X86/generate-odr-hash.ll +++ b/test/DebugInfo/X86/generate-odr-hash.ll @@ -180,7 +180,7 @@ @llvm.global_ctors = appending global [1 x { i32, void ()* }] [{ i32, void ()* } { i32 65535, void ()* @_GLOBAL__I_a }] ; Function Attrs: nounwind uwtable -define void @_Z3foov() #0 { +define void @_Z3foov() #0 !dbg !22 { entry: %b = alloca %struct.baz, align 1 call void @llvm.dbg.declare(metadata %struct.baz* %b, metadata !46, metadata !DIExpression()), !dbg !48 @@ -190,14 +190,14 @@ entry: ; Function Attrs: nounwind readnone declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 -define internal void @__cxx_global_var_init() section ".text.startup" { +define internal void @__cxx_global_var_init() section ".text.startup" !dbg !26 { entry: call void @_ZN12_GLOBAL__N_16walrusC2Ev(%"struct.<anonymous namespace>::walrus"* @w), !dbg !50 ret void, !dbg !50 } ; Function Attrs: nounwind uwtable -define internal void @_ZN12_GLOBAL__N_16walrusC2Ev(%"struct.<anonymous namespace>::walrus"* %this) unnamed_addr #0 align 2 { +define internal void @_ZN12_GLOBAL__N_16walrusC2Ev(%"struct.<anonymous namespace>::walrus"* %this) unnamed_addr #0 align 2 !dbg !27 { entry: %this.addr = alloca %"struct.<anonymous namespace>::walrus"*, align 8 store %"struct.<anonymous namespace>::walrus"* %this, %"struct.<anonymous namespace>::walrus"** %this.addr, align 8 @@ -206,7 +206,7 @@ entry: ret void, !dbg !54 } -define internal void @_GLOBAL__I_a() section ".text.startup" { +define internal void @_GLOBAL__I_a() section ".text.startup" !dbg !36 { entry: call void @__cxx_global_var_init(), !dbg !55 ret void, !dbg !55 @@ -241,12 +241,12 @@ attributes #1 = { nounwind readnone } !19 = !DIDerivedType(tag: DW_TAG_member, name: "a", line: 33, size: 32, align: 32, file: !1, scope: !"_ZTSN6wombatUt_E", baseType: !12) !20 = !DIDerivedType(tag: DW_TAG_member, name: "b", line: 34, size: 32, align: 32, offset: 32, file: !1, scope: !"_ZTSN6wombatUt_E", baseType: !12) !21 = !{!22, !26, !27, !36} -!22 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foov", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !23, type: !24, function: void ()* @_Z3foov, variables: !2) +!22 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foov", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !23, type: !24, variables: !2) !23 = !DIFile(filename: "bar.cpp", directory: "/tmp/dbginfo") !24 = !DISubroutineType(types: !25) !25 = !{null} -!26 = distinct !DISubprogram(name: "__cxx_global_var_init", line: 29, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 29, file: !1, scope: !23, type: !24, function: void ()* @__cxx_global_var_init, variables: !2) -!27 = distinct !DISubprogram(name: "walrus", linkageName: "_ZN12_GLOBAL__N_16walrusC2Ev", line: 25, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 25, file: !1, scope: !28, type: !32, function: void (%"struct.<anonymous namespace>::walrus"*)* @_ZN12_GLOBAL__N_16walrusC2Ev, declaration: !31, variables: !2) +!26 = distinct !DISubprogram(name: "__cxx_global_var_init", line: 29, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 29, file: !1, scope: !23, type: !24, variables: !2) +!27 = distinct !DISubprogram(name: "walrus", linkageName: "_ZN12_GLOBAL__N_16walrusC2Ev", line: 25, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 25, file: !1, scope: !28, type: !32, declaration: !31, variables: !2) !28 = !DICompositeType(tag: DW_TAG_structure_type, name: "walrus", line: 24, size: 8, align: 8, file: !1, scope: !29, elements: !30) !29 = !DINamespace(line: 23, file: !1, scope: null) !30 = !{!31} @@ -254,7 +254,7 @@ attributes #1 = { nounwind readnone } !32 = !DISubroutineType(types: !33) !33 = !{null, !34} !34 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !28) -!36 = distinct !DISubprogram(name: "", linkageName: "_GLOBAL__I_a", line: 25, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagArtificial, isOptimized: false, scopeLine: 25, file: !1, scope: !23, type: !37, function: void ()* @_GLOBAL__I_a, variables: !2) +!36 = distinct !DISubprogram(name: "", linkageName: "_GLOBAL__I_a", line: 25, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagArtificial, isOptimized: false, scopeLine: 25, file: !1, scope: !23, type: !37, variables: !2) !37 = !DISubroutineType(types: !2) !38 = !{!39, !40, !41, !42} !39 = !DIGlobalVariable(name: "b", line: 3, isLocal: false, isDefinition: true, scope: null, file: !23, type: !4, variable: %struct.bar* @b) diff --git a/test/DebugInfo/X86/ghost-sdnode-dbgvalues.ll b/test/DebugInfo/X86/ghost-sdnode-dbgvalues.ll index a38c02eaa4b..20bb1b3f145 100644 --- a/test/DebugInfo/X86/ghost-sdnode-dbgvalues.ll +++ b/test/DebugInfo/X86/ghost-sdnode-dbgvalues.ll @@ -29,7 +29,7 @@ ; when run with r221709 reverted, then it really doesn't test anything anymore. ; Function Attrs: nounwind ssp uwtable -define i32 @foo(i32 %a) #0 { +define i32 @foo(i32 %a) #0 !dbg !8 { entry: call void @llvm.dbg.value(metadata i32 %a, i64 0, metadata !16, metadata !17), !dbg !18 %conv = trunc i32 %a to i16, !dbg !19 @@ -76,7 +76,7 @@ attributes #1 = { nounwind readnone } !5 = !DIFile(filename: "/usr/include/sys/_types/_int16_t.h", directory: "/tmp") !6 = !DIBasicType(tag: DW_TAG_base_type, name: "short", size: 16, align: 16, encoding: DW_ATE_signed) !7 = !{!8} -!8 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !9, type: !10, function: i32 (i32)* @foo, variables: !2) +!8 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !9, type: !10, variables: !2) !9 = !DIFile(filename: "ghost-sdnode-dbgvalues.c", directory: "/tmp") !10 = !DISubroutineType(types: !11) !11 = !{!12, !12} diff --git a/test/DebugInfo/X86/gnu-public-names.ll b/test/DebugInfo/X86/gnu-public-names.ll index fb417fb8b81..584c879c064 100644 --- a/test/DebugInfo/X86/gnu-public-names.ll +++ b/test/DebugInfo/X86/gnu-public-names.ll @@ -240,7 +240,7 @@ @_ZN5outer12_GLOBAL__N_11cE = internal global i32 0, align 4 ; Function Attrs: nounwind uwtable -define void @_ZN1C15member_functionEv(%struct.C* %this) #0 align 2 { +define void @_ZN1C15member_functionEv(%struct.C* %this) #0 align 2 !dbg !20 { entry: %this.addr = alloca %struct.C*, align 8 store %struct.C* %this, %struct.C** %this.addr, align 8 @@ -254,33 +254,33 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: nounwind uwtable -define i32 @_ZN1C22static_member_functionEv() #0 align 2 { +define i32 @_ZN1C22static_member_functionEv() #0 align 2 !dbg !21 { entry: %0 = load i32, i32* @_ZN1C22static_member_variableE, align 4, !dbg !57 ret i32 %0, !dbg !57 } ; Function Attrs: nounwind uwtable -define i32 @_Z15global_functionv() #0 { +define i32 @_Z15global_functionv() #0 !dbg !22 { entry: ret i32 -1, !dbg !58 } ; Function Attrs: nounwind uwtable -define void @_ZN2ns25global_namespace_functionEv() #0 { +define void @_ZN2ns25global_namespace_functionEv() #0 !dbg !23 { entry: call void @_ZN1C15member_functionEv(%struct.C* @global_variable), !dbg !59 ret void, !dbg !60 } ; Function Attrs: nounwind uwtable -define i32* @_Z2f3v() #0 { +define i32* @_Z2f3v() #0 !dbg !26 { entry: ret i32* @_ZZ2f3vE1z, !dbg !61 } ; Function Attrs: nounwind uwtable -define i32 @_Z2f7v() #0 { +define i32 @_Z2f7v() #0 !dbg !30 { entry: %0 = load i32, i32* @_ZN12_GLOBAL__N_11iE, align 4, !dbg !62 %call = call i32* @_Z2f3v(), !dbg !62 @@ -320,17 +320,17 @@ attributes #1 = { nounwind readnone } !17 = !{!18} !18 = !DIDerivedType(tag: DW_TAG_member, name: "A", scope: !"_ZTSN2ns1DE", file: !1, line: 30, baseType: !7, size: 32, align: 32) !19 = !{!20, !21, !22, !23, !26, !30} -!20 = distinct !DISubprogram(name: "member_function", linkageName: "_ZN1C15member_functionEv", scope: !"_ZTS1C", file: !1, line: 9, type: !9, isLocal: false, isDefinition: true, scopeLine: 9, flags: DIFlagPrototyped, isOptimized: false, function: void (%struct.C*)* @_ZN1C15member_functionEv, declaration: !8, variables: !2) -!21 = distinct !DISubprogram(name: "static_member_function", linkageName: "_ZN1C22static_member_functionEv", scope: !"_ZTS1C", file: !1, line: 13, type: !13, isLocal: false, isDefinition: true, scopeLine: 13, flags: DIFlagPrototyped, isOptimized: false, function: i32 ()* @_ZN1C22static_member_functionEv, declaration: !12, variables: !2) -!22 = distinct !DISubprogram(name: "global_function", linkageName: "_Z15global_functionv", scope: !1, file: !1, line: 19, type: !13, isLocal: false, isDefinition: true, scopeLine: 19, flags: DIFlagPrototyped, isOptimized: false, function: i32 ()* @_Z15global_functionv, variables: !2) -!23 = distinct !DISubprogram(name: "global_namespace_function", linkageName: "_ZN2ns25global_namespace_functionEv", scope: !16, file: !1, line: 24, type: !24, isLocal: false, isDefinition: true, scopeLine: 24, flags: DIFlagPrototyped, isOptimized: false, function: void ()* @_ZN2ns25global_namespace_functionEv, variables: !2) +!20 = distinct !DISubprogram(name: "member_function", linkageName: "_ZN1C15member_functionEv", scope: !"_ZTS1C", file: !1, line: 9, type: !9, isLocal: false, isDefinition: true, scopeLine: 9, flags: DIFlagPrototyped, isOptimized: false, declaration: !8, variables: !2) +!21 = distinct !DISubprogram(name: "static_member_function", linkageName: "_ZN1C22static_member_functionEv", scope: !"_ZTS1C", file: !1, line: 13, type: !13, isLocal: false, isDefinition: true, scopeLine: 13, flags: DIFlagPrototyped, isOptimized: false, declaration: !12, variables: !2) +!22 = distinct !DISubprogram(name: "global_function", linkageName: "_Z15global_functionv", scope: !1, file: !1, line: 19, type: !13, isLocal: false, isDefinition: true, scopeLine: 19, flags: DIFlagPrototyped, isOptimized: false, variables: !2) +!23 = distinct !DISubprogram(name: "global_namespace_function", linkageName: "_ZN2ns25global_namespace_functionEv", scope: !16, file: !1, line: 24, type: !24, isLocal: false, isDefinition: true, scopeLine: 24, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !24 = !DISubroutineType(types: !25) !25 = !{null} -!26 = distinct !DISubprogram(name: "f3", linkageName: "_Z2f3v", scope: !1, file: !1, line: 40, type: !27, isLocal: false, isDefinition: true, scopeLine: 40, flags: DIFlagPrototyped, isOptimized: false, function: i32* ()* @_Z2f3v, variables: !2) +!26 = distinct !DISubprogram(name: "f3", linkageName: "_Z2f3v", scope: !1, file: !1, line: 40, type: !27, isLocal: false, isDefinition: true, scopeLine: 40, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !27 = !DISubroutineType(types: !28) !28 = !{!29} !29 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: !7, size: 64, align: 64) -!30 = distinct !DISubprogram(name: "f7", linkageName: "_Z2f7v", scope: !1, file: !1, line: 57, type: !13, isLocal: false, isDefinition: true, scopeLine: 57, flags: DIFlagPrototyped, isOptimized: false, function: i32 ()* @_Z2f7v, variables: !2) +!30 = distinct !DISubprogram(name: "f7", linkageName: "_Z2f7v", scope: !1, file: !1, line: 57, type: !13, isLocal: false, isDefinition: true, scopeLine: 57, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !31 = !{!32, !33, !34, !35, !36, !37, !39, !41} !32 = !DIGlobalVariable(name: "static_member_variable", linkageName: "_ZN1C22static_member_variableE", scope: !0, file: !1, line: 7, type: !7, isLocal: false, isDefinition: true, variable: i32* @_ZN1C22static_member_variableE, declaration: !6) !33 = !DIGlobalVariable(name: "global_variable", scope: !0, file: !1, line: 17, type: !"_ZTS1C", isLocal: false, isDefinition: true, variable: %struct.C* @global_variable) diff --git a/test/DebugInfo/X86/header.ll b/test/DebugInfo/X86/header.ll index 87eb9070f0d..1b210d0b90a 100644 --- a/test/DebugInfo/X86/header.ll +++ b/test/DebugInfo/X86/header.ll @@ -11,7 +11,7 @@ ; CHECK: .section .debug_str -define void @f() { +define void @f() !dbg !4 { ret void, !dbg !9 } !llvm.dbg.cu = !{!0} @@ -21,7 +21,7 @@ define void @f() { !1 = !DIFile(filename: "/foo/test.c", directory: "/foo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: true, function: void ()* @f, variables: !2) +!4 = distinct !DISubprogram(name: "f", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: true, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/DebugInfo/X86/inline-member-function.ll b/test/DebugInfo/X86/inline-member-function.ll index 3a1d7574e41..712a20c3a4a 100644 --- a/test/DebugInfo/X86/inline-member-function.ll +++ b/test/DebugInfo/X86/inline-member-function.ll @@ -37,7 +37,7 @@ @i = global i32 0, align 4 ; Function Attrs: uwtable -define i32 @main() #0 { +define i32 @main() #0 !dbg !13 { entry: %this.addr.i = alloca %struct.foo*, align 8 %x.addr.i = alloca i32, align 4 @@ -77,7 +77,7 @@ attributes #1 = { nounwind readnone } !9 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !10 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS3foo") !12 = !{!13, !17} -!13 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !14, type: !15, function: i32 ()* @main, variables: !2) +!13 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !14, type: !15, variables: !2) !14 = !DIFile(filename: "inline.cpp", directory: "/tmp/dbginfo") !15 = !DISubroutineType(types: !16) !16 = !{!9} diff --git a/test/DebugInfo/X86/inline-seldag-test.ll b/test/DebugInfo/X86/inline-seldag-test.ll index fb655d4d2d7..62b946611f4 100644 --- a/test/DebugInfo/X86/inline-seldag-test.ll +++ b/test/DebugInfo/X86/inline-seldag-test.ll @@ -23,7 +23,7 @@ ; ASM: testl ; Function Attrs: nounwind uwtable -define void @func() #0 { +define void @func() #0 !dbg !4 { entry: %y.addr.i = alloca i32, align 4 %x = alloca i32, align 4 @@ -52,7 +52,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "inline-seldag-test.c", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4, !8} -!4 = distinct !DISubprogram(name: "func", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 4, file: !1, scope: !5, type: !6, function: void ()* @func, variables: !2) +!4 = distinct !DISubprogram(name: "func", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 4, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "inline-seldag-test.c", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !7) !7 = !{null} diff --git a/test/DebugInfo/X86/inlined-formal-parameter.ll b/test/DebugInfo/X86/inlined-formal-parameter.ll index de4b1bbc5b1..49c1747d7d6 100644 --- a/test/DebugInfo/X86/inlined-formal-parameter.ll +++ b/test/DebugInfo/X86/inlined-formal-parameter.ll @@ -25,7 +25,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-apple-darwin" ; Function Attrs: nounwind ssp uwtable -define void @foo() #0 { +define void @foo() #0 !dbg !4 { entry: tail call void @llvm.dbg.value(metadata i32 0, i64 0, metadata !12, metadata !17) #3, !dbg !18 tail call void @sink() #3, !dbg !20 @@ -52,7 +52,7 @@ attributes #3 = { nounwind } !1 = !DIFile(filename: "t.c", directory: "/path/to/dir") !2 = !{} !3 = !{!4, !7} -!4 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: true, function: void ()* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: true, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = distinct !DISubprogram(name: "bar", scope: !1, file: !1, line: 2, type: !8, isLocal: true, isDefinition: true, scopeLine: 2, flags: DIFlagPrototyped, isOptimized: true, variables: !11) diff --git a/test/DebugInfo/X86/inlined-indirect-value.ll b/test/DebugInfo/X86/inlined-indirect-value.ll index 489efa54490..d203650d05c 100644 --- a/test/DebugInfo/X86/inlined-indirect-value.ll +++ b/test/DebugInfo/X86/inlined-indirect-value.ll @@ -22,7 +22,7 @@ target triple = "x86_64-unknown-linux-gnu" @x = common global i32 0, align 4 @y = common global i32 0, align 4 -define i32 @main() { +define i32 @main() !dbg !4 { ; CHECK: .loc 1 {{[89]}} ; CHECK-NOT: .loc ; CHECK: movl $1 @@ -53,7 +53,7 @@ select.end: ; preds = %entry, %select.mid !1 = !DIFile(filename: "inline-break.c", directory: "/build/dir") !2 = !{} !3 = !{!4, !8} -!4 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 7, type: !5, isLocal: false, isDefinition: true, scopeLine: 7, isOptimized: true, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 7, type: !5, isLocal: false, isDefinition: true, scopeLine: 7, isOptimized: true, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{!7} !7 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/DebugInfo/X86/instcombine-instrinsics.ll b/test/DebugInfo/X86/instcombine-instrinsics.ll index cc27cd65631..f4f7e1403d3 100644 --- a/test/DebugInfo/X86/instcombine-instrinsics.ll +++ b/test/DebugInfo/X86/instcombine-instrinsics.ll @@ -28,7 +28,7 @@ target triple = "x86_64-apple-macosx10.9.0" %struct.i14 = type { i64 } ; Function Attrs: nounwind ssp uwtable -define void @init() #0 { +define void @init() #0 !dbg !4 { %p = alloca %struct.i14*, align 8 call void @llvm.dbg.declare(metadata %struct.i14** %p, metadata !11, metadata !DIExpression()), !dbg !18 store %struct.i14* null, %struct.i14** %p, align 8, !dbg !18 @@ -58,7 +58,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "instcombine_intrinsics.c", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "init", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 7, file: !1, scope: !5, type: !6, function: void ()* @init, variables: !2) +!4 = distinct !DISubprogram(name: "init", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 7, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "instcombine_intrinsics.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{null} diff --git a/test/DebugInfo/X86/lexical_block.ll b/test/DebugInfo/X86/lexical_block.ll index 4e3a99c4432..5fdfcdfe269 100644 --- a/test/DebugInfo/X86/lexical_block.ll +++ b/test/DebugInfo/X86/lexical_block.ll @@ -22,7 +22,7 @@ ; } ; Function Attrs: nounwind uwtable -define void @_Z1bv() #0 { +define void @_Z1bv() #0 !dbg !4 { entry: %i = alloca i32, align 4 call void @llvm.dbg.declare(metadata i32* %i, metadata !11, metadata !DIExpression()), !dbg !14 @@ -52,7 +52,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "lexical_block.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "b", linkageName: "_Z1bv", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: void ()* @_Z1bv, variables: !2) +!4 = distinct !DISubprogram(name: "b", linkageName: "_Z1bv", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "lexical_block.cpp", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !7) !7 = !{null} diff --git a/test/DebugInfo/X86/line-info.ll b/test/DebugInfo/X86/line-info.ll index 486c42e7be8..bdd91db9eec 100644 --- a/test/DebugInfo/X86/line-info.ll +++ b/test/DebugInfo/X86/line-info.ll @@ -14,7 +14,7 @@ ; int main() { ; } -define i32 @foo(i32 %x) #0 { +define i32 @foo(i32 %x) #0 !dbg !4 { entry: %x.addr = alloca i32, align 4 store i32 %x, i32* %x.addr, align 4 @@ -27,7 +27,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 -define i32 @main() #0 { +define i32 @main() #0 !dbg !10 { entry: ret i32 0, !dbg !17 } @@ -42,13 +42,13 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "list0.c", directory: "/usr/local/google/home/blaikie/dev/scratch") !2 = !{} !3 = !{!4, !10} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !5, scope: !6, type: !7, function: i32 (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !5, scope: !6, type: !7, variables: !2) !5 = !DIFile(filename: "./list0.h", directory: "/usr/local/google/home/blaikie/dev/scratch") !6 = !DIFile(filename: "./list0.h", directory: "/usr/local/google/home/blaikie/dev/scratch") !7 = !DISubroutineType(types: !8) !8 = !{!9, !9} !9 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!10 = distinct !DISubprogram(name: "main", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 2, file: !1, scope: !11, type: !12, function: i32 ()* @main, variables: !2) +!10 = distinct !DISubprogram(name: "main", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 2, file: !1, scope: !11, type: !12, variables: !2) !11 = !DIFile(filename: "list0.c", directory: "/usr/local/google/home/blaikie/dev/scratch") !12 = !DISubroutineType(types: !13) !13 = !{!9} diff --git a/test/DebugInfo/X86/linkage-name.ll b/test/DebugInfo/X86/linkage-name.ll index 23bfeee0f13..4408d5132c4 100644 --- a/test/DebugInfo/X86/linkage-name.ll +++ b/test/DebugInfo/X86/linkage-name.ll @@ -9,7 +9,7 @@ @a = global %class.A zeroinitializer, align 1 -define i32 @_ZN1A1aEi(%class.A* %this, i32 %b) nounwind uwtable ssp align 2 { +define i32 @_ZN1A1aEi(%class.A* %this, i32 %b) nounwind uwtable ssp align 2 !dbg !5 { entry: %this.addr = alloca %class.A*, align 8 %b.addr = alloca i32, align 4 @@ -30,7 +30,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.1 (trunk 152691) (llvm/trunk 152692)", isOptimized: false, emissionKind: 0, file: !28, enums: !1, retainedTypes: !1, subprograms: !3, globals: !18, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "a", linkageName: "_ZN1A1aEi", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !6, scope: null, type: !7, function: i32 (%class.A*, i32)* @_ZN1A1aEi, declaration: !13) +!5 = distinct !DISubprogram(name: "a", linkageName: "_ZN1A1aEi", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !6, scope: null, type: !7, declaration: !13) !6 = !DIFile(filename: "foo.cpp", directory: "/Users/echristo") !7 = !DISubroutineType(types: !8) !8 = !{!9, !10, !9} diff --git a/test/DebugInfo/X86/low-pc-cu.ll b/test/DebugInfo/X86/low-pc-cu.ll index 3ecdd333929..f98da6f5ae2 100644 --- a/test/DebugInfo/X86/low-pc-cu.ll +++ b/test/DebugInfo/X86/low-pc-cu.ll @@ -21,7 +21,7 @@ ; CHECK-V4: DW_AT_high_pc [DW_FORM_data4] ; Function Attrs: nounwind uwtable -define void @z() #0 { +define void @z() #0 !dbg !4 { entry: ret void, !dbg !11 } @@ -36,7 +36,7 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe !1 = !DIFile(filename: "z.c", directory: "/usr/local/google/home/echristo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "z", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: void ()* @z, variables: !2) +!4 = distinct !DISubprogram(name: "z", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "z.c", directory: "/usr/local/google/home/echristo") !6 = !DISubroutineType(types: !7) !7 = !{null} diff --git a/test/DebugInfo/X86/mi-print.ll b/test/DebugInfo/X86/mi-print.ll index 8eb1895f951..086e88deffb 100644 --- a/test/DebugInfo/X86/mi-print.ll +++ b/test/DebugInfo/X86/mi-print.ll @@ -14,7 +14,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-apple-macosx10.10.0" ; Function Attrs: nounwind readnone ssp uwtable -define i32 @bar(i32 %x) #0 { +define i32 @bar(i32 %x) #0 !dbg !4 { entry: tail call void @llvm.dbg.value(metadata i32 %x, i64 0, metadata !9, metadata !17), !dbg !18 tail call void @llvm.dbg.value(metadata i32 %x, i64 0, metadata !19, metadata !17), !dbg !21 @@ -35,7 +35,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "t.c", directory: "/Users/dexonsmith/data/llvm/debug-info/test/DebugInfo/X86") !2 = !{} !3 = !{!4, !10} -!4 = distinct !DISubprogram(name: "bar", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, flags: DIFlagPrototyped, isOptimized: true, function: i32 (i32)* @bar, variables: !8) +!4 = distinct !DISubprogram(name: "bar", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, flags: DIFlagPrototyped, isOptimized: true, variables: !8) !5 = !DISubroutineType(types: !6) !6 = !{!7, !7} !7 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/DebugInfo/X86/misched-dbg-value.ll b/test/DebugInfo/X86/misched-dbg-value.ll index 35c62516fea..e85e241c589 100644 --- a/test/DebugInfo/X86/misched-dbg-value.ll +++ b/test/DebugInfo/X86/misched-dbg-value.ll @@ -46,7 +46,7 @@ @PtrGlb = common global %struct.Record* null, align 8 @PtrGlbNext = common global %struct.Record* null, align 8 -define void @Proc8(i32* nocapture %Array1Par, [51 x i32]* nocapture %Array2Par, i32 %IntParI1, i32 %IntParI2) nounwind optsize { +define void @Proc8(i32* nocapture %Array1Par, [51 x i32]* nocapture %Array2Par, i32 %IntParI1, i32 %IntParI2) nounwind optsize !dbg !12 { entry: tail call void @llvm.dbg.value(metadata i32* %Array1Par, i64 0, metadata !23, metadata !DIExpression()), !dbg !64 tail call void @llvm.dbg.value(metadata [51 x i32]* %Array2Par, i64 0, metadata !24, metadata !DIExpression()), !dbg !65 @@ -115,7 +115,7 @@ attributes #1 = { nounwind readnone } !9 = !DIEnumerator(name: "Ident5", value: 10003) ; [ DW_TAG_enumerator ] [Ident5 :: 10003] !10 = !{} !11 = !{!12} -!12 = distinct !DISubprogram(name: "Proc8", line: 180, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 185, file: !82, scope: !3, type: !13, function: void (i32*, [51 x i32]*, i32, i32)* @Proc8, variables: !22) +!12 = distinct !DISubprogram(name: "Proc8", line: 180, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 185, file: !82, scope: !3, type: !13, variables: !22) !13 = !DISubroutineType(types: !14) !14 = !{null, !15, !17, !21, !21} !15 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !16) diff --git a/test/DebugInfo/X86/missing-file-line.ll b/test/DebugInfo/X86/missing-file-line.ll index 6fbfb94c39d..19064579af3 100644 --- a/test/DebugInfo/X86/missing-file-line.ll +++ b/test/DebugInfo/X86/missing-file-line.ll @@ -11,7 +11,7 @@ target triple = "x86_64-unknown-linux-gnu" %struct.S = type { %struct.S* } -define void @f() { +define void @f() !dbg !4 { %x = alloca %struct.S, align 8 ; CHECK: DW_TAG_typedef ; CHECK-NOT: DW_AT_decl_file @@ -40,7 +40,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 !1 = !DIFile(filename: "file.c", directory: "/dir") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f", scope: !1, file: !1, line: 7, type: !5, isLocal: false, isDefinition: true, scopeLine: 7, isOptimized: false, function: void ()* @f, variables: !2) +!4 = distinct !DISubprogram(name: "f", scope: !1, file: !1, line: 7, type: !5, isLocal: false, isDefinition: true, scopeLine: 7, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/DebugInfo/X86/multiple-at-const-val.ll b/test/DebugInfo/X86/multiple-at-const-val.ll index 5ecb9f05d39..97db7195290 100644 --- a/test/DebugInfo/X86/multiple-at-const-val.ll +++ b/test/DebugInfo/X86/multiple-at-const-val.ll @@ -19,7 +19,7 @@ @_ZSt4cout = external global %"class.std::basic_ostream" @.str = private unnamed_addr constant [6 x i8] c"c is \00", align 1 -define i32 @main() { +define i32 @main() !dbg !960 { entry: %call1.i = tail call %"class.std::basic_ostream"* @test(%"class.std::basic_ostream"* @_ZSt4cout, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i64 5) ret i32 0 @@ -54,7 +54,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !79 = !DIDerivedType(tag: DW_TAG_typedef, name: "ostate", line: 327, file: !1801, scope: !49, baseType: !26) !955 = !{} !956 = !{!960} -!960 = distinct !DISubprogram(name: "main", line: 73, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 73, file: !1802, scope: null, type: !54, function: i32 ()* @main, variables: !955) +!960 = distinct !DISubprogram(name: "main", line: 73, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 73, file: !1802, scope: null, type: !54, variables: !955) !961 = !DIFile(filename: "student2.cpp", directory: "/privite/tmp") !1786 = !{!1800} !1800 = !DIGlobalVariable(name: "badbit", linkageName: "badbit", line: 331, isLocal: true, isDefinition: true, scope: !5, file: !5, type: !78, variable: i32 1, declaration: !77) diff --git a/test/DebugInfo/X86/nophysreg.ll b/test/DebugInfo/X86/nophysreg.ll index b5ac42f2210..ddf014b43b7 100644 --- a/test/DebugInfo/X86/nophysreg.ll +++ b/test/DebugInfo/X86/nophysreg.ll @@ -53,7 +53,7 @@ target triple = "x86_64-apple-macosx10.10.0" %struct.A = type { i32*, i32 } ; Function Attrs: alwaysinline ssp uwtable -define void @_Z2f21A(i32* %p5.coerce0, i32 %p5.coerce1) #0 { +define void @_Z2f21A(i32* %p5.coerce0, i32 %p5.coerce1) #0 !dbg !11 { entry: tail call void @llvm.dbg.value(metadata i32* %p5.coerce0, i64 0, metadata !16, metadata !33), !dbg !34 tail call void @llvm.dbg.value(metadata i32 %p5.coerce1, i64 0, metadata !16, metadata !35), !dbg !34 @@ -68,7 +68,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 declare void @_Z2f1Pii(i32*, i32) #2 ; Function Attrs: ssp uwtable -define void @_Z1fv() #3 { +define void @_Z1fv() #3 !dbg !17 { entry: %x = alloca i32, align 4 %ref.tmp = alloca i32, align 4 @@ -147,13 +147,13 @@ attributes #3 = { ssp uwtable } !8 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !9 = !DIDerivedType(tag: DW_TAG_member, name: "m2", line: 3, size: 32, align: 32, offset: 64, file: !1, scope: !"_ZTS1A", baseType: !8) !10 = !{!11, !17} -!11 = distinct !DISubprogram(name: "f2", linkageName: "_Z2f21A", line: 7, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 7, file: !1, scope: !12, type: !13, function: void (i32*, i32)* @_Z2f21A, variables: !15) +!11 = distinct !DISubprogram(name: "f2", linkageName: "_Z2f21A", line: 7, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 7, file: !1, scope: !12, type: !13, variables: !15) !12 = !DIFile(filename: "test.cpp", directory: "") !13 = !DISubroutineType(types: !14) !14 = !{null, !"_ZTS1A"} !15 = !{!16} !16 = !DILocalVariable(name: "p5", line: 7, arg: 1, scope: !11, file: !12, type: !"_ZTS1A") -!17 = distinct !DISubprogram(name: "f", linkageName: "_Z1fv", line: 12, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 12, file: !1, scope: !12, type: !18, function: void ()* @_Z1fv, variables: !20) +!17 = distinct !DISubprogram(name: "f", linkageName: "_Z1fv", line: 12, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 12, file: !1, scope: !12, type: !18, variables: !20) !18 = !DISubroutineType(types: !19) !19 = !{null} !20 = !{!21, !23, !26, !27, !28} diff --git a/test/DebugInfo/X86/objc-property-void.ll b/test/DebugInfo/X86/objc-property-void.ll index 286a8ae82c3..190d5fe00e7 100644 --- a/test/DebugInfo/X86/objc-property-void.ll +++ b/test/DebugInfo/X86/objc-property-void.ll @@ -51,7 +51,7 @@ target triple = "x86_64-apple-macosx10.9.0" @llvm.used = appending global [8 x i8*] [i8* getelementptr inbounds ([4 x i8], [4 x i8]* @"\01L_OBJC_CLASS_NAME_", i32 0, i32 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @"\01L_OBJC_METH_VAR_NAME_", i32 0, i32 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @"\01L_OBJC_METH_VAR_TYPE_", i32 0, i32 0), i8* bitcast ({ i32, i32, [1 x %struct._objc_method] }* @"\01l_OBJC_$_INSTANCE_METHODS_Foo" to i8*), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @"\01L_OBJC_PROP_NAME_ATTR_", i32 0, i32 0), i8* getelementptr inbounds ([7 x i8], [7 x i8]* @"\01L_OBJC_PROP_NAME_ATTR_1", i32 0, i32 0), i8* bitcast ({ i32, i32, [1 x %struct._prop_t] }* @"\01l_OBJC_$_PROP_LIST_Foo" to i8*), i8* bitcast ([1 x i8*]* @"\01L_OBJC_LABEL_CLASS_$" to i8*)], section "llvm.metadata" ; Function Attrs: ssp uwtable -define internal void @"\01-[Foo foo]"(%0* %self, i8* %_cmd) #0 { +define internal void @"\01-[Foo foo]"(%0* %self, i8* %_cmd) #0 !dbg !10 { entry: %self.addr = alloca %0*, align 8 %_cmd.addr = alloca i8*, align 8 @@ -82,7 +82,7 @@ attributes #1 = { nounwind readnone } !7 = !{!8} !8 = !DIObjCProperty(name: "foo", line: 2, attributes: 2117, file: !6) !9 = !{!10} -!10 = distinct !DISubprogram(name: "-[Foo foo]", line: 5, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !5, scope: !6, type: !11, function: void (%0*, i8*)* @"\01-[Foo foo]", variables: !2) +!10 = distinct !DISubprogram(name: "-[Foo foo]", line: 5, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !5, scope: !6, type: !11, variables: !2) !11 = !DISubroutineType(types: !12) !12 = !{null, !13, !14} !13 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !4) diff --git a/test/DebugInfo/X86/op_deref.ll b/test/DebugInfo/X86/op_deref.ll index 1628d7f9968..1d89a686918 100644 --- a/test/DebugInfo/X86/op_deref.ll +++ b/test/DebugInfo/X86/op_deref.ll @@ -26,7 +26,7 @@ ; RUN: llvm-as %s -o - | llvm-dis - | FileCheck %s --check-prefix=PRETTY-PRINT ; PRETTY-PRINT: DIExpression(DW_OP_deref, DW_OP_deref) -define void @testVLAwithSize(i32 %s) nounwind uwtable ssp { +define void @testVLAwithSize(i32 %s) nounwind uwtable ssp !dbg !5 { entry: %s.addr = alloca i32, align 4 %saved_stack = alloca i8* @@ -83,7 +83,7 @@ declare void @llvm.stackrestore(i8*) nounwind !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.2 (trunk 156005) (llvm/trunk 156000)", isOptimized: false, emissionKind: 1, file: !28, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "testVLAwithSize", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !28, scope: !6, type: !7, function: void (i32)* @testVLAwithSize, variables: !1) +!5 = distinct !DISubprogram(name: "testVLAwithSize", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !28, scope: !6, type: !7, variables: !1) !6 = !DIFile(filename: "bar.c", directory: "/Users/echristo/tmp") !7 = !DISubroutineType(types: !8) !8 = !{null, !9} diff --git a/test/DebugInfo/X86/parameters.ll b/test/DebugInfo/X86/parameters.ll index d859816e8cc..1d71efc0719 100644 --- a/test/DebugInfo/X86/parameters.ll +++ b/test/DebugInfo/X86/parameters.ll @@ -40,7 +40,7 @@ %"struct.pr14763::foo" = type { i8 } ; Function Attrs: uwtable -define void @_ZN7pr147634funcENS_3fooE(%"struct.pr14763::foo"* noalias sret %agg.result, %"struct.pr14763::foo"* %f) #0 { +define void @_ZN7pr147634funcENS_3fooE(%"struct.pr14763::foo"* noalias sret %agg.result, %"struct.pr14763::foo"* %f) #0 !dbg !4 { entry: call void @llvm.dbg.declare(metadata %"struct.pr14763::foo"* %f, metadata !22, metadata !DIExpression(DW_OP_deref)), !dbg !24 call void @_ZN7pr147633fooC1ERKS0_(%"struct.pr14763::foo"* %agg.result, %"struct.pr14763::foo"* %f), !dbg !25 @@ -53,7 +53,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 declare void @_ZN7pr147633fooC1ERKS0_(%"struct.pr14763::foo"*, %"struct.pr14763::foo"*) #2 ; Function Attrs: uwtable -define void @_ZN7pr147635func2EbNS_3fooE(i1 zeroext %b, %"struct.pr14763::foo"* %g) #0 { +define void @_ZN7pr147635func2EbNS_3fooE(i1 zeroext %b, %"struct.pr14763::foo"* %g) #0 !dbg !17 { entry: %b.addr = alloca i8, align 1 %frombool = zext i1 %b to i8 @@ -86,7 +86,7 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !1 = !DIFile(filename: "pass.cpp", directory: "/tmp") !2 = !{} !3 = !{!4, !17} -!4 = distinct !DISubprogram(name: "func", linkageName: "_ZN7pr147634funcENS_3fooE", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: !5, type: !6, function: void (%"struct.pr14763::foo"*, %"struct.pr14763::foo"*)* @_ZN7pr147634funcENS_3fooE, variables: !2) +!4 = distinct !DISubprogram(name: "func", linkageName: "_ZN7pr147634funcENS_3fooE", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 6, file: !1, scope: !5, type: !6, variables: !2) !5 = !DINamespace(name: "pr14763", line: 1, file: !1, scope: null) !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} @@ -98,7 +98,7 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !13 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !8) !14 = !DIDerivedType(tag: DW_TAG_reference_type, baseType: !15) !15 = !DIDerivedType(tag: DW_TAG_const_type, baseType: !8) -!17 = distinct !DISubprogram(name: "func2", linkageName: "_ZN7pr147635func2EbNS_3fooE", line: 12, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 12, file: !1, scope: !5, type: !18, function: void (i1, %"struct.pr14763::foo"*)* @_ZN7pr147635func2EbNS_3fooE, variables: !2) +!17 = distinct !DISubprogram(name: "func2", linkageName: "_ZN7pr147635func2EbNS_3fooE", line: 12, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 12, file: !1, scope: !5, type: !18, variables: !2) !18 = !DISubroutineType(types: !19) !19 = !{null, !20, !8} !20 = !DIBasicType(tag: DW_TAG_base_type, name: "bool", size: 8, align: 8, encoding: DW_ATE_boolean) diff --git a/test/DebugInfo/X86/pieces-1.ll b/test/DebugInfo/X86/pieces-1.ll index 247ec5af2cb..9d4f5265b3c 100644 --- a/test/DebugInfo/X86/pieces-1.ll +++ b/test/DebugInfo/X86/pieces-1.ll @@ -30,7 +30,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-apple-macosx10.9.0" ; Function Attrs: nounwind ssp uwtable -define i32 @foo(i64 %s.coerce0, i32 %s.coerce1) #0 { +define i32 @foo(i64 %s.coerce0, i32 %s.coerce1) #0 !dbg !4 { entry: call void @llvm.dbg.value(metadata i64 %s.coerce0, i64 0, metadata !20, metadata !24), !dbg !21 call void @llvm.dbg.value(metadata i32 %s.coerce1, i64 0, metadata !22, metadata !27), !dbg !21 @@ -54,7 +54,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "pieces.c", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !5, type: !6, function: i32 (i64, i32)* @foo, variables: !15) +!4 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !15) !5 = !DIFile(filename: "pieces.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8, !9} diff --git a/test/DebugInfo/X86/pieces-2.ll b/test/DebugInfo/X86/pieces-2.ll index ee2e4d4f36f..8a43f452d32 100644 --- a/test/DebugInfo/X86/pieces-2.ll +++ b/test/DebugInfo/X86/pieces-2.ll @@ -29,7 +29,7 @@ target triple = "x86_64-apple-macosx10.9.0" %struct.Inner = type { i32, i64 } ; Function Attrs: nounwind ssp uwtable -define i32 @foo(%struct.Outer* byval align 8 %outer) #0 { +define i32 @foo(%struct.Outer* byval align 8 %outer) #0 !dbg !4 { entry: call void @llvm.dbg.declare(metadata %struct.Outer* %outer, metadata !25, metadata !DIExpression()), !dbg !26 %i1.sroa.0.0..sroa_idx = getelementptr inbounds %struct.Outer, %struct.Outer* %outer, i64 0, i32 0, i64 1, i32 0, !dbg !27 @@ -61,7 +61,7 @@ attributes #2 = { nounwind } !1 = !DIFile(filename: "sroasplit-1.c", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !1, scope: !5, type: !6, function: i32 (%struct.Outer*)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "sroasplit-1.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8, !9} diff --git a/test/DebugInfo/X86/pieces-3.ll b/test/DebugInfo/X86/pieces-3.ll index 56990b4d813..d52748fc17f 100644 --- a/test/DebugInfo/X86/pieces-3.ll +++ b/test/DebugInfo/X86/pieces-3.ll @@ -35,7 +35,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-apple-macosx10.9.0" ; Function Attrs: nounwind ssp uwtable -define i32 @foo(i64 %outer.coerce0, i64 %outer.coerce1) #0 { +define i32 @foo(i64 %outer.coerce0, i64 %outer.coerce1) #0 !dbg !4 { call void @llvm.dbg.value(metadata i64 %outer.coerce0, i64 0, metadata !24, metadata !25), !dbg !26 call void @llvm.dbg.declare(metadata !{null}, metadata !27, metadata !28), !dbg !26 call void @llvm.dbg.value(metadata i64 %outer.coerce1, i64 0, metadata !29, metadata !30), !dbg !26 @@ -71,7 +71,7 @@ attributes #2 = { nounwind } !1 = !DIFile(filename: "sroasplit-2.c", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !1, scope: !5, type: !6, function: i32 (i64, i64)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "sroasplit-2.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8, !9} diff --git a/test/DebugInfo/X86/pr11300.ll b/test/DebugInfo/X86/pr11300.ll index 4dda1a1e89b..c6124687b2c 100644 --- a/test/DebugInfo/X86/pr11300.ll +++ b/test/DebugInfo/X86/pr11300.ll @@ -14,7 +14,7 @@ %struct.foo = type { i8 } -define void @_Z3zedP3foo(%struct.foo* %x) uwtable { +define void @_Z3zedP3foo(%struct.foo* %x) uwtable !dbg !5 { entry: %x.addr = alloca %struct.foo*, align 8 store %struct.foo* %x, %struct.foo** %x.addr, align 8 @@ -26,7 +26,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone -define linkonce_odr void @_ZN3foo3barEv(%struct.foo* %this) nounwind uwtable align 2 { +define linkonce_odr void @_ZN3foo3barEv(%struct.foo* %this) nounwind uwtable align 2 !dbg !20 { entry: %this.addr = alloca %struct.foo*, align 8 store %struct.foo* %this, %struct.foo** %this.addr, align 8 @@ -41,7 +41,7 @@ entry: !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.0 ()", isOptimized: false, emissionKind: 0, file: !32, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5, !20} -!5 = distinct !DISubprogram(name: "zed", linkageName: "_Z3zedP3foo", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !6, scope: !6, type: !7, function: void (%struct.foo*)* @_Z3zedP3foo) +!5 = distinct !DISubprogram(name: "zed", linkageName: "_Z3zedP3foo", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !6, scope: !6, type: !7) !6 = !DIFile(filename: "/home/espindola/llvm/test.cc", directory: "/home/espindola/tmpfs/build") !7 = !DISubroutineType(types: !8) !8 = !{null, !9} @@ -52,7 +52,7 @@ entry: !13 = !DISubroutineType(types: !14) !14 = !{null, !15} !15 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial, baseType: !10) -!20 = distinct !DISubprogram(name: "bar", linkageName: "_ZN3foo3barEv", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !6, scope: null, type: !13, function: void (%struct.foo*)* @_ZN3foo3barEv, declaration: !12) +!20 = distinct !DISubprogram(name: "bar", linkageName: "_ZN3foo3barEv", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !6, scope: null, type: !13, declaration: !12) !23 = !DILocalVariable(name: "x", line: 4, arg: 1, scope: !5, file: !6, type: !9) !24 = !DILocation(line: 4, column: 15, scope: !5) !25 = !DILocation(line: 4, column: 20, scope: !26) diff --git a/test/DebugInfo/X86/pr12831.ll b/test/DebugInfo/X86/pr12831.ll index 082bb59e294..89f59983897 100644 --- a/test/DebugInfo/X86/pr12831.ll +++ b/test/DebugInfo/X86/pr12831.ll @@ -12,7 +12,7 @@ target triple = "x86_64-unknown-linux-gnu" @"_ZN8functionIFvvEEC1IZN17BPLFunctionWriter9writeExprEvE3$_1_0EET_" = internal alias void (%class.function*), void (%class.function*)* @"_ZN8functionIFvvEEC2IZN17BPLFunctionWriter9writeExprEvE3$_1_0EET_" @"_ZN8functionIFvvEEC1IZN17BPLFunctionWriter9writeExprEvE3$_0EET_" = internal alias void (%class.function*), void (%class.function*)* @"_ZN8functionIFvvEEC2IZN17BPLFunctionWriter9writeExprEvE3$_0EET_" -define void @_ZN17BPLFunctionWriter9writeExprEv(%class.BPLFunctionWriter* %this) nounwind uwtable align 2 { +define void @_ZN17BPLFunctionWriter9writeExprEv(%class.BPLFunctionWriter* %this) nounwind uwtable align 2 !dbg !5 { entry: %this.addr = alloca %class.BPLFunctionWriter*, align 8 %agg.tmp = alloca %class.function, align 1 @@ -81,7 +81,7 @@ entry: !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.2 ", isOptimized: false, emissionKind: 0, file: !161, enums: !1, retainedTypes: !1, subprograms: !3, globals: !128) !1 = !{} !3 = !{!5, !106, !107, !126, !127} -!5 = distinct !DISubprogram(name: "writeExpr", linkageName: "_ZN17BPLFunctionWriter9writeExprEv", line: 19, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 19, file: !6, scope: null, type: !7, function: void (%class.BPLFunctionWriter*)* @_ZN17BPLFunctionWriter9writeExprEv, declaration: !103, variables: !1) +!5 = distinct !DISubprogram(name: "writeExpr", linkageName: "_ZN17BPLFunctionWriter9writeExprEv", line: 19, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 19, file: !6, scope: null, type: !7, declaration: !103, variables: !1) !6 = !DIFile(filename: "BPLFunctionWriter2.ii", directory: "/home/peter/crashdelta") !7 = !DISubroutineType(types: !8) !8 = !{null, !9} @@ -156,8 +156,8 @@ entry: !99 = !DISubroutineType(types: !100) !100 = !{null} !103 = !DISubprogram(name: "writeExpr", linkageName: "_ZN17BPLFunctionWriter9writeExprEv", line: 17, isLocal: false, isDefinition: false, virtualIndex: 6, flags: DIFlagPrivate | DIFlagPrototyped, isOptimized: false, scopeLine: 17, file: !6, scope: !10, type: !7) -!106 = distinct !DISubprogram(name: "function<BPLFunctionWriter::<lambda at BPLFunctionWriter2.ii:23:36> >", linkageName: "_ZN8functionIFvvEEC2IZN17BPLFunctionWriter9writeExprEvE3$_1_0EET_", line: 8, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 8, file: !6, scope: null, type: !59, function: void (%class.function*)* @"_ZN8functionIFvvEEC2IZN17BPLFunctionWriter9writeExprEvE3$_1_0EET_", templateParams: !82, declaration: !58, variables: !1) -!107 = distinct !DISubprogram(name: "_M_not_empty_function<BPLFunctionWriter::<lambda at BPLFunctionWriter2.ii:23:36> >", linkageName: "_ZN13_Base_manager21_M_not_empty_functionIZN17BPLFunctionWriter9writeExprEvE3$_1_0EEvRKT_", line: 3, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !6, scope: null, type: !108, function: void (%class.anon.0*)* @"_ZN13_Base_manager21_M_not_empty_functionIZN17BPLFunctionWriter9writeExprEvE3$_1_0EEvRKT_", templateParams: !111, declaration: !113, variables: !1) +!106 = distinct !DISubprogram(name: "function<BPLFunctionWriter::<lambda at BPLFunctionWriter2.ii:23:36> >", linkageName: "_ZN8functionIFvvEEC2IZN17BPLFunctionWriter9writeExprEvE3$_1_0EET_", line: 8, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 8, file: !6, scope: null, type: !59, templateParams: !82, declaration: !58, variables: !1) +!107 = distinct !DISubprogram(name: "_M_not_empty_function<BPLFunctionWriter::<lambda at BPLFunctionWriter2.ii:23:36> >", linkageName: "_ZN13_Base_manager21_M_not_empty_functionIZN17BPLFunctionWriter9writeExprEvE3$_1_0EEvRKT_", line: 3, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !6, scope: null, type: !108, templateParams: !111, declaration: !113, variables: !1) !108 = !DISubroutineType(types: !109) !109 = !{null, !110} !110 = !DIDerivedType(tag: DW_TAG_reference_type, baseType: !61) @@ -172,8 +172,8 @@ entry: !119 = !DIDerivedType(tag: DW_TAG_reference_type, baseType: !26) !120 = !{!121} !121 = !DITemplateTypeParameter(name: "_Tp", type: !26) -!126 = distinct !DISubprogram(name: "function<BPLFunctionWriter::<lambda at BPLFunctionWriter2.ii:20:36> >", linkageName: "_ZN8functionIFvvEEC2IZN17BPLFunctionWriter9writeExprEvE3$_0EET_", line: 8, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 8, file: !6, scope: null, type: !23, function: void (%class.function*)* @"_ZN8functionIFvvEEC2IZN17BPLFunctionWriter9writeExprEvE3$_0EET_", templateParams: !47, declaration: !22, variables: !1) -!127 = distinct !DISubprogram(name: "_M_not_empty_function<BPLFunctionWriter::<lambda at BPLFunctionWriter2.ii:20:36> >", linkageName: "_ZN13_Base_manager21_M_not_empty_functionIZN17BPLFunctionWriter9writeExprEvE3$_0EEvRKT_", line: 3, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !6, scope: null, type: !117, function: void (%class.anon*)* @"_ZN13_Base_manager21_M_not_empty_functionIZN17BPLFunctionWriter9writeExprEvE3$_0EEvRKT_", templateParams: !120, declaration: !116, variables: !1) +!126 = distinct !DISubprogram(name: "function<BPLFunctionWriter::<lambda at BPLFunctionWriter2.ii:20:36> >", linkageName: "_ZN8functionIFvvEEC2IZN17BPLFunctionWriter9writeExprEvE3$_0EET_", line: 8, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 8, file: !6, scope: null, type: !23, templateParams: !47, declaration: !22, variables: !1) +!127 = distinct !DISubprogram(name: "_M_not_empty_function<BPLFunctionWriter::<lambda at BPLFunctionWriter2.ii:20:36> >", linkageName: "_ZN13_Base_manager21_M_not_empty_functionIZN17BPLFunctionWriter9writeExprEvE3$_0EEvRKT_", line: 3, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !6, scope: null, type: !117, templateParams: !120, declaration: !116, variables: !1) !128 = !{!130} !130 = !DIGlobalVariable(name: "__stored_locally", linkageName: "__stored_locally", line: 2, isLocal: true, isDefinition: true, scope: !114, file: !6, type: !131, variable: i1 1) !131 = !DIDerivedType(tag: DW_TAG_const_type, baseType: !132) diff --git a/test/DebugInfo/X86/pr13303.ll b/test/DebugInfo/X86/pr13303.ll index 8ffda095c10..a369b425958 100644 --- a/test/DebugInfo/X86/pr13303.ll +++ b/test/DebugInfo/X86/pr13303.ll @@ -5,7 +5,7 @@ ; Check that the prologue ends with is_stmt here. ; CHECK: 0x0000000000000000 {{.*}} is_stmt -define i32 @main() nounwind uwtable { +define i32 @main() nounwind uwtable !dbg !5 { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval @@ -18,7 +18,7 @@ entry: !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.2 (trunk 160143)", isOptimized: false, emissionKind: 0, file: !12, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !12, scope: !6, type: !7, function: i32 ()* @main, variables: !1) +!5 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !12, scope: !6, type: !7, variables: !1) !6 = !DIFile(filename: "PR13303.c", directory: "/home/probinson") !7 = !DISubroutineType(types: !8) !8 = !{!9} diff --git a/test/DebugInfo/X86/pr19307.ll b/test/DebugInfo/X86/pr19307.ll index a5658e70417..39a800704b1 100644 --- a/test/DebugInfo/X86/pr19307.ll +++ b/test/DebugInfo/X86/pr19307.ll @@ -35,7 +35,7 @@ target triple = "x86_64-unknown-linux-gnu" @.str = private unnamed_addr constant [7 x i8] c"items=\00", align 1 ; Function Attrs: uwtable -define void @_Z11parse_rangeRyS_Ss(i64* %offset, i64* %limit, %"class.std::basic_string"* %range) #0 { +define void @_Z11parse_rangeRyS_Ss(i64* %offset, i64* %limit, %"class.std::basic_string"* %range) #0 !dbg !13 { entry: %offset.addr = alloca i64*, align 8 %limit.addr = alloca i64*, align 8 @@ -97,7 +97,7 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !10 = !DINamespace(name: "std", line: 153, file: !11, scope: null) !11 = !DIFile(filename: "/usr/lib/gcc/x86_64-linux-gnu/4.6/../../../../include/c++/4.6/x86_64-linux-gnu/bits/c++config.h", directory: "/llvm_cmake_gcc") !12 = !{!13} -!13 = distinct !DISubprogram(name: "parse_range", linkageName: "_Z11parse_rangeRyS_Ss", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !14, type: !15, function: void (i64*, i64*, %"class.std::basic_string"*)* @_Z11parse_rangeRyS_Ss, variables: !2) +!13 = distinct !DISubprogram(name: "parse_range", linkageName: "_Z11parse_rangeRyS_Ss", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !14, type: !15, variables: !2) !14 = !DIFile(filename: "pr19307.cc", directory: "/llvm_cmake_gcc") !15 = !DISubroutineType(types: !16) !16 = !{null, !17, !17, !19} diff --git a/test/DebugInfo/X86/prologue-stack.ll b/test/DebugInfo/X86/prologue-stack.ll index 9b48c41e8a4..b3447d344e1 100644 --- a/test/DebugInfo/X86/prologue-stack.ll +++ b/test/DebugInfo/X86/prologue-stack.ll @@ -6,7 +6,7 @@ ; return 0; ; } -define i32 @isel_line_test2() nounwind uwtable { +define i32 @isel_line_test2() nounwind uwtable !dbg !5 { ; The stack adjustment should be part of the prologue. ; CHECK: isel_line_test2: ; CHECK: {{subq|leaq}} {{.*}}, %rsp @@ -24,7 +24,7 @@ declare i32 @callme(i32) !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.2 (trunk 164980) (llvm/trunk 164979)", isOptimized: false, emissionKind: 0, file: !13, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "isel_line_test2", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 4, file: !13, scope: !6, type: !7, function: i32 ()* @isel_line_test2, variables: !1) +!5 = distinct !DISubprogram(name: "isel_line_test2", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 4, file: !13, scope: !6, type: !7, variables: !1) !6 = !DIFile(filename: "bar.c", directory: "/usr/local/google/home/echristo/tmp") !7 = !DISubroutineType(types: !8) !8 = !{!9} diff --git a/test/DebugInfo/X86/reference-argument.ll b/test/DebugInfo/X86/reference-argument.ll index 7efe5c536c2..d45d04d1396 100644 --- a/test/DebugInfo/X86/reference-argument.ll +++ b/test/DebugInfo/X86/reference-argument.ll @@ -16,7 +16,7 @@ declare void @_Z3barR4SVal(%class.SVal* %v) declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 declare i32 @main() ; Function Attrs: nounwind ssp uwtable -define linkonce_odr void @_ZN1A3fooE4SVal(%class.A* %this, %class.SVal* %v) nounwind ssp uwtable align 2 { +define linkonce_odr void @_ZN1A3fooE4SVal(%class.A* %this, %class.SVal* %v) nounwind ssp uwtable align 2 !dbg !35 { entry: %this.addr = alloca %class.A*, align 8 store %class.A* %this, %class.A** %this.addr, align 8 @@ -36,7 +36,7 @@ declare void @_ZN4SValD2Ev(%class.SVal* %this) !1 = !DIFile(filename: "aggregate-indirect-arg.cpp", directory: "") !2 = !{} !3 = !{!4, !29, !33, !34, !35} -!4 = distinct !DISubprogram(name: "bar", linkageName: "_Z3barR4SVal", line: 19, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 19, file: !1, scope: !5, type: !6, function: void (%class.SVal*)* @_Z3barR4SVal, variables: !2) +!4 = distinct !DISubprogram(name: "bar", linkageName: "_Z3barR4SVal", line: 19, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 19, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "aggregate-indirect-arg.cpp", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{null, !8} @@ -58,13 +58,13 @@ declare void @_ZN4SValD2Ev(%class.SVal* %this) !25 = !{null, !19, !26} !26 = !DIDerivedType(tag: DW_TAG_reference_type, baseType: !27) !27 = !DIDerivedType(tag: DW_TAG_const_type, baseType: !9) -!29 = distinct !DISubprogram(name: "main", line: 25, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 25, file: !1, scope: !5, type: !30, function: i32 ()* @main, variables: !2) +!29 = distinct !DISubprogram(name: "main", line: 25, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 25, file: !1, scope: !5, type: !30, variables: !2) !30 = !DISubroutineType(types: !31) !31 = !{!32} !32 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!33 = distinct !DISubprogram(name: "~SVal", linkageName: "_ZN4SValD1Ev", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 14, file: !1, scope: null, type: !17, function: void (%class.SVal*)* @_ZN4SValD1Ev, declaration: !16, variables: !2) -!34 = distinct !DISubprogram(name: "~SVal", linkageName: "_ZN4SValD2Ev", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 14, file: !1, scope: null, type: !17, function: void (%class.SVal*)* @_ZN4SValD2Ev, declaration: !16, variables: !2) -!35 = distinct !DISubprogram(name: "foo", linkageName: "_ZN1A3fooE4SVal", line: 22, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 22, file: !1, scope: null, type: !36, function: void (%class.A*, %class.SVal*)* @_ZN1A3fooE4SVal, declaration: !41, variables: !2) +!33 = distinct !DISubprogram(name: "~SVal", linkageName: "_ZN4SValD1Ev", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 14, file: !1, scope: null, type: !17, declaration: !16, variables: !2) +!34 = distinct !DISubprogram(name: "~SVal", linkageName: "_ZN4SValD2Ev", line: 14, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 14, file: !1, scope: null, type: !17, declaration: !16, variables: !2) +!35 = distinct !DISubprogram(name: "foo", linkageName: "_ZN1A3fooE4SVal", line: 22, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 22, file: !1, scope: null, type: !36, declaration: !41, variables: !2) !36 = !DISubroutineType(types: !37) !37 = !{null, !38, !9} !38 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !39) diff --git a/test/DebugInfo/X86/rvalue-ref.ll b/test/DebugInfo/X86/rvalue-ref.ll index acccc240a9a..c72a3aa2c04 100644 --- a/test/DebugInfo/X86/rvalue-ref.ll +++ b/test/DebugInfo/X86/rvalue-ref.ll @@ -5,7 +5,7 @@ @.str = private unnamed_addr constant [4 x i8] c"%d\0A\00", align 1 -define void @_Z3fooOi(i32* %i) uwtable ssp { +define void @_Z3fooOi(i32* %i) uwtable ssp !dbg !5 { entry: %i.addr = alloca i32*, align 8 store i32* %i, i32** %i.addr, align 8 @@ -26,7 +26,7 @@ declare i32 @printf(i8*, ...) !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.2 (trunk 157054) (llvm/trunk 157060)", isOptimized: false, emissionKind: 0, file: !16, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooOi", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !16, scope: !6, type: !7, function: void (i32*)* @_Z3fooOi, variables: !1) +!5 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooOi", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !16, scope: !6, type: !7, variables: !1) !6 = !DIFile(filename: "foo.cpp", directory: "/Users/echristo/tmp") !7 = !DISubroutineType(types: !8) !8 = !{null, !9} diff --git a/test/DebugInfo/X86/sret.ll b/test/DebugInfo/X86/sret.ll index da73eb8ddc2..45af2821741 100644 --- a/test/DebugInfo/X86/sret.ll +++ b/test/DebugInfo/X86/sret.ll @@ -18,7 +18,7 @@ @_ZN1AC1ERKS_ = alias void (%class.A*, %class.A*), void (%class.A*, %class.A*)* @_ZN1AC2ERKS_ ; Function Attrs: nounwind uwtable -define void @_ZN1AC2Ei(%class.A* %this, i32 %i) unnamed_addr #0 align 2 { +define void @_ZN1AC2Ei(%class.A* %this, i32 %i) unnamed_addr #0 align 2 !dbg !49 { entry: %this.addr = alloca %class.A*, align 8 %i.addr = alloca i32, align 4 @@ -39,7 +39,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: nounwind uwtable -define void @_ZN1AC2ERKS_(%class.A* %this, %class.A* %rhs) unnamed_addr #0 align 2 { +define void @_ZN1AC2ERKS_(%class.A* %this, %class.A* %rhs) unnamed_addr #0 align 2 !dbg !50 { entry: %this.addr = alloca %class.A*, align 8 %rhs.addr = alloca %class.A*, align 8 @@ -59,7 +59,7 @@ entry: } ; Function Attrs: nounwind uwtable -define %class.A* @_ZN1AaSERKS_(%class.A* %this, %class.A* %rhs) #0 align 2 { +define %class.A* @_ZN1AaSERKS_(%class.A* %this, %class.A* %rhs) #0 align 2 !dbg !51 { entry: %this.addr = alloca %class.A*, align 8 %rhs.addr = alloca %class.A*, align 8 @@ -77,7 +77,7 @@ entry: } ; Function Attrs: nounwind uwtable -define i32 @_ZN1A7get_intEv(%class.A* %this) #0 align 2 { +define i32 @_ZN1A7get_intEv(%class.A* %this) #0 align 2 !dbg !52 { entry: %this.addr = alloca %class.A*, align 8 store %class.A* %this, %class.A** %this.addr, align 8 @@ -89,7 +89,7 @@ entry: } ; Function Attrs: uwtable -define void @_ZN1B9AInstanceEv(%class.A* noalias sret %agg.result, %class.B* %this) #2 align 2 { +define void @_ZN1B9AInstanceEv(%class.A* noalias sret %agg.result, %class.B* %this) #2 align 2 !dbg !53 { entry: %this.addr = alloca %class.B*, align 8 %nrvo = alloca i1 @@ -114,7 +114,7 @@ nrvo.skipdtor: ; preds = %nrvo.unused, %entry } ; Function Attrs: nounwind uwtable -define linkonce_odr void @_ZN1AD2Ev(%class.A* %this) unnamed_addr #0 align 2 { +define linkonce_odr void @_ZN1AD2Ev(%class.A* %this) unnamed_addr #0 align 2 !dbg !63 { entry: %this.addr = alloca %class.A*, align 8 store %class.A* %this, %class.A** %this.addr, align 8 @@ -124,7 +124,7 @@ entry: } ; Function Attrs: uwtable -define i32 @main(i32 %argc, i8** %argv) #2 personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) { +define i32 @main(i32 %argc, i8** %argv) #2 personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) !dbg !54 { entry: %retval = alloca i32, align 4 %argc.addr = alloca i32, align 4 @@ -189,7 +189,7 @@ terminate.lpad: ; preds = %lpad } ; Function Attrs: nounwind uwtable -define linkonce_odr void @_ZN1BC2Ev(%class.B* %this) unnamed_addr #0 align 2 { +define linkonce_odr void @_ZN1BC2Ev(%class.B* %this) unnamed_addr #0 align 2 !dbg !62 { entry: %this.addr = alloca %class.B*, align 8 store %class.B* %this, %class.B** %this.addr, align 8 @@ -212,7 +212,7 @@ declare i8* @__cxa_begin_catch(i8*) declare void @_ZSt9terminatev() ; Function Attrs: uwtable -define linkonce_odr void @_ZN1AD0Ev(%class.A* %this) unnamed_addr #2 align 2 personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) { +define linkonce_odr void @_ZN1AD0Ev(%class.A* %this) unnamed_addr #2 align 2 personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) !dbg !61 { entry: %this.addr = alloca %class.A*, align 8 %exn.slot = alloca i8* @@ -305,21 +305,21 @@ attributes #7 = { builtin nounwind } !45 = !DISubroutineType(types: !46) !46 = !{!4, !42} !48 = !{!49, !50, !51, !52, !53, !54, !61, !62, !63} -!49 = distinct !DISubprogram(name: "A", linkageName: "_ZN1AC2Ei", line: 16, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 18, file: !1, scope: !"_ZTS1A", type: !15, function: void (%class.A*, i32)* @_ZN1AC2Ei, declaration: !14, variables: !2) -!50 = distinct !DISubprogram(name: "A", linkageName: "_ZN1AC2ERKS_", line: 21, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 23, file: !1, scope: !"_ZTS1A", type: !20, function: void (%class.A*, %class.A*)* @_ZN1AC2ERKS_, declaration: !19, variables: !2) -!51 = distinct !DISubprogram(name: "operator=", linkageName: "_ZN1AaSERKS_", line: 27, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 28, file: !1, scope: !"_ZTS1A", type: !26, function: %class.A* (%class.A*, %class.A*)* @_ZN1AaSERKS_, declaration: !25, variables: !2) -!52 = distinct !DISubprogram(name: "get_int", linkageName: "_ZN1A7get_intEv", line: 33, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 34, file: !1, scope: !"_ZTS1A", type: !34, function: i32 (%class.A*)* @_ZN1A7get_intEv, declaration: !33, variables: !2) -!53 = distinct !DISubprogram(name: "AInstance", linkageName: "_ZN1B9AInstanceEv", line: 47, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 48, file: !1, scope: !"_ZTS1B", type: !45, function: void (%class.A*, %class.B*)* @_ZN1B9AInstanceEv, declaration: !44, variables: !2) -!54 = distinct !DISubprogram(name: "main", line: 53, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 54, file: !1, scope: !7, type: !55, function: i32 (i32, i8**)* @main, variables: !2) +!49 = distinct !DISubprogram(name: "A", linkageName: "_ZN1AC2Ei", line: 16, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 18, file: !1, scope: !"_ZTS1A", type: !15, declaration: !14, variables: !2) +!50 = distinct !DISubprogram(name: "A", linkageName: "_ZN1AC2ERKS_", line: 21, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 23, file: !1, scope: !"_ZTS1A", type: !20, declaration: !19, variables: !2) +!51 = distinct !DISubprogram(name: "operator=", linkageName: "_ZN1AaSERKS_", line: 27, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 28, file: !1, scope: !"_ZTS1A", type: !26, declaration: !25, variables: !2) +!52 = distinct !DISubprogram(name: "get_int", linkageName: "_ZN1A7get_intEv", line: 33, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 34, file: !1, scope: !"_ZTS1A", type: !34, declaration: !33, variables: !2) +!53 = distinct !DISubprogram(name: "AInstance", linkageName: "_ZN1B9AInstanceEv", line: 47, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 48, file: !1, scope: !"_ZTS1B", type: !45, declaration: !44, variables: !2) +!54 = distinct !DISubprogram(name: "main", line: 53, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 54, file: !1, scope: !7, type: !55, variables: !2) !55 = !DISubroutineType(types: !56) !56 = !{!12, !12, !57} !57 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !58) !58 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !59) !59 = !DIDerivedType(tag: DW_TAG_const_type, baseType: !60) !60 = !DIBasicType(tag: DW_TAG_base_type, name: "char", size: 8, align: 8, encoding: DW_ATE_signed_char) -!61 = distinct !DISubprogram(name: "~A", linkageName: "_ZN1AD0Ev", line: 8, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 8, file: !1, scope: !"_ZTS1A", type: !30, function: void (%class.A*)* @_ZN1AD0Ev, declaration: !29, variables: !2) -!62 = distinct !DISubprogram(name: "B", linkageName: "_ZN1BC2Ev", line: 41, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 41, file: !1, scope: !"_ZTS1B", type: !40, function: void (%class.B*)* @_ZN1BC2Ev, declaration: !39, variables: !2) -!63 = distinct !DISubprogram(name: "~A", linkageName: "_ZN1AD2Ev", line: 8, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 8, file: !1, scope: !"_ZTS1A", type: !30, function: void (%class.A*)* @_ZN1AD2Ev, declaration: !29, variables: !2) +!61 = distinct !DISubprogram(name: "~A", linkageName: "_ZN1AD0Ev", line: 8, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 8, file: !1, scope: !"_ZTS1A", type: !30, declaration: !29, variables: !2) +!62 = distinct !DISubprogram(name: "B", linkageName: "_ZN1BC2Ev", line: 41, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 41, file: !1, scope: !"_ZTS1B", type: !40, declaration: !39, variables: !2) +!63 = distinct !DISubprogram(name: "~A", linkageName: "_ZN1AD2Ev", line: 8, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 8, file: !1, scope: !"_ZTS1A", type: !30, declaration: !29, variables: !2) !64 = !{i32 2, !"Dwarf Version", i32 4} !65 = !{i32 1, !"Debug Info Version", i32 3} !66 = !{!"clang version 3.5.0 (trunk 203283) (llvm/trunk 203307)"} diff --git a/test/DebugInfo/X86/sroasplit-1.ll b/test/DebugInfo/X86/sroasplit-1.ll index 7f241e7c3ee..11895a7f083 100644 --- a/test/DebugInfo/X86/sroasplit-1.ll +++ b/test/DebugInfo/X86/sroasplit-1.ll @@ -36,7 +36,7 @@ target triple = "x86_64-apple-macosx10.9.0" %struct.Inner = type { i32, i64 } ; Function Attrs: nounwind ssp uwtable -define i32 @foo(%struct.Outer* byval align 8 %outer) #0 { +define i32 @foo(%struct.Outer* byval align 8 %outer) #0 !dbg !4 { entry: %i1 = alloca %struct.Inner, align 8 call void @llvm.dbg.declare(metadata %struct.Outer* %outer, metadata !25, metadata !2), !dbg !26 @@ -69,7 +69,7 @@ attributes #2 = { nounwind } !1 = !DIFile(filename: "sroasplit-1.c", directory: "") !2 = !DIExpression() !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !1, scope: !5, type: !6, function: i32 (%struct.Outer*)* @foo, variables: !{}) +!4 = distinct !DISubprogram(name: "foo", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !1, scope: !5, type: !6, variables: !{}) !5 = !DIFile(filename: "sroasplit-1.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8, !9} diff --git a/test/DebugInfo/X86/sroasplit-2.ll b/test/DebugInfo/X86/sroasplit-2.ll index 0c981f23af7..bea1b26df28 100644 --- a/test/DebugInfo/X86/sroasplit-2.ll +++ b/test/DebugInfo/X86/sroasplit-2.ll @@ -37,7 +37,7 @@ target triple = "x86_64-apple-macosx10.9.0" %struct.Inner = type { i32, i32 } ; Function Attrs: nounwind ssp uwtable -define i32 @foo(i64 %outer.coerce0, i64 %outer.coerce1) #0 { +define i32 @foo(i64 %outer.coerce0, i64 %outer.coerce1) #0 !dbg !4 { %outer = alloca %struct.Outer, align 8 %i1 = alloca %struct.Inner, align 4 %1 = bitcast %struct.Outer* %outer to { i64, i64 }* @@ -75,7 +75,7 @@ attributes #2 = { nounwind } !1 = !DIFile(filename: "sroasplit-2.c", directory: "") !2 = !DIExpression() !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !1, scope: !5, type: !6, function: i32 (i64, i64)* @foo, variables: !{}) +!4 = distinct !DISubprogram(name: "foo", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !1, scope: !5, type: !6, variables: !{}) !5 = !DIFile(filename: "sroasplit-2.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8, !9} diff --git a/test/DebugInfo/X86/sroasplit-3.ll b/test/DebugInfo/X86/sroasplit-3.ll index 94db9c5712b..7a39beb137d 100644 --- a/test/DebugInfo/X86/sroasplit-3.ll +++ b/test/DebugInfo/X86/sroasplit-3.ll @@ -20,7 +20,7 @@ target triple = "x86_64-apple-macosx10.10.0" %struct.S = type { float } ; Function Attrs: nounwind ssp uwtable -define float @foo(float %s.coerce) #0 { +define float @foo(float %s.coerce) #0 !dbg !4 { entry: %s = alloca %struct.S, align 4 %coerce.dive = getelementptr %struct.S, %struct.S* %s, i32 0, i32 0 @@ -45,7 +45,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "test.c", directory: "/Volumes/Data/llvm/_build.ninja.debug") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, function: float (float)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "test.c", directory: "/Volumes/Data/llvm/_build.ninja.debug") !6 = !DISubroutineType(types: !7) !7 = !{!8, !9} diff --git a/test/DebugInfo/X86/sroasplit-4.ll b/test/DebugInfo/X86/sroasplit-4.ll index 994df0dab0c..2abf6e1ec9b 100644 --- a/test/DebugInfo/X86/sroasplit-4.ll +++ b/test/DebugInfo/X86/sroasplit-4.ll @@ -45,7 +45,7 @@ target triple = "x86_64-apple-darwin" @t = external global i64 ; Function Attrs: nounwind -define i32 @_Z4testv() #0 { +define i32 @_Z4testv() #0 !dbg !17 { entry: %retval = alloca i32, align 4 %y = alloca %struct.p, align 8 @@ -126,7 +126,7 @@ attributes #3 = { nounwind } !14 = !DIDerivedType(tag: DW_TAG_member, name: "x", line: 10, size: 128, align: 64, offset: 64, file: !5, scope: !"_ZTS1r", baseType: !"_ZTS1p") !15 = !DIDerivedType(tag: DW_TAG_member, name: "y", line: 11, size: 128, align: 64, offset: 192, file: !5, scope: !"_ZTS1r", baseType: !"_ZTS1p") !16 = !{!17} -!17 = distinct !DISubprogram(name: "test", linkageName: "_Z4testv", line: 18, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 18, file: !5, scope: !18, type: !19, function: i32 ()* @_Z4testv, variables: !2) +!17 = distinct !DISubprogram(name: "test", linkageName: "_Z4testv", line: 18, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 18, file: !5, scope: !18, type: !19, variables: !2) !18 = !DIFile(filename: "pr22393.cc", directory: "") !19 = !DISubroutineType(types: !20) !20 = !{!13} diff --git a/test/DebugInfo/X86/sroasplit-5.ll b/test/DebugInfo/X86/sroasplit-5.ll index 6be74317341..059cb19e92e 100644 --- a/test/DebugInfo/X86/sroasplit-5.ll +++ b/test/DebugInfo/X86/sroasplit-5.ll @@ -27,7 +27,7 @@ target triple = "x86_64-unknown-linux-gnu" %struct.prog_src_register = type { i32, i24 } ; Function Attrs: nounwind -define i64 @src_reg_for_float() #0 { +define i64 @src_reg_for_float() #0 !dbg !4 { entry: %retval = alloca %struct.prog_src_register, align 4 %a = alloca %struct.prog_src_register, align 4 @@ -70,7 +70,7 @@ attributes #2 = { nounwind } !1 = !DIFile(filename: "<stdin>", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "src_reg_for_float", line: 7, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 7, file: !5, scope: !6, type: !7, function: i64 ()* @src_reg_for_float, variables: !2) +!4 = distinct !DISubprogram(name: "src_reg_for_float", line: 7, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 7, file: !5, scope: !6, type: !7, variables: !2) !5 = !DIFile(filename: "pr22495.c", directory: "") !6 = !DIFile(filename: "pr22495.c", directory: "") !7 = !DISubroutineType(types: !8) diff --git a/test/DebugInfo/X86/stmt-list-multiple-compile-units.ll b/test/DebugInfo/X86/stmt-list-multiple-compile-units.ll index 1bf13d8cfc8..a366853ad20 100644 --- a/test/DebugInfo/X86/stmt-list-multiple-compile-units.ll +++ b/test/DebugInfo/X86/stmt-list-multiple-compile-units.ll @@ -58,7 +58,7 @@ ; ASM-NOT: Lcu_begin ; ASM: Lset[[LT:[0-9]+]] = Lline_table_start0-Lsection_line ## DW_AT_stmt_list ; ASM-NEXT: .long Lset[[LT]] -define i32 @test(i32 %a) nounwind uwtable ssp { +define i32 @test(i32 %a) nounwind uwtable ssp !dbg !5 { entry: %a.addr = alloca i32, align 4 store i32 %a, i32* %a.addr, align 4 @@ -70,7 +70,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone -define i32 @fn(i32 %a) nounwind uwtable ssp { +define i32 @fn(i32 %a) nounwind uwtable ssp !dbg !13 { entry: %a.addr = alloca i32, align 4 store i32 %a, i32* %a.addr, align 4 @@ -84,14 +84,14 @@ entry: !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.3", isOptimized: false, emissionKind: 1, file: !23, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "test", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !23, scope: !6, type: !7, function: i32 (i32)* @test, variables: !1) +!5 = distinct !DISubprogram(name: "test", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !23, scope: !6, type: !7, variables: !1) !6 = !DIFile(filename: "simple.c", directory: "/private/tmp") !7 = !DISubroutineType(types: !8) !8 = !{!9, !9} !9 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !10 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.3 (trunk 172862)", isOptimized: false, emissionKind: 1, file: !24, enums: !1, retainedTypes: !1, subprograms: !11, globals: !1, imports: !1) !11 = !{!13} -!13 = distinct !DISubprogram(name: "fn", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !24, scope: !14, type: !7, function: i32 (i32)* @fn, variables: !1) +!13 = distinct !DISubprogram(name: "fn", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !24, scope: !14, type: !7, variables: !1) !14 = !DIFile(filename: "simple2.c", directory: "/private/tmp") !15 = !DILocalVariable(name: "a", line: 2, arg: 1, scope: !5, file: !6, type: !9) !16 = !DILocation(line: 2, scope: !5) diff --git a/test/DebugInfo/X86/stmt-list.ll b/test/DebugInfo/X86/stmt-list.ll index ea1ed53bdd5..393e1b50ea8 100644 --- a/test/DebugInfo/X86/stmt-list.ll +++ b/test/DebugInfo/X86/stmt-list.ll @@ -5,7 +5,7 @@ ; CHECK: .section .debug_line,"",@progbits ; CHECK-NEXT: .Lline_table_start0: -define void @f() { +define void @f() !dbg !0 { entry: ret void } @@ -14,7 +14,7 @@ entry: !llvm.module.flags = !{!7} !5 = !{!0} -!0 = distinct !DISubprogram(name: "f", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !6, scope: !1, type: !3, function: void ()* @f) +!0 = distinct !DISubprogram(name: "f", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !6, scope: !1, type: !3) !1 = !DIFile(filename: "test2.c", directory: "/home/espindola/llvm") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 ()", isOptimized: true, emissionKind: 0, file: !6, enums: !{}, retainedTypes: !{}, subprograms: !5) !3 = !DISubroutineType(types: !4) diff --git a/test/DebugInfo/X86/subrange-type.ll b/test/DebugInfo/X86/subrange-type.ll index d268a2c6e7b..7a81bac56d0 100644 --- a/test/DebugInfo/X86/subrange-type.ll +++ b/test/DebugInfo/X86/subrange-type.ll @@ -7,7 +7,7 @@ ; CHECK: [[SUBTYPE]]: DW_TAG_base_type ; CHECK-NEXT: DW_AT_name -define i32 @main() nounwind uwtable { +define i32 @main() nounwind uwtable !dbg !5 { entry: %retval = alloca i32, align 4 %i = alloca [2 x i32], align 4 @@ -24,7 +24,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.3 (trunk 171472) (llvm/trunk 171487)", isOptimized: false, emissionKind: 0, file: !17, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1, imports: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "main", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !6, scope: !6, type: !7, function: i32 ()* @main, variables: !1) +!5 = distinct !DISubprogram(name: "main", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !6, scope: !6, type: !7, variables: !1) !6 = !DIFile(filename: "foo.c", directory: "/usr/local/google/home/echristo/tmp") !7 = !DISubroutineType(types: !8) !8 = !{!9} diff --git a/test/DebugInfo/X86/subreg.ll b/test/DebugInfo/X86/subreg.ll index b720ae8e3c4..3b95532ff52 100644 --- a/test/DebugInfo/X86/subreg.ll +++ b/test/DebugInfo/X86/subreg.ll @@ -7,7 +7,7 @@ ; CHECK-NEXT: .byte 147 # DW_OP_piece ; CHECK-NEXT: .byte 2 # 2 -define i16 @f(i16 signext %zzz) nounwind { +define i16 @f(i16 signext %zzz) nounwind !dbg !1 { entry: call void @llvm.dbg.value(metadata i16 %zzz, i64 0, metadata !0, metadata !DIExpression()), !dbg !DILocation(scope: !1) %conv = sext i16 %zzz to i32, !dbg !7 @@ -22,7 +22,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !9 = !{!1} !0 = !DILocalVariable(name: "zzz", line: 3, arg: 1, scope: !1, file: !2, type: !6) -!1 = distinct !DISubprogram(name: "f", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !10, scope: !2, type: !4, function: i16 (i16)* @f) +!1 = distinct !DISubprogram(name: "f", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !10, scope: !2, type: !4) !2 = !DIFile(filename: "/home/espindola/llvm/test.c", directory: "/home/espindola/tmpfs/build") !3 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 ()", isOptimized: false, emissionKind: 1, file: !10, enums: !{}, retainedTypes: !{}, subprograms: !9, imports: null) !4 = !DISubroutineType(types: !5) diff --git a/test/DebugInfo/X86/subregisters.ll b/test/DebugInfo/X86/subregisters.ll index 4b012cef277..9dcb09f0869 100644 --- a/test/DebugInfo/X86/subregisters.ll +++ b/test/DebugInfo/X86/subregisters.ll @@ -38,7 +38,7 @@ target triple = "x86_64-apple-macosx10.9.0" @main.myBar = private unnamed_addr constant %struct.bar { i32 3, i32 4 }, align 4 ; Function Attrs: noinline nounwind ssp uwtable -define void @doSomething(%struct.bar* nocapture readonly %b) #0 { +define void @doSomething(%struct.bar* nocapture readonly %b) #0 !dbg !4 { entry: tail call void @llvm.dbg.value(metadata %struct.bar* %b, i64 0, metadata !15, metadata !DIExpression()), !dbg !25 %a1 = getelementptr inbounds %struct.bar, %struct.bar* %b, i64 0, i32 0, !dbg !26 @@ -55,7 +55,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 declare i32 @printf(i8* nocapture readonly, ...) #2 ; Function Attrs: nounwind ssp uwtable -define i32 @main() #3 { +define i32 @main() #3 !dbg !17 { entry: %myBar = alloca i64, align 8, !dbg !34 %tmpcast = bitcast i64* %myBar to %struct.bar*, !dbg !34 @@ -82,7 +82,7 @@ attributes #4 = { nounwind } !1 = !DIFile(filename: "subregisters.c", directory: "") !2 = !{} !3 = !{!4, !17} -!4 = distinct !DISubprogram(name: "doSomething", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 11, file: !1, scope: !5, type: !6, function: void (%struct.bar*)* @doSomething, variables: !14) +!4 = distinct !DISubprogram(name: "doSomething", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 11, file: !1, scope: !5, type: !6, variables: !14) !5 = !DIFile(filename: "subregisters.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{null, !8} @@ -95,7 +95,7 @@ attributes #4 = { nounwind } !14 = !{!15, !16} !15 = !DILocalVariable(name: "b", line: 10, arg: 1, scope: !4, file: !5, type: !8) !16 = !DILocalVariable(name: "a", line: 12, scope: !4, file: !5, type: !12) -!17 = distinct !DISubprogram(name: "main", line: 16, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 17, file: !1, scope: !5, type: !18, function: i32 ()* @main, variables: !20) +!17 = distinct !DISubprogram(name: "main", line: 16, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 17, file: !1, scope: !5, type: !18, variables: !20) !18 = !DISubroutineType(types: !19) !19 = !{!12} !20 = !{!21} diff --git a/test/DebugInfo/X86/template.ll b/test/DebugInfo/X86/template.ll index 5cd04d1d4fb..d7ce08437ca 100644 --- a/test/DebugInfo/X86/template.ll +++ b/test/DebugInfo/X86/template.ll @@ -64,7 +64,7 @@ @n = global %"struct.y_impl<int>::nested" zeroinitializer, align 1 @llvm.global_ctors = appending global [1 x { i32, void ()*, i8* }] [{ i32, void ()*, i8* } { i32 65535, void ()* @_GLOBAL__sub_I_template.cpp, i8* null }] -define internal void @__cxx_global_var_init() section ".text.startup" { +define internal void @__cxx_global_var_init() section ".text.startup" !dbg !10 { entry: %call = call i32 @_Z4funcILi3EXadL_Z4glblEE6y_implLDn0EJLi1ELi2EEEiv(), !dbg !36 store i32 %call, i32* @glbl, align 4, !dbg !36 @@ -72,7 +72,7 @@ entry: } ; Function Attrs: nounwind uwtable -define linkonce_odr i32 @_Z4funcILi3EXadL_Z4glblEE6y_implLDn0EJLi1ELi2EEEiv() #0 { +define linkonce_odr i32 @_Z4funcILi3EXadL_Z4glblEE6y_implLDn0EJLi1ELi2EEEiv() #0 !dbg !14 { entry: ret i32 3, !dbg !37 } @@ -99,11 +99,11 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe !7 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !8 = !DICompositeType(tag: DW_TAG_structure_type, name: "nested", line: 2, size: 8, align: 8, file: !1, scope: !"_ZTS6y_implIiE", elements: !2, identifier: "_ZTSN6y_implIiE6nestedE") !9 = !{!10, !14, !28} -!10 = distinct !DISubprogram(name: "__cxx_global_var_init", line: 3, isLocal: true, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !11, type: !12, function: void ()* @__cxx_global_var_init, variables: !2) +!10 = distinct !DISubprogram(name: "__cxx_global_var_init", line: 3, isLocal: true, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !11, type: !12, variables: !2) !11 = !DIFile(filename: "template.cpp", directory: "/tmp/dbginfo") !12 = !DISubroutineType(types: !13) !13 = !{null} -!14 = distinct !DISubprogram(name: "func<3, &glbl, y_impl, nullptr, 1, 2>", linkageName: "_Z4funcILi3EXadL_Z4glblEE6y_implLDn0EJLi1ELi2EEEiv", line: 1, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !11, type: !15, function: i32 ()* @_Z4funcILi3EXadL_Z4glblEE6y_implLDn0EJLi1ELi2EEEiv, templateParams: !17, variables: !2) +!14 = distinct !DISubprogram(name: "func<3, &glbl, y_impl, nullptr, 1, 2>", linkageName: "_Z4funcILi3EXadL_Z4glblEE6y_implLDn0EJLi1ELi2EEEiv", line: 1, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !11, type: !15, templateParams: !17, variables: !2) !15 = !DISubroutineType(types: !16) !16 = !{!7} !17 = !{!18, !19, !21, !22, !24} @@ -117,7 +117,7 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe !25 = !{!26, !27} !26 = !DITemplateValueParameter(tag: DW_TAG_template_value_parameter, type: !7, value: i32 1) !27 = !DITemplateValueParameter(tag: DW_TAG_template_value_parameter, type: !7, value: i32 2) -!28 = distinct !DISubprogram(name: "", linkageName: "_GLOBAL__sub_I_template.cpp", isLocal: true, isDefinition: true, flags: DIFlagArtificial, isOptimized: false, file: !1, scope: !11, type: !29, function: void ()* @_GLOBAL__sub_I_template.cpp, variables: !2) +!28 = distinct !DISubprogram(name: "", linkageName: "_GLOBAL__sub_I_template.cpp", isLocal: true, isDefinition: true, flags: DIFlagArtificial, isOptimized: false, file: !1, scope: !11, type: !29, variables: !2) !29 = !DISubroutineType(types: !2) !30 = !{!31, !32} !31 = !DIGlobalVariable(name: "glbl", line: 3, isLocal: false, isDefinition: true, scope: null, file: !11, type: !7, variable: i32* @glbl) diff --git a/test/DebugInfo/X86/tls.ll b/test/DebugInfo/X86/tls.ll index 7d54e4ae465..754ed25debc 100644 --- a/test/DebugInfo/X86/tls.ll +++ b/test/DebugInfo/X86/tls.ll @@ -100,7 +100,7 @@ @glbl = global i32 0, align 4 ; Function Attrs: nounwind uwtable -define weak_odr i32 @_Z4funcIXadL_Z4glblEEEiv() #0 { +define weak_odr i32 @_Z4funcIXadL_Z4glblEEEiv() #0 !dbg !4 { entry: ret i32 0, !dbg !18 } @@ -115,7 +115,7 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe !1 = !DIFile(filename: "tls.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "func<&glbl>", linkageName: "_Z4funcIXadL_Z4glblEEEiv", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !6, function: i32 ()* @_Z4funcIXadL_Z4glblEEEiv, templateParams: !9, variables: !2) +!4 = distinct !DISubprogram(name: "func<&glbl>", linkageName: "_Z4funcIXadL_Z4glblEEEiv", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !6, templateParams: !9, variables: !2) !5 = !DIFile(filename: "tls.cpp", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/DebugInfo/X86/union-const.ll b/test/DebugInfo/X86/union-const.ll index f6af2edad62..1d3969aff52 100644 --- a/test/DebugInfo/X86/union-const.ll +++ b/test/DebugInfo/X86/union-const.ll @@ -20,7 +20,7 @@ target triple = "x86_64-apple-macosx10.10.0" %struct.anon = type { i32 } ; Function Attrs: nounwind readnone ssp uwtable -define i32 @mfi_aen_setup() #0 { +define i32 @mfi_aen_setup() #0 !dbg !4 { entry: tail call void @llvm.dbg.declare(metadata %union.mfi_evt* undef, metadata !16, metadata !21), !dbg !22 tail call void @llvm.dbg.value(metadata i32 0, i64 0, metadata !16, metadata !21), !dbg !22 @@ -44,7 +44,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "union.c", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "mfi_aen_setup", line: 5, isLocal: false, isDefinition: true, isOptimized: true, scopeLine: 5, file: !1, scope: !5, type: !6, function: i32 ()* @mfi_aen_setup, variables: !15) +!4 = distinct !DISubprogram(name: "mfi_aen_setup", line: 5, isLocal: false, isDefinition: true, isOptimized: true, scopeLine: 5, file: !1, scope: !5, type: !6, variables: !15) !5 = !DIFile(filename: "union.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/DebugInfo/X86/union-template.ll b/test/DebugInfo/X86/union-template.ll index c7f018104b4..1f91f2a129f 100644 --- a/test/DebugInfo/X86/union-template.ll +++ b/test/DebugInfo/X86/union-template.ll @@ -11,7 +11,7 @@ @_ZN7PR156371fE = global %"union.PR15637::Value" zeroinitializer, align 4 -define void @_ZN7PR156371gEf(float %value) #0 { +define void @_ZN7PR156371gEf(float %value) #0 !dbg !4 { entry: %value.addr = alloca float, align 4 %tempValue = alloca %"union.PR15637::Value", align 4 @@ -33,7 +33,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "foo.cc", directory: "/usr/local/google/home/echristo/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "g", linkageName: "_ZN7PR156371gEf", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, function: void (float)* @_ZN7PR156371gEf, variables: !2) +!4 = distinct !DISubprogram(name: "g", linkageName: "_ZN7PR156371gEf", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !2) !5 = !DINamespace(name: "PR15637", line: 1, file: !1, scope: null) !6 = !DISubroutineType(types: !7) !7 = !{null, !8} diff --git a/test/DebugInfo/X86/vla.ll b/test/DebugInfo/X86/vla.ll index 70afb4e9813..68d40ae5d33 100644 --- a/test/DebugInfo/X86/vla.ll +++ b/test/DebugInfo/X86/vla.ll @@ -21,7 +21,7 @@ target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f3 target triple = "x86_64-apple-macosx10.8.0" ; Function Attrs: nounwind ssp uwtable -define i32 @vla(i32 %n) nounwind ssp uwtable { +define i32 @vla(i32 %n) nounwind ssp uwtable !dbg !4 { entry: %n.addr = alloca i32, align 4 %saved_stack = alloca i8* @@ -57,7 +57,7 @@ declare i8* @llvm.stacksave() nounwind declare void @llvm.stackrestore(i8*) nounwind ; Function Attrs: nounwind ssp uwtable -define i32 @main(i32 %argc, i8** %argv) nounwind ssp uwtable { +define i32 @main(i32 %argc, i8** %argv) nounwind ssp uwtable !dbg !9 { entry: %retval = alloca i32, align 4 %argc.addr = alloca i32, align 4 @@ -79,12 +79,12 @@ entry: !1 = !DIFile(filename: "vla.c", directory: "") !2 = !{} !3 = !{!4, !9} -!4 = distinct !DISubprogram(name: "vla", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 (i32)* @vla, variables: !2) +!4 = distinct !DISubprogram(name: "vla", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "vla.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} !8 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!9 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !5, type: !10, function: i32 (i32, i8**)* @main, variables: !2) +!9 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !5, type: !10, variables: !2) !10 = !DISubroutineType(types: !11) !11 = !{!8, !8, !12} !12 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !13) diff --git a/test/Instrumentation/AddressSanitizer/debug_info.ll b/test/Instrumentation/AddressSanitizer/debug_info.ll index d30b5ac9f2e..0834d642df8 100644 --- a/test/Instrumentation/AddressSanitizer/debug_info.ll +++ b/test/Instrumentation/AddressSanitizer/debug_info.ll @@ -6,7 +6,7 @@ target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128" target triple = "x86_64-unknown-linux-gnu" -define i32 @_Z3zzzi(i32 %p) nounwind uwtable sanitize_address { +define i32 @_Z3zzzi(i32 %p) nounwind uwtable sanitize_address !dbg !5 { entry: %p.addr = alloca i32, align 4 %r = alloca i32, align 4 @@ -36,7 +36,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.3 (trunk 169314)", isOptimized: true, emissionKind: 0, file: !16, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1) !1 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "zzz", linkageName: "_Z3zzzi", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !16, scope: !6, type: !7, function: i32 (i32)* @_Z3zzzi, variables: !1) +!5 = distinct !DISubprogram(name: "zzz", linkageName: "_Z3zzzi", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !16, scope: !6, type: !7, variables: !1) !6 = !DIFile(filename: "a.cc", directory: "/usr/local/google/llvm_cmake_clang/tmp/debuginfo") !7 = !DISubroutineType(types: !8) !8 = !{!9, !9} diff --git a/test/Instrumentation/DataFlowSanitizer/debug.ll b/test/Instrumentation/DataFlowSanitizer/debug.ll index 9946bee3157..8fac157afd4 100644 --- a/test/Instrumentation/DataFlowSanitizer/debug.ll +++ b/test/Instrumentation/DataFlowSanitizer/debug.ll @@ -1,6 +1,7 @@ ; RUN: opt < %s -dfsan -dfsan-abilist=%S/Inputs/debuglist.txt -S | FileCheck %s -; CHECK: !DISubprogram(name: "main",{{.*}} function: i32 ()* @main{{[,)]}} +; CHECK: define i32 @main() {{.*}} !dbg [[SP:![0-9]+]] +; CHECK: [[SP]] = distinct !DISubprogram(name: "main" ; Generated from a simple source file compiled with clang -g: ; int main() { @@ -10,7 +11,7 @@ target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-unknown-linux-gnu" ; Function Attrs: nounwind uwtable -define i32 @main() #0 { +define i32 @main() #0 !dbg !4 { entry: ret i32 0, !dbg !12 } @@ -25,7 +26,7 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe !1 = !DIFile(filename: "debug.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !2) +!4 = distinct !DISubprogram(name: "main", line: 1, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "debug.cpp", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/Instrumentation/MemorySanitizer/store-origin.ll b/test/Instrumentation/MemorySanitizer/store-origin.ll index de97760dade..42bfac20822 100644 --- a/test/Instrumentation/MemorySanitizer/store-origin.ll +++ b/test/Instrumentation/MemorySanitizer/store-origin.ll @@ -9,7 +9,7 @@ target triple = "x86_64-unknown-linux-gnu" ; Check that debug info for origin propagation code is set correctly. ; Function Attrs: nounwind -define void @Store(i32* nocapture %p, i32 %x) #0 { +define void @Store(i32* nocapture %p, i32 %x) #0 !dbg !4 { entry: tail call void @llvm.dbg.value(metadata i32* %p, i64 0, metadata !11, metadata !DIExpression()), !dbg !16 tail call void @llvm.dbg.value(metadata i32 %x, i64 0, metadata !12, metadata !DIExpression()), !dbg !16 @@ -31,7 +31,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "../2.cc", directory: "/tmp/build0") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "Store", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !1, scope: !5, type: !6, function: void (i32*, i32)* @Store, variables: !10) +!4 = distinct !DISubprogram(name: "Store", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !10) !5 = !DIFile(filename: "../2.cc", directory: "/tmp/build0") !6 = !DISubroutineType(types: !7) !7 = !{null, !8, !9} diff --git a/test/Instrumentation/SanitizerCoverage/coverage-dbg.ll b/test/Instrumentation/SanitizerCoverage/coverage-dbg.ll index b312f02924b..93d0f881625 100644 --- a/test/Instrumentation/SanitizerCoverage/coverage-dbg.ll +++ b/test/Instrumentation/SanitizerCoverage/coverage-dbg.ll @@ -25,7 +25,7 @@ target triple = "x86_64-unknown-linux-gnu" %struct.A = type { i32 } ; Function Attrs: nounwind readonly uwtable -define i32 @_ZN1A1fEv(%struct.A* nocapture readonly %this) #0 align 2 { +define i32 @_ZN1A1fEv(%struct.A* nocapture readonly %this) #0 align 2 !dbg !13 { entry: tail call void @llvm.dbg.value(metadata %struct.A* %this, i64 0, metadata !15, metadata !DIExpression()), !dbg !20 %x = getelementptr inbounds %struct.A, %struct.A* %this, i64 0, i32 0, !dbg !21 @@ -56,7 +56,7 @@ attributes #1 = { nounwind readnone } !10 = !{!7, !11} !11 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS1A") !12 = !{!13} -!13 = distinct !DISubprogram(name: "f", linkageName: "_ZN1A1fEv", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 6, file: !1, scope: !"_ZTS1A", type: !9, function: i32 (%struct.A*)* @_ZN1A1fEv, declaration: !8, variables: !14) +!13 = distinct !DISubprogram(name: "f", linkageName: "_ZN1A1fEv", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 6, file: !1, scope: !"_ZTS1A", type: !9, declaration: !8, variables: !14) !14 = !{!15} !15 = !DILocalVariable(name: "this", arg: 1, flags: DIFlagArtificial | DIFlagObjectPointer, scope: !13, type: !16) !16 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !"_ZTS1A") diff --git a/test/Instrumentation/SanitizerCoverage/coverage2-dbg.ll b/test/Instrumentation/SanitizerCoverage/coverage2-dbg.ll index 699813ae903..8c330ea5bdd 100644 --- a/test/Instrumentation/SanitizerCoverage/coverage2-dbg.ll +++ b/test/Instrumentation/SanitizerCoverage/coverage2-dbg.ll @@ -25,7 +25,7 @@ target triple = "x86_64-unknown-linux-gnu" ; CHECK: [[B]] = !DILocation(line: 3, column: 5, scope: !{{.*}}) ; CHECK: [[C]] = !DILocation(line: 4, column: 1, scope: !{{.*}}) -define void @_Z3fooPi(i32* %a) #0 { +define void @_Z3fooPi(i32* %a) #0 !dbg !4 { entry: tail call void @llvm.dbg.value(metadata i32* %a, i64 0, metadata !11, metadata !DIExpression()), !dbg !15 %tobool = icmp eq i32* %a, null, !dbg !16 @@ -53,7 +53,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "if.cc", directory: "FOO") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooPi", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !1, scope: !5, type: !6, function: void (i32*)* @_Z3fooPi, variables: !10) +!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooPi", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !10) !5 = !DIFile(filename: "if.cc", directory: "FOO") !6 = !DISubroutineType(types: !7) !7 = !{null, !8} diff --git a/test/JitListener/multiple.ll b/test/JitListener/multiple.ll index 235a62a14b7..1f69ddae4f5 100644 --- a/test/JitListener/multiple.ll +++ b/test/JitListener/multiple.ll @@ -50,7 +50,7 @@ ; ModuleID = 'multiple.c' ; Function Attrs: nounwind uwtable -define i32 @foo(i32 %a) #0 { +define i32 @foo(i32 %a) #0 !dbg !4 { entry: %a.addr = alloca i32, align 4 store i32 %a, i32* %a.addr, align 4 @@ -63,7 +63,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: nounwind uwtable -define i32 @bar(i32 %a) #0 { +define i32 @bar(i32 %a) #0 !dbg !9 { entry: %retval = alloca i32, align 4 %a.addr = alloca i32, align 4 @@ -89,7 +89,7 @@ return: ; preds = %if.end, %if.then } ; Function Attrs: nounwind uwtable -define i32 @fubar(i32 %a) #0 { +define i32 @fubar(i32 %a) #0 !dbg !10 { entry: %retval = alloca i32, align 4 %a.addr = alloca i32, align 4 @@ -129,13 +129,13 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "multiple.c", directory: "F:\5Cusers\5Cakaylor\5Cllvm-s\5Cllvm\5Ctest\5CJitListener") !2 = !{} !3 = !{!4, !9, !10} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "multiple.c", directory: "F:CusersCakaylorCllvm-sCllvmCtestCJitListener") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} !8 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!9 = distinct !DISubprogram(name: "bar", line: 5, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !6, function: i32 (i32)* @bar, variables: !2) -!10 = distinct !DISubprogram(name: "fubar", line: 12, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 12, file: !1, scope: !5, type: !6, function: i32 (i32)* @fubar, variables: !2) +!9 = distinct !DISubprogram(name: "bar", line: 5, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !1, scope: !5, type: !6, variables: !2) +!10 = distinct !DISubprogram(name: "fubar", line: 12, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 12, file: !1, scope: !5, type: !6, variables: !2) !11 = !{i32 2, !"Dwarf Version", i32 4} !12 = !{i32 2, !"Debug Info Version", i32 3} !13 = !{i32 1, !"PIC Level", i32 2} diff --git a/test/JitListener/simple.ll b/test/JitListener/simple.ll index da46dc80be0..bfa11b7e533 100644 --- a/test/JitListener/simple.ll +++ b/test/JitListener/simple.ll @@ -16,7 +16,7 @@ ; ModuleID = 'simple.c' ; Function Attrs: nounwind uwtable -define i32 @foo(i32 %a) #0 { +define i32 @foo(i32 %a) #0 !dbg !4 { entry: %a.addr = alloca i32, align 4 store i32 %a, i32* %a.addr, align 4 @@ -39,7 +39,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "simple.c", directory: "F:\5Cusers\5Cakaylor\5Cllvm-s\5Cllvm\5Ctest\5CJitListener") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "simple.c", directory: "F:CusersCakaylorCllvm-sCllvmCtestCJitListener") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} diff --git a/test/Linker/2011-08-04-DebugLoc.ll b/test/Linker/2011-08-04-DebugLoc.ll index cce88ff2d2a..71e89a5072e 100644 --- a/test/Linker/2011-08-04-DebugLoc.ll +++ b/test/Linker/2011-08-04-DebugLoc.ll @@ -9,7 +9,7 @@ target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64" target triple = "x86_64-apple-macosx10.7.0" -define i32 @foo() nounwind ssp { +define i32 @foo() nounwind ssp !dbg !1 { ret i32 42, !dbg !6 } @@ -18,7 +18,7 @@ define i32 @foo() nounwind ssp { !llvm.dbg.sp = !{!1} !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "Apple clang version 3.0 (tags/Apple/clang-209.11) (based on LLVM 3.0svn)", isOptimized: true, emissionKind: 0, file: !8, enums: !9, retainedTypes: !9, subprograms: !10) -!1 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !8, scope: !2, type: !3, function: i32 ()* @foo) +!1 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !8, scope: !2, type: !3) !2 = !DIFile(filename: "a.c", directory: "/private/tmp") !3 = !DISubroutineType(types: !4) !4 = !{!5} diff --git a/test/Linker/2011-08-04-DebugLoc2.ll b/test/Linker/2011-08-04-DebugLoc2.ll index 8b23cbb7d65..c5f77ac69cd 100644 --- a/test/Linker/2011-08-04-DebugLoc2.ll +++ b/test/Linker/2011-08-04-DebugLoc2.ll @@ -6,7 +6,7 @@ target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64" target triple = "x86_64-apple-macosx10.7.0" -define i32 @bar() nounwind ssp { +define i32 @bar() nounwind ssp !dbg !1 { ret i32 21, !dbg !6 } @@ -15,7 +15,7 @@ define i32 @bar() nounwind ssp { !llvm.dbg.sp = !{!1} !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "Apple clang version 3.0 (tags/Apple/clang-209.11) (based on LLVM 3.0svn)", isOptimized: true, emissionKind: 0, file: !8, enums: !9, retainedTypes: !9, subprograms: !10) -!1 = distinct !DISubprogram(name: "bar", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !8, scope: !2, type: !3, function: i32 ()* @bar) +!1 = distinct !DISubprogram(name: "bar", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !8, scope: !2, type: !3) !2 = !DIFile(filename: "b.c", directory: "/private/tmp") !3 = !DISubroutineType(types: !4) !4 = !{!5} diff --git a/test/Linker/2011-08-04-Metadata.ll b/test/Linker/2011-08-04-Metadata.ll index 6d88f5b3309..a685142ab71 100644 --- a/test/Linker/2011-08-04-Metadata.ll +++ b/test/Linker/2011-08-04-Metadata.ll @@ -13,7 +13,7 @@ target triple = "x86_64-apple-macosx10.7.0" @x = internal global i32 0, align 4 -define void @foo() nounwind uwtable ssp { +define void @foo() nounwind uwtable ssp !dbg !1 { entry: store i32 1, i32* @x, align 4, !dbg !7 ret void, !dbg !7 @@ -25,7 +25,7 @@ entry: !llvm.dbg.gv = !{!5} !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 ()", isOptimized: true, emissionKind: 0, file: !9, enums: !{}, retainedTypes: !{}, subprograms: !10) -!1 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !9, scope: !2, type: !3, function: void ()* @foo) +!1 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !9, scope: !2, type: !3) !2 = !DIFile(filename: "/tmp/one.c", directory: "/Volumes/Lalgate/Slate/D") !3 = !DISubroutineType(types: !4) !4 = !{null} diff --git a/test/Linker/2011-08-04-Metadata2.ll b/test/Linker/2011-08-04-Metadata2.ll index 1bd12347d1c..07baebff4f4 100644 --- a/test/Linker/2011-08-04-Metadata2.ll +++ b/test/Linker/2011-08-04-Metadata2.ll @@ -8,7 +8,7 @@ target triple = "x86_64-apple-macosx10.7.0" @x = internal global i32 0, align 4 -define void @bar() nounwind uwtable ssp { +define void @bar() nounwind uwtable ssp !dbg !1 { entry: store i32 1, i32* @x, align 4, !dbg !7 ret void, !dbg !7 @@ -20,7 +20,7 @@ entry: !llvm.dbg.gv = !{!5} !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 ()", isOptimized: true, emissionKind: 0, file: !9, enums: !{}, retainedTypes: !{}, subprograms: !10) -!1 = distinct !DISubprogram(name: "bar", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !9, scope: !2, type: !3, function: void ()* @bar) +!1 = distinct !DISubprogram(name: "bar", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !9, scope: !2, type: !3) !2 = !DIFile(filename: "/tmp/two.c", directory: "/Volumes/Lalgate/Slate/D") !3 = !DISubroutineType(types: !4) !4 = !{null} diff --git a/test/Linker/2011-08-18-unique-class-type.ll b/test/Linker/2011-08-18-unique-class-type.ll index ec5246c9f5b..e466bceb0cd 100644 --- a/test/Linker/2011-08-18-unique-class-type.ll +++ b/test/Linker/2011-08-18-unique-class-type.ll @@ -8,7 +8,7 @@ target triple = "x86_64-apple-macosx10.7.0" %"class.N1::A" = type { i8 } -define void @_Z3fooN2N11AE() nounwind uwtable ssp { +define void @_Z3fooN2N11AE() nounwind uwtable ssp !dbg !5 { entry: %mya = alloca %"class.N1::A", align 1 call void @llvm.dbg.declare(metadata %"class.N1::A"* %mya, metadata !9, metadata !DIExpression()), !dbg !13 @@ -24,7 +24,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !1 = !{!2} !2 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooN2N11AE", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !16, scope: !6, type: !7, function: void ()* @_Z3fooN2N11AE) +!5 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooN2N11AE", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !16, scope: !6, type: !7) !6 = !DIFile(filename: "n1.c", directory: "/private/tmp") !7 = !DISubroutineType(types: !8) !8 = !{null} diff --git a/test/Linker/2011-08-18-unique-class-type2.ll b/test/Linker/2011-08-18-unique-class-type2.ll index 92f21bbf412..8821dd37fad 100644 --- a/test/Linker/2011-08-18-unique-class-type2.ll +++ b/test/Linker/2011-08-18-unique-class-type2.ll @@ -6,7 +6,7 @@ target triple = "x86_64-apple-macosx10.7.0" %"class.N1::A" = type { i8 } -define void @_Z3barN2N11AE() nounwind uwtable ssp { +define void @_Z3barN2N11AE() nounwind uwtable ssp !dbg !5 { entry: %youra = alloca %"class.N1::A", align 1 call void @llvm.dbg.declare(metadata %"class.N1::A"* %youra, metadata !9, metadata !DIExpression()), !dbg !13 @@ -22,7 +22,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !1 = !{!2} !2 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "bar", linkageName: "_Z3barN2N11AE", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scope: !6, type: !7, function: void ()* @_Z3barN2N11AE) +!5 = distinct !DISubprogram(name: "bar", linkageName: "_Z3barN2N11AE", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scope: !6, type: !7) !6 = !DIFile(filename: "n2.c", directory: "/private/tmp") !7 = !DISubroutineType(types: !8) !8 = !{null} diff --git a/test/Linker/2011-08-18-unique-debug-type.ll b/test/Linker/2011-08-18-unique-debug-type.ll index 1836c576946..11a1c4ecb73 100644 --- a/test/Linker/2011-08-18-unique-debug-type.ll +++ b/test/Linker/2011-08-18-unique-debug-type.ll @@ -4,7 +4,7 @@ target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64" target triple = "x86_64-apple-macosx10.7.0" -define i32 @foo() nounwind uwtable ssp { +define i32 @foo() nounwind uwtable ssp !dbg !5 { entry: ret i32 1, !dbg !10 } @@ -16,7 +16,7 @@ entry: !1 = !{!2} !2 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !12, scope: !6, type: !7, function: i32 ()* @foo) +!5 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !12, scope: !6, type: !7) !6 = !DIFile(filename: "one.c", directory: "/private/tmp") !7 = !DISubroutineType(types: !8) !8 = !{!9} diff --git a/test/Linker/2011-08-18-unique-debug-type2.ll b/test/Linker/2011-08-18-unique-debug-type2.ll index 4c012dce0df..5b68ba0bf29 100644 --- a/test/Linker/2011-08-18-unique-debug-type2.ll +++ b/test/Linker/2011-08-18-unique-debug-type2.ll @@ -4,7 +4,7 @@ target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64" target triple = "x86_64-apple-macosx10.7.0" -define i32 @bar() nounwind uwtable ssp { +define i32 @bar() nounwind uwtable ssp !dbg !5 { entry: ret i32 2, !dbg !10 } @@ -16,7 +16,7 @@ entry: !1 = !{!2} !2 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "bar", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !12, scope: !6, type: !7, function: i32 ()* @bar) +!5 = distinct !DISubprogram(name: "bar", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !12, scope: !6, type: !7) !6 = !DIFile(filename: "two.c", directory: "/private/tmp") !7 = !DISubroutineType(types: !8) !8 = !{!9} diff --git a/test/Linker/DbgDeclare.ll b/test/Linker/DbgDeclare.ll index 3f89e889e05..23c00a32dbc 100644 --- a/test/Linker/DbgDeclare.ll +++ b/test/Linker/DbgDeclare.ll @@ -14,7 +14,7 @@ target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128" target triple = "x86_64-apple-macosx10.9.0" -define i32 @main(i32 %argc, i8** %argv) uwtable ssp { +define i32 @main(i32 %argc, i8** %argv) uwtable ssp !dbg !5 { entry: %retval = alloca i32, align 4 %argc.addr = alloca i32, align 4 @@ -40,7 +40,7 @@ declare void @test(i32, i8**) !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.3 (trunk 173515)", isOptimized: true, emissionKind: 0, file: !20, enums: !2, retainedTypes: !2, subprograms: !3, globals: !2) !2 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "main", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !20, scope: null, type: !7, function: i32 (i32, i8**)* @main, variables: !2) +!5 = distinct !DISubprogram(name: "main", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !20, scope: null, type: !7, variables: !2) !6 = !DIFile(filename: "main.cpp", directory: "/private/tmp") !7 = !DISubroutineType(types: !8) !8 = !{!9, !9, !10} diff --git a/test/Linker/DbgDeclare2.ll b/test/Linker/DbgDeclare2.ll index f3bd85cb087..2335f126d8e 100644 --- a/test/Linker/DbgDeclare2.ll +++ b/test/Linker/DbgDeclare2.ll @@ -5,7 +5,7 @@ target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128" target triple = "x86_64-apple-macosx10.9.0" -define void @test(i32 %argc, i8** %argv) uwtable ssp { +define void @test(i32 %argc, i8** %argv) uwtable ssp !dbg !5 { entry: %argc.addr = alloca i32, align 4 %argv.addr = alloca i8**, align 8 @@ -53,7 +53,7 @@ declare i32 @puts(i8*) !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.3 (trunk 173515)", isOptimized: true, emissionKind: 0, file: !25, enums: !2, retainedTypes: !2, subprograms: !3, globals: !2) !2 = !{} !3 = !{!5} -!5 = distinct !DISubprogram(name: "print_args", linkageName: "test", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !26, scope: null, type: !7, function: void (i32, i8**)* @test, variables: !2) +!5 = distinct !DISubprogram(name: "print_args", linkageName: "test", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 5, file: !26, scope: null, type: !7, variables: !2) !6 = !DIFile(filename: "test.cpp", directory: "/private/tmp") !7 = !DISubroutineType(types: !8) !8 = !{null, !9, !10} diff --git a/test/Linker/Inputs/replaced-function-matches-first-subprogram.ll b/test/Linker/Inputs/replaced-function-matches-first-subprogram.ll index c7d4f560fa7..a817cf07107 100644 --- a/test/Linker/Inputs/replaced-function-matches-first-subprogram.ll +++ b/test/Linker/Inputs/replaced-function-matches-first-subprogram.ll @@ -1,6 +1,6 @@ %struct.Class = type { i8 } -define weak_odr i32 @_ZN5ClassIiE3fooEv(%struct.Class* %this) align 2 { +define weak_odr i32 @_ZN5ClassIiE3fooEv(%struct.Class* %this) align 2 !dbg !4 { entry: %this.addr = alloca %struct.Class*, align 8 store %struct.Class* %this, %struct.Class** %this.addr, align 8 @@ -16,7 +16,7 @@ entry: !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, function: i32 (%struct.Class*)* @_ZN5ClassIiE3fooEv, variables: !2) +!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) !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 8fcb00c36e2..5e6627d90c9 100644 --- a/test/Linker/Inputs/subprogram-linkonce-weak.ll +++ b/test/Linker/Inputs/subprogram-linkonce-weak.ll @@ -1,4 +1,4 @@ -define weak i32 @foo(i32 %a, i32 %b) { +define weak i32 @foo(i32 %a, i32 %b) !dbg !3 { entry: %sum = call i32 @fastadd(i32 %a, i32 %b), !dbg !DILocation(line: 52, scope: !3) ret i32 %sum, !dbg !DILocation(line: 53, scope: !3) @@ -12,5 +12,5 @@ declare i32 @fastadd(i32, i32) !llvm.dbg.cu = !{!1} !1 = distinct !DICompileUnit(language: DW_LANG_C99, file: !2, subprograms: !{!3}, emissionKind: 1) !2 = !DIFile(filename: "foo.c", directory: "/path/to/dir") -!3 = distinct !DISubprogram(file: !2, scope: !2, line: 51, name: "foo", function: i32 (i32, i32)* @foo, type: !4) +!3 = distinct !DISubprogram(file: !2, scope: !2, line: 51, name: "foo", type: !4) !4 = !DISubroutineType(types: !{}) diff --git a/test/Linker/Inputs/type-unique-inheritance-a.ll b/test/Linker/Inputs/type-unique-inheritance-a.ll index ca9aba09e6b..0a1c107580b 100644 --- a/test/Linker/Inputs/type-unique-inheritance-a.ll +++ b/test/Linker/Inputs/type-unique-inheritance-a.ll @@ -47,7 +47,7 @@ %class.Base = type { i32 } ; Function Attrs: nounwind ssp uwtable -define void @_Z1fi(i32 %a) #0 { +define void @_Z1fi(i32 %a) #0 !dbg !15 { entry: %a.addr = alloca i32, align 4 %t = alloca %class.A, align 4 @@ -81,7 +81,7 @@ attributes #1 = { nounwind readnone } !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, function: void (i32)* @_Z1fi, variables: !2) +!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) !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 011d8d91f76..e87b96b9c79 100644 --- a/test/Linker/Inputs/type-unique-inheritance-b.ll +++ b/test/Linker/Inputs/type-unique-inheritance-b.ll @@ -5,7 +5,7 @@ %class.Base = type { i32 } ; Function Attrs: nounwind ssp uwtable -define void @_Z1gi(i32 %a) #0 { +define void @_Z1gi(i32 %a) #0 !dbg !20 { entry: %a.addr = alloca i32, align 4 %t = alloca %class.B, align 8 @@ -19,7 +19,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: ssp uwtable -define i32 @main() #2 { +define i32 @main() #2 !dbg !24 { entry: %retval = alloca i32, align 4 %a = alloca %class.A, align 4 @@ -60,11 +60,11 @@ attributes #3 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !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, function: void (i32)* @_Z1gi, variables: !2) +!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) !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, function: i32 ()* @main, variables: !2) +!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) !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 cc0f85ab808..2a52e89b6fd 100644 --- a/test/Linker/Inputs/type-unique-simple2-a.ll +++ b/test/Linker/Inputs/type-unique-simple2-a.ll @@ -44,7 +44,7 @@ %struct.Base = type { i32, %struct.Base* } ; Function Attrs: nounwind ssp uwtable -define void @_Z1fi(i32 %a) #0 { +define void @_Z1fi(i32 %a) #0 !dbg !12 { entry: %a.addr = alloca i32, align 4 %t = alloca %struct.Base, align 8 @@ -75,7 +75,7 @@ attributes #1 = { nounwind readnone } !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, function: void (i32)* @_Z1fi, variables: !2) +!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) !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 d87e41db4db..7e1c6aabd9a 100644 --- a/test/Linker/Inputs/type-unique-simple2-b.ll +++ b/test/Linker/Inputs/type-unique-simple2-b.ll @@ -3,7 +3,7 @@ %struct.Base = type { i32, %struct.Base* } ; Function Attrs: nounwind ssp uwtable -define void @_Z1gi(i32 %a) #0 { +define void @_Z1gi(i32 %a) #0 !dbg !12 { entry: %a.addr = alloca i32, align 4 %t = alloca %struct.Base, align 8 @@ -17,7 +17,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: ssp uwtable -define i32 @main() #2 { +define i32 @main() #2 !dbg !16 { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval @@ -48,11 +48,11 @@ attributes #3 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !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, function: void (i32)* @_Z1gi, variables: !2) +!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) !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, function: i32 ()* @main, variables: !2) +!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) !17 = !DISubroutineType(types: !18) !18 = !{!8} !19 = !{i32 2, !"Dwarf Version", i32 2} diff --git a/test/Linker/replaced-function-matches-first-subprogram.ll b/test/Linker/replaced-function-matches-first-subprogram.ll index 793a64563ed..30b8be992bb 100644 --- a/test/Linker/replaced-function-matches-first-subprogram.ll +++ b/test/Linker/replaced-function-matches-first-subprogram.ll @@ -15,17 +15,18 @@ %struct.Class = type { i8 } -define i32 @_Z3foov() { +; CHECK: define i32 @_Z3foov(){{.*}} !dbg ![[SP1:[0-9]+]] +define i32 @_Z3foov() !dbg !4 { entry: %tmp = alloca %struct.Class, align 1 %call = call i32 @_ZN5ClassIiE3fooEv(%struct.Class* %tmp), !dbg !14 ret i32 %call, !dbg !14 } -; CHECK: define weak_odr i32 @_ZN5ClassIiE3fooEv(%struct.Class* %this){{.*}}{ +; CHECK: define weak_odr i32 @_ZN5ClassIiE3fooEv(%struct.Class* %this){{.*}} !dbg ![[SP2:[0-9]+]] { ; CHECK-NOT: } ; CHECK: !dbg ![[LOC:[0-9]+]] -define linkonce_odr i32 @_ZN5ClassIiE3fooEv(%struct.Class* %this) align 2 { +define linkonce_odr i32 @_ZN5ClassIiE3fooEv(%struct.Class* %this) align 2 !dbg !7 { entry: %this.addr = alloca %struct.Class*, align 8 store %struct.Class* %this, %struct.Class** %this.addr, align 8 @@ -47,22 +48,20 @@ entry: ; Extract out each compile unit's single subprogram. The replaced subprogram's ; function should drop to null in the first compile unit. -; CHECK-DAG: ![[SPs1]] = !{![[SP1:[0-9]+]], ![[SP2r:[0-9]+]]} -; CHECK-DAG: ![[SPs2]] = !{![[SP2:[0-9]+]]} +; CHECK-DAG: ![[SPs1]] = !{![[SP1]], ![[SP2r:[0-9]+]]} +; CHECK-DAG: ![[SPs2]] = !{![[SP2]]} !3 = !{!4, !7} -!4 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, function: i32 ()* @_Z3foov, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "t1.cpp", directory: "/Users/dexonsmith/data/llvm/staging/test/Linker/repro/d1") !6 = !DISubroutineType(types: !2) -; Extract out the file from the replaced subprogram. Confirm that each -; subprogram is pointing at the correct function. -; CHECK-DAG: ![[SP1]] = distinct !DISubprogram({{.*}} function: i32 ()* @_Z3foov -; CHECK-DAG: ![[SP2]] = distinct !DISubprogram({{.*}} file: ![[FILE:[0-9]+]],{{.*}} function: i32 (%struct.Class*)* @_ZN5ClassIiE3fooEv +; Extract out the file from the replaced subprogram. +; CHECK-DAG: ![[SP2]] = distinct !DISubprogram({{.*}} file: ![[FILE:[0-9]+]], ; We can't use CHECK-NOT/CHECK-SAME with a CHECK-DAG, so rely on field order to ; prove that there's no function: here. ; CHECK-DAG: ![[SP2r]] = {{.*}}!DISubprogram({{.*}} isOptimized: false, variables: -!7 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !8, scope: !9, type: !6, function: i32 (%struct.Class*)* @_ZN5ClassIiE3fooEv, variables: !2) +!7 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !8, scope: !9, type: !6, variables: !2) ; The new subprogram should be pointing at the new directory. ; CHECK-DAG: ![[FILE]] = !DIFile(filename: "../t.h", directory: "/Users/dexonsmith/data/llvm/staging/test/Linker/repro/d2") diff --git a/test/Linker/subprogram-linkonce-weak.ll b/test/Linker/subprogram-linkonce-weak.ll index 78a576d7635..e8bc67765bb 100644 --- a/test/Linker/subprogram-linkonce-weak.ll +++ b/test/Linker/subprogram-linkonce-weak.ll @@ -17,29 +17,29 @@ ; The WL prefix means weak (the other file) first, then linkonce (this file). ; We'll see @bar before @foo if this file is first. -; LW-LABEL: define i32 @bar( +; LW: define i32 @bar({{.*}} !dbg ![[BARSP:[0-9]+]] ; LW: %sum = add i32 %a, %b, !dbg ![[FOOINBAR:[0-9]+]] ; LW: ret i32 %sum, !dbg ![[BARRET:[0-9]+]] -; LW-LABEL: define weak i32 @foo( +; LW: define weak i32 @foo({{.*}} !dbg ![[WEAKFOOSP:[0-9]+]] ; LW: %sum = call i32 @fastadd(i32 %a, i32 %b), !dbg ![[FOOCALL:[0-9]+]] ; LW: ret i32 %sum, !dbg ![[FOORET:[0-9]+]] ; We'll see @foo before @bar if this file is second. -; WL-LABEL: define weak i32 @foo( +; WL: define weak i32 @foo({{.*}} !dbg ![[WEAKFOOSP:[0-9]+]] ; WL: %sum = call i32 @fastadd(i32 %a, i32 %b), !dbg ![[FOOCALL:[0-9]+]] ; WL: ret i32 %sum, !dbg ![[FOORET:[0-9]+]] -; WL-LABEL: define i32 @bar( +; WL: define i32 @bar({{.*}} !dbg ![[BARSP:[0-9]+]] ; WL: %sum = add i32 %a, %b, !dbg ![[FOOINBAR:[0-9]+]] ; WL: ret i32 %sum, !dbg ![[BARRET:[0-9]+]] -define i32 @bar(i32 %a, i32 %b) { +define i32 @bar(i32 %a, i32 %b) !dbg !3 { entry: %sum = add i32 %a, %b, !dbg !DILocation(line: 2, scope: !4, inlinedAt: !DILocation(line: 12, scope: !3)) ret i32 %sum, !dbg !DILocation(line: 13, scope: !3) } -define linkonce i32 @foo(i32 %a, i32 %b) { +define linkonce i32 @foo(i32 %a, i32 %b) !dbg !4 { entry: %sum = add i32 %a, %b, !dbg !DILocation(line: 2, scope: !4) ret i32 %sum, !dbg !DILocation(line: 3, scope: !4) @@ -54,16 +54,12 @@ entry: !llvm.dbg.cu = !{!1} ; LW: ![[LCU]] = distinct !DICompileUnit({{.*}} subprograms: ![[LSPs:[0-9]+]] -; LW: ![[LSPs]] = !{![[BARSP:[0-9]+]], ![[FOOSP:[0-9]+]]} +; LW: ![[LSPs]] = !{![[BARSP]], ![[FOOSP:[0-9]+]]} ; LW: ![[BARSP]] = distinct !DISubprogram(name: "bar", -; LW-SAME: function: i32 (i32, i32)* @bar ; LW: ![[FOOSP]] = distinct !DISubprogram(name: "foo", -; LW-NOT: function: -; LW-SAME: ){{$}} ; LW: ![[WCU]] = distinct !DICompileUnit({{.*}} subprograms: ![[WSPs:[0-9]+]] -; LW: ![[WSPs]] = !{![[WEAKFOOSP:[0-9]+]]} +; LW: ![[WSPs]] = !{![[WEAKFOOSP]]} ; LW: ![[WEAKFOOSP]] = distinct !DISubprogram(name: "foo", -; LW-SAME: function: i32 (i32, i32)* @foo ; LW: ![[FOOINBAR]] = !DILocation(line: 2, scope: ![[FOOSP]], inlinedAt: ![[BARIA:[0-9]+]]) ; LW: ![[BARIA]] = !DILocation(line: 12, scope: ![[BARSP]]) ; LW: ![[BARRET]] = !DILocation(line: 13, scope: ![[BARSP]]) @@ -72,16 +68,12 @@ entry: ; Same as above, but reordered. ; WL: ![[WCU]] = distinct !DICompileUnit({{.*}} subprograms: ![[WSPs:[0-9]+]] -; WL: ![[WSPs]] = !{![[WEAKFOOSP:[0-9]+]]} +; WL: ![[WSPs]] = !{![[WEAKFOOSP]]} ; WL: ![[WEAKFOOSP]] = distinct !DISubprogram(name: "foo", -; WL-SAME: function: i32 (i32, i32)* @foo ; WL: ![[LCU]] = distinct !DICompileUnit({{.*}} subprograms: ![[LSPs:[0-9]+]] ; WL: ![[LSPs]] = !{![[BARSP:[0-9]+]], ![[FOOSP:[0-9]+]]} ; WL: ![[BARSP]] = distinct !DISubprogram(name: "bar", -; WL-SAME: function: i32 (i32, i32)* @bar ; WL: ![[FOOSP]] = distinct !DISubprogram(name: "foo", -; Note, for symmetry, this should be "NOT: function:" and "SAME: ){{$}}". -; WL-SAME: function: i32 (i32, i32)* @foo ; WL: ![[FOOCALL]] = !DILocation(line: 52, scope: ![[WEAKFOOSP]]) ; WL: ![[FOORET]] = !DILocation(line: 53, scope: ![[WEAKFOOSP]]) ; WL: ![[FOOINBAR]] = !DILocation(line: 2, scope: ![[FOOSP]], inlinedAt: ![[BARIA:[0-9]+]]) @@ -90,8 +82,8 @@ entry: !1 = distinct !DICompileUnit(language: DW_LANG_C99, file: !2, subprograms: !{!3, !4}, emissionKind: 1) !2 = !DIFile(filename: "bar.c", directory: "/path/to/dir") -!3 = distinct !DISubprogram(file: !2, scope: !2, line: 11, name: "bar", function: i32 (i32, i32)* @bar, type: !5) -!4 = distinct !DISubprogram(file: !2, scope: !2, line: 1, name: "foo", function: i32 (i32, i32)* @foo, type: !5) +!3 = distinct !DISubprogram(file: !2, scope: !2, line: 11, name: "bar", type: !5) +!4 = distinct !DISubprogram(file: !2, scope: !2, line: 1, name: "foo", type: !5) !5 = !DISubroutineType(types: !{}) ; Crasher for llc. diff --git a/test/Linker/type-unique-odr-a.ll b/test/Linker/type-unique-odr-a.ll index 7dec8608949..d7d978c2d3d 100644 --- a/test/Linker/type-unique-odr-a.ll +++ b/test/Linker/type-unique-odr-a.ll @@ -49,14 +49,14 @@ %class.A = type { i32 } ; Function Attrs: nounwind -define void @_Z3bazv() #0 { +define void @_Z3bazv() #0 !dbg !15 { entry: call void @_ZL3barv(), !dbg !23 ret void, !dbg !23 } ; Function Attrs: nounwind -define internal void @_ZL3barv() #0 { +define internal void @_ZL3barv() #0 !dbg !19 { entry: %a = alloca %class.A, align 4 call void @llvm.dbg.declare(metadata %class.A* %a, metadata !24, metadata !DIExpression()), !dbg !25 @@ -87,11 +87,11 @@ attributes #1 = { nounwind readnone } !11 = !{null, !12} !12 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS1A") !14 = !{!15, !19} -!15 = distinct !DISubprogram(name: "baz", linkageName: "_Z3bazv", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 11, file: !5, scope: !16, type: !17, function: void ()* @_Z3bazv, variables: !2) +!15 = distinct !DISubprogram(name: "baz", linkageName: "_Z3bazv", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 11, file: !5, scope: !16, type: !17, variables: !2) !16 = !DIFile(filename: "type-unique-odr-a.cpp", directory: "") !17 = !DISubroutineType(types: !18) !18 = !{null} -!19 = distinct !DISubprogram(name: "bar", linkageName: "_ZL3barv", line: 7, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !5, scope: !16, type: !17, function: void ()* @_ZL3barv, variables: !2) +!19 = distinct !DISubprogram(name: "bar", linkageName: "_ZL3barv", line: 7, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !5, scope: !16, type: !17, variables: !2) !20 = !{i32 2, !"Dwarf Version", i32 4} !21 = !{i32 1, !"Debug Info Version", i32 3} !22 = !{!"clang version 3.5.0 "} diff --git a/test/Linker/type-unique-odr-b.ll b/test/Linker/type-unique-odr-b.ll index fe45b29d3a8..714bb314c90 100644 --- a/test/Linker/type-unique-odr-b.ll +++ b/test/Linker/type-unique-odr-b.ll @@ -22,7 +22,7 @@ %class.A = type { i32 } ; Function Attrs: nounwind -define void @_ZN1A6getFooEv(%class.A* %this) #0 align 2 { +define void @_ZN1A6getFooEv(%class.A* %this) #0 align 2 !dbg !15 { entry: %this.addr = alloca %class.A*, align 8 store %class.A* %this, %class.A** %this.addr, align 8 @@ -35,14 +35,14 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: nounwind -define void @_Z1fv() #0 { +define void @_Z1fv() #0 !dbg !16 { entry: call void @_ZL3barv(), !dbg !28 ret void, !dbg !28 } ; Function Attrs: nounwind -define internal void @_ZL3barv() #0 { +define internal void @_ZL3barv() #0 !dbg !20 { entry: ret void, !dbg !29 } @@ -68,12 +68,12 @@ attributes #1 = { nounwind readnone } !11 = !{null, !12} !12 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS1A") !14 = !{!15, !16, !20} -!15 = distinct !DISubprogram(name: "getFoo", linkageName: "_ZN1A6getFooEv", line: 8, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 8, file: !5, scope: !"_ZTS1A", type: !10, function: void (%class.A*)* @_ZN1A6getFooEv, declaration: !9, variables: !2) -!16 = distinct !DISubprogram(name: "f", linkageName: "_Z1fv", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 11, file: !5, scope: !17, type: !18, function: void ()* @_Z1fv, variables: !2) +!15 = distinct !DISubprogram(name: "getFoo", linkageName: "_ZN1A6getFooEv", line: 8, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 8, file: !5, scope: !"_ZTS1A", type: !10, declaration: !9, variables: !2) +!16 = distinct !DISubprogram(name: "f", linkageName: "_Z1fv", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 11, file: !5, scope: !17, type: !18, variables: !2) !17 = !DIFile(filename: "type-unique-odr-b.cpp", directory: "") !18 = !DISubroutineType(types: !19) !19 = !{null} -!20 = distinct !DISubprogram(name: "bar", linkageName: "_ZL3barv", line: 10, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !5, scope: !17, type: !18, function: void ()* @_ZL3barv, variables: !2) +!20 = distinct !DISubprogram(name: "bar", linkageName: "_ZL3barv", line: 10, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !5, scope: !17, type: !18, variables: !2) !21 = !{i32 2, !"Dwarf Version", i32 4} !22 = !{i32 1, !"Debug Info Version", i32 3} !23 = !{!"clang version 3.5.0 "} diff --git a/test/Linker/type-unique-simple-a.ll b/test/Linker/type-unique-simple-a.ll index 5fb0ff2d491..24a830922ef 100644 --- a/test/Linker/type-unique-simple-a.ll +++ b/test/Linker/type-unique-simple-a.ll @@ -49,7 +49,7 @@ %struct.Base = type { i32 } ; Function Attrs: nounwind ssp uwtable -define void @_Z1fi(i32 %a) #0 { +define void @_Z1fi(i32 %a) #0 !dbg !10 { entry: %a.addr = alloca i32, align 4 %t = alloca %struct.Base, align 4 @@ -78,7 +78,7 @@ attributes #1 = { nounwind readnone } !7 = !DIDerivedType(tag: DW_TAG_member, name: "a", line: 2, size: 32, align: 32, file: !5, scope: !"_ZTS4Base", baseType: !8) !8 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !9 = !{!10} -!10 = distinct !DISubprogram(name: "f", linkageName: "_Z1fi", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !11, type: !12, function: void (i32)* @_Z1fi, variables: !2) +!10 = distinct !DISubprogram(name: "f", linkageName: "_Z1fi", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !11, type: !12, variables: !2) !11 = !DIFile(filename: "foo.cpp", directory: "/Users/mren/c_testing/type_unique_air/simple") !12 = !DISubroutineType(types: !13) !13 = !{null, !8} diff --git a/test/Linker/type-unique-simple-b.ll b/test/Linker/type-unique-simple-b.ll index 79e72a2df81..b2228185c9b 100644 --- a/test/Linker/type-unique-simple-b.ll +++ b/test/Linker/type-unique-simple-b.ll @@ -5,7 +5,7 @@ %struct.Base = type { i32 } ; Function Attrs: nounwind ssp uwtable -define void @_Z1gi(i32 %a) #0 { +define void @_Z1gi(i32 %a) #0 !dbg !10 { entry: %a.addr = alloca i32, align 4 %t = alloca %struct.Base, align 4 @@ -19,7 +19,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: ssp uwtable -define i32 @main() #2 { +define i32 @main() #2 !dbg !14 { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval @@ -48,11 +48,11 @@ attributes #3 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !7 = !DIDerivedType(tag: DW_TAG_member, name: "a", line: 2, size: 32, align: 32, file: !5, scope: !"_ZTS4Base", baseType: !8) !8 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !9 = !{!10, !14} -!10 = distinct !DISubprogram(name: "g", linkageName: "_Z1gi", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !11, type: !12, function: void (i32)* @_Z1gi, variables: !2) +!10 = distinct !DISubprogram(name: "g", linkageName: "_Z1gi", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !11, type: !12, variables: !2) !11 = !DIFile(filename: "bar.cpp", directory: "/Users/mren/c_testing/type_unique_air/simple") !12 = !DISubroutineType(types: !13) !13 = !{null, !8} -!14 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !11, type: !15, function: i32 ()* @main, variables: !2) +!14 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !11, type: !15, variables: !2) !15 = !DISubroutineType(types: !16) !16 = !{!8} !17 = !{i32 2, !"Dwarf Version", i32 2} diff --git a/test/Linker/type-unique-simple2-a.ll b/test/Linker/type-unique-simple2-a.ll index aeaf708da50..3779753a64e 100644 --- a/test/Linker/type-unique-simple2-a.ll +++ b/test/Linker/type-unique-simple2-a.ll @@ -31,7 +31,7 @@ @_ZTV1A = external unnamed_addr constant [4 x i8*] ; Function Attrs: nounwind -define i32 @_Z3barv() #0 { +define i32 @_Z3barv() #0 !dbg !27 { entry: %tmp = alloca %class.A, align 8 %0 = bitcast %class.A* %tmp to i8*, !dbg !38 @@ -45,7 +45,7 @@ entry: declare void @llvm.memset.p0i8.i64(i8* nocapture, i8, i64, i32, i1) #1 ; Function Attrs: inlinehint nounwind -define linkonce_odr void @_ZN1AC1Ev(%class.A* %this) unnamed_addr #2 align 2 { +define linkonce_odr void @_ZN1AC1Ev(%class.A* %this) unnamed_addr #2 align 2 !dbg !31 { entry: %this.addr = alloca %class.A*, align 8 store %class.A* %this, %class.A** %this.addr, align 8 @@ -61,7 +61,7 @@ declare i32 @_ZN1A6getFooEv(%class.A*) declare void @llvm.dbg.declare(metadata, metadata, metadata) #4 ; Function Attrs: inlinehint nounwind -define linkonce_odr void @_ZN1AC2Ev(%class.A* %this) unnamed_addr #2 align 2 { +define linkonce_odr void @_ZN1AC2Ev(%class.A* %this) unnamed_addr #2 align 2 !dbg !34 { entry: %this.addr = alloca %class.A*, align 8 store %class.A* %this, %class.A** %this.addr, align 8 @@ -106,13 +106,13 @@ attributes #4 = { nounwind readnone } !23 = !DIDerivedType(tag: DW_TAG_typedef, name: "foo_t", line: 1, file: !24, baseType: !13) !24 = !DIFile(filename: "a.cpp", directory: "") !26 = !{!27, !31, !34} -!27 = distinct !DISubprogram(name: "bar", linkageName: "_Z3barv", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !24, scope: !28, type: !29, function: i32 ()* @_Z3barv, variables: !2) +!27 = distinct !DISubprogram(name: "bar", linkageName: "_Z3barv", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !24, scope: !28, type: !29, variables: !2) !28 = !DIFile(filename: "a.cpp", directory: "") !29 = !DISubroutineType(types: !30) !30 = !{!23} -!31 = distinct !DISubprogram(name: "A", linkageName: "_ZN1AC1Ev", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagArtificial | DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !5, scope: !"_ZTS1A", type: !15, function: void (%class.A*)* @_ZN1AC1Ev, declaration: !32, variables: !2) +!31 = distinct !DISubprogram(name: "A", linkageName: "_ZN1AC1Ev", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagArtificial | DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !5, scope: !"_ZTS1A", type: !15, declaration: !32, variables: !2) !32 = !DISubprogram(name: "A", isLocal: false, isDefinition: false, virtualIndex: 6, flags: DIFlagArtificial | DIFlagPrototyped, isOptimized: false, scope: !"_ZTS1A", type: !15) -!34 = distinct !DISubprogram(name: "A", linkageName: "_ZN1AC2Ev", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagArtificial | DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !5, scope: !"_ZTS1A", type: !15, function: void (%class.A*)* @_ZN1AC2Ev, declaration: !32, variables: !2) +!34 = distinct !DISubprogram(name: "A", linkageName: "_ZN1AC2Ev", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagArtificial | DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !5, scope: !"_ZTS1A", type: !15, declaration: !32, variables: !2) !35 = !{i32 2, !"Dwarf Version", i32 2} !36 = !{i32 1, !"Debug Info Version", i32 3} !37 = !{!"clang version 3.5 "} diff --git a/test/Linker/type-unique-simple2-b.ll b/test/Linker/type-unique-simple2-b.ll index ab9f23efb23..e69ab63e6d2 100644 --- a/test/Linker/type-unique-simple2-b.ll +++ b/test/Linker/type-unique-simple2-b.ll @@ -18,7 +18,7 @@ @_ZTI1A = unnamed_addr constant { i8*, i8* } { i8* bitcast (i8** getelementptr inbounds (i8*, i8** @_ZTVN10__cxxabiv117__class_type_infoE, i64 2) to i8*), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @_ZTS1A, i32 0, i32 0) } ; Function Attrs: nounwind -define void @_ZN1A6setFooEv(%class.A* %this) unnamed_addr #0 align 2 { +define void @_ZN1A6setFooEv(%class.A* %this) unnamed_addr #0 align 2 !dbg !26 { entry: %this.addr = alloca %class.A*, align 8 store %class.A* %this, %class.A** %this.addr, align 8 @@ -31,7 +31,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: nounwind -define i32 @_ZN1A6getFooEv(%class.A* %this) unnamed_addr #0 align 2 { +define i32 @_ZN1A6getFooEv(%class.A* %this) unnamed_addr #0 align 2 !dbg !28 { entry: %this.addr = alloca %class.A*, align 8 store %class.A* %this, %class.A** %this.addr, align 8 @@ -71,9 +71,9 @@ attributes #1 = { nounwind readnone } !22 = !DIDerivedType(tag: DW_TAG_const_type, baseType: !23) !23 = !DIDerivedType(tag: DW_TAG_typedef, name: "foo_t", line: 1, file: !5, baseType: !13) !25 = !{!26, !28} -!26 = distinct !DISubprogram(name: "setFoo", linkageName: "_ZN1A6setFooEv", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPublic | DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !27, scope: !"_ZTS1A", type: !15, function: void (%class.A*)* @_ZN1A6setFooEv, declaration: !14, variables: !2) +!26 = distinct !DISubprogram(name: "setFoo", linkageName: "_ZN1A6setFooEv", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPublic | DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !27, scope: !"_ZTS1A", type: !15, declaration: !14, variables: !2) !27 = !DIFile(filename: "b.cpp", directory: "") -!28 = distinct !DISubprogram(name: "getFoo", linkageName: "_ZN1A6getFooEv", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPublic | DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !27, scope: !"_ZTS1A", type: !20, function: i32 (%class.A*)* @_ZN1A6getFooEv, declaration: !19, variables: !2) +!28 = distinct !DISubprogram(name: "getFoo", linkageName: "_ZN1A6getFooEv", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPublic | DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !27, scope: !"_ZTS1A", type: !20, declaration: !19, variables: !2) !29 = !{i32 2, !"Dwarf Version", i32 2} !30 = !{i32 1, !"Debug Info Version", i32 3} !31 = !{!"clang version 3.5 "} diff --git a/test/Linker/type-unique-type-array-a.ll b/test/Linker/type-unique-type-array-a.ll index eb4fbd3ca74..0a79f20f40c 100644 --- a/test/Linker/type-unique-type-array-a.ll +++ b/test/Linker/type-unique-type-array-a.ll @@ -43,7 +43,7 @@ %struct.SA = type { i32 } ; Function Attrs: ssp uwtable -define void @_Z4topAP1A2SA(%class.A* %a, i32 %sa.coerce) #0 { +define void @_Z4topAP1A2SA(%class.A* %a, i32 %sa.coerce) #0 !dbg !15 { entry: %sa = alloca %struct.SA, align 4 %a.addr = alloca %class.A*, align 8 @@ -67,7 +67,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: nounwind ssp uwtable -define linkonce_odr void @_ZN1A5testAE2SA(%class.A* %this, i32 %a.coerce) #2 align 2 { +define linkonce_odr void @_ZN1A5testAE2SA(%class.A* %this, i32 %a.coerce) #2 align 2 !dbg !20 { entry: %a = alloca %struct.SA, align 4 %this.addr = alloca %class.A*, align 8 @@ -107,12 +107,12 @@ attributes #3 = { nounwind } !12 = !DIDerivedType(tag: DW_TAG_member, name: "a", line: 2, size: 32, align: 32, file: !1, scope: !"_ZTS2SA", baseType: !13) !13 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !14 = !{!15, !20} -!15 = distinct !DISubprogram(name: "topA", linkageName: "_Z4topAP1A2SA", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 11, file: !1, scope: !16, type: !17, function: void (%class.A*, i32)* @_Z4topAP1A2SA, variables: !2) +!15 = distinct !DISubprogram(name: "topA", linkageName: "_Z4topAP1A2SA", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 11, file: !1, scope: !16, type: !17, variables: !2) !16 = !DIFile(filename: "a.cpp", directory: "/Users/manmanren/test-Nov/type_unique/rdar_di_array") !17 = !DISubroutineType(types: !18) !18 = !{null, !19, !"_ZTS2SA"} !19 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !"_ZTS1A") -!20 = distinct !DISubprogram(name: "testA", linkageName: "_ZN1A5testAE2SA", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !"_ZTS1A", type: !7, function: void (%class.A*, i32)* @_ZN1A5testAE2SA, declaration: !6, variables: !2) +!20 = distinct !DISubprogram(name: "testA", linkageName: "_ZN1A5testAE2SA", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !"_ZTS1A", type: !7, declaration: !6, variables: !2) !21 = !{i32 2, !"Dwarf Version", i32 2} !22 = !{i32 2, !"Debug Info Version", i32 3} !23 = !{!"clang version 3.5.0 (trunk 214102:214113M) (llvm/trunk 214102:214115M)"} diff --git a/test/Linker/type-unique-type-array-b.ll b/test/Linker/type-unique-type-array-b.ll index b4d9a155d74..b7796daf9b1 100644 --- a/test/Linker/type-unique-type-array-b.ll +++ b/test/Linker/type-unique-type-array-b.ll @@ -22,7 +22,7 @@ %struct.SA = type { i32 } ; Function Attrs: ssp uwtable -define void @_Z4topBP1B2SA(%class.B* %b, i32 %sa.coerce) #0 { +define void @_Z4topBP1B2SA(%class.B* %b, i32 %sa.coerce) #0 !dbg !15 { entry: %sa = alloca %struct.SA, align 4 %b.addr = alloca %class.B*, align 8 @@ -46,7 +46,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: nounwind ssp uwtable -define linkonce_odr void @_ZN1B5testBE2SA(%class.B* %this, i32 %sa.coerce) #2 align 2 { +define linkonce_odr void @_ZN1B5testBE2SA(%class.B* %this, i32 %sa.coerce) #2 align 2 !dbg !20 { entry: %sa = alloca %struct.SA, align 4 %this.addr = alloca %class.B*, align 8 @@ -86,12 +86,12 @@ attributes #3 = { nounwind } !12 = !DIDerivedType(tag: DW_TAG_member, name: "a", line: 2, size: 32, align: 32, file: !1, scope: !"_ZTS2SA", baseType: !13) !13 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) !14 = !{!15, !20} -!15 = distinct !DISubprogram(name: "topB", linkageName: "_Z4topBP1B2SA", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 11, file: !1, scope: !16, type: !17, function: void (%class.B*, i32)* @_Z4topBP1B2SA, variables: !2) +!15 = distinct !DISubprogram(name: "topB", linkageName: "_Z4topBP1B2SA", line: 11, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 11, file: !1, scope: !16, type: !17, variables: !2) !16 = !DIFile(filename: "b.cpp", directory: "/Users/manmanren/test-Nov/type_unique/rdar_di_array") !17 = !DISubroutineType(types: !18) !18 = !{null, !19, !"_ZTS2SA"} !19 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, baseType: !"_ZTS1B") -!20 = distinct !DISubprogram(name: "testB", linkageName: "_ZN1B5testBE2SA", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !"_ZTS1B", type: !7, function: void (%class.B*, i32)* @_ZN1B5testBE2SA, declaration: !6, variables: !2) +!20 = distinct !DISubprogram(name: "testB", linkageName: "_ZN1B5testBE2SA", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !"_ZTS1B", type: !7, declaration: !6, variables: !2) !21 = !{i32 2, !"Dwarf Version", i32 2} !22 = !{i32 2, !"Debug Info Version", i32 3} !23 = !{!"clang version 3.5.0 (trunk 214102:214113M) (llvm/trunk 214102:214115M)"} diff --git a/test/MC/ARM/coff-debugging-secrel.ll b/test/MC/ARM/coff-debugging-secrel.ll index 76d928957b6..a950ba2b689 100644 --- a/test/MC/ARM/coff-debugging-secrel.ll +++ b/test/MC/ARM/coff-debugging-secrel.ll @@ -9,7 +9,7 @@ target datalayout = "e-m:e-p:32:32-i1:8:32-i8:8:32-i16:16:32-i64:64-v128:64:128-a:0:32-n32-S64" target triple = "thumbv7--windows-itanium" -define arm_aapcs_vfpcc void @function() { +define arm_aapcs_vfpcc void @function() !dbg !1 { entry: ret void, !dbg !0 } @@ -18,7 +18,7 @@ entry: !llvm.module.flags = !{!9, !10} !0 = !DILocation(line: 1, scope: !1) -!1 = distinct !DISubprogram(name: "function", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !2, scope: !3, type: !4, function: void ()* @function, variables: !6) +!1 = distinct !DISubprogram(name: "function", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 1, file: !2, scope: !3, type: !4, variables: !6) !2 = !DIFile(filename: "/Users/compnerd/work/llvm/test/MC/ARM/reduced.c", directory: "/Users/compnerd/work/llvm") !3 = !DIFile(filename: "/Users/compnerd/work/llvm/test/MC/ARM/reduced.c", directory: "/Users/compnerd/work/llvm") !4 = !DISubroutineType(types: !5) diff --git a/test/MC/ELF/cfi-version.ll b/test/MC/ELF/cfi-version.ll index fc5ea0f4c83..71708a6489b 100644 --- a/test/MC/ELF/cfi-version.ll +++ b/test/MC/ELF/cfi-version.ll @@ -7,7 +7,7 @@ ; REQUIRES: default_triple ; Function Attrs: nounwind -define i32 @foo() #0 { +define i32 @foo() #0 !dbg !4 { entry: %call = call i32 bitcast (i32 (...)* @bar to i32 ()*)(), !dbg !12 %add = add nsw i32 %call, 1, !dbg !12 @@ -27,7 +27,7 @@ attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !1 = !DIFile(filename: "test.c", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, function: i32 ()* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "test.c", directory: "/tmp") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/Transforms/AddDiscriminators/basic.ll b/test/Transforms/AddDiscriminators/basic.ll index 6e6c5233072..cd7455b0a1d 100644 --- a/test/Transforms/AddDiscriminators/basic.ll +++ b/test/Transforms/AddDiscriminators/basic.ll @@ -11,7 +11,7 @@ ; if (i < 10) x = i; ; } -define void @foo(i32 %i) #0 { +define void @foo(i32 %i) #0 !dbg !4 { entry: %i.addr = alloca i32, align 4 %x = alloca i32, align 4 @@ -45,7 +45,7 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe !1 = !DIFile(filename: "basic.c", directory: ".") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: void (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "basic.c", directory: ".") !6 = !DISubroutineType(types: !2) !7 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/Transforms/AddDiscriminators/first-only.ll b/test/Transforms/AddDiscriminators/first-only.ll index aed667ef400..f9ea7cb8541 100644 --- a/test/Transforms/AddDiscriminators/first-only.ll +++ b/test/Transforms/AddDiscriminators/first-only.ll @@ -13,7 +13,7 @@ ; } ; } -define void @foo(i32 %i) #0 { +define void @foo(i32 %i) #0 !dbg !4 { entry: %i.addr = alloca i32, align 4 %x = alloca i32, align 4 @@ -54,7 +54,7 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe !1 = !DIFile(filename: "first-only.c", directory: ".") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: void (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "first-only.c", directory: ".") !6 = !DISubroutineType(types: !{null}) !7 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/Transforms/AddDiscriminators/multiple.ll b/test/Transforms/AddDiscriminators/multiple.ll index 1e86fb5753c..949ae5c4093 100644 --- a/test/Transforms/AddDiscriminators/multiple.ll +++ b/test/Transforms/AddDiscriminators/multiple.ll @@ -10,7 +10,7 @@ ; The two stores inside the if-then-else line must have different discriminator ; values. -define void @foo(i32 %i) #0 { +define void @foo(i32 %i) #0 !dbg !4 { entry: %i.addr = alloca i32, align 4 %x = alloca i32, align 4 @@ -55,7 +55,7 @@ attributes #0 = { nounwind uwtable "less-precise-fpmad"="false" "no-frame-pointe !1 = !DIFile(filename: "multiple.c", directory: ".") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: void (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "multiple.c", directory: ".") !6 = !DISubroutineType(types: !{null, !13}) !13 = !DIBasicType(encoding: DW_ATE_signed, name: "int", size: 32, align: 32) diff --git a/test/Transforms/AddDiscriminators/no-discriminators.ll b/test/Transforms/AddDiscriminators/no-discriminators.ll index cc9e0c49943..bbf931360a5 100644 --- a/test/Transforms/AddDiscriminators/no-discriminators.ll +++ b/test/Transforms/AddDiscriminators/no-discriminators.ll @@ -12,7 +12,7 @@ ; altered. If they are, it means that the discriminators pass added a ; new lexical scope. -define i32 @foo(i64 %i) #0 { +define i32 @foo(i64 %i) #0 !dbg !4 { entry: %retval = alloca i32, align 4 %i.addr = alloca i64, align 8 @@ -52,7 +52,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "no-discriminators", directory: ".") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 (i64)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) ; CHECK: ![[FOO:[0-9]+]] = distinct !DISubprogram(name: "foo" !5 = !DIFile(filename: "no-discriminators", directory: ".") !6 = !DISubroutineType(types: !7) diff --git a/test/Transforms/AddDiscriminators/oneline.ll b/test/Transforms/AddDiscriminators/oneline.ll index dcad5ae9176..a5deff4a549 100644 --- a/test/Transforms/AddDiscriminators/oneline.ll +++ b/test/Transforms/AddDiscriminators/oneline.ll @@ -10,7 +10,7 @@ ; return 100: discriminator 1 ; return 99: discriminator 3 -define i32 @_Z3fooi(i32 %i) #0 { +define i32 @_Z3fooi(i32 %i) #0 !dbg !4 { %1 = alloca i32, align 4 %2 = alloca i32, align 4 store i32 %i, i32* %2, align 4, !tbaa !13 @@ -62,7 +62,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "a.cc", directory: "/usr/local/google/home/dehao/discr") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooi", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: true, function: i32 (i32)* @_Z3fooi, variables: !8) +!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooi", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: true, variables: !8) !5 = !DISubroutineType(types: !6) !6 = !{!7, !7} !7 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/Transforms/ArgumentPromotion/dbg.ll b/test/Transforms/ArgumentPromotion/dbg.ll index 06b2bc81763..dbdccacf42b 100644 --- a/test/Transforms/ArgumentPromotion/dbg.ll +++ b/test/Transforms/ArgumentPromotion/dbg.ll @@ -1,10 +1,9 @@ ; RUN: opt < %s -argpromotion -S | FileCheck %s -; CHECK: call void @test(i32 % -; CHECK: !DISubprogram(name: "test",{{.*}} function: void (i32)* @test declare void @sink(i32) -define internal void @test(i32** %X) { +; CHECK: define internal void @test({{.*}} !dbg [[SP:![0-9]+]] +define internal void @test(i32** %X) !dbg !2 { %1 = load i32*, i32** %X, align 8 %2 = load i32, i32* %1, align 8 call void @sink(i32 %2) @@ -12,16 +11,19 @@ define internal void @test(i32** %X) { } define void @caller(i32** %Y) { +; CHECK: call void @test(i32 % call void @test(i32** %Y) ret void } +; CHECK: [[SP]] = distinct !DISubprogram(name: "test", + !llvm.module.flags = !{!0} !llvm.dbg.cu = !{!3} !0 = !{i32 2, !"Debug Info Version", i32 3} !1 = !DILocation(line: 8, scope: !2) -!2 = distinct !DISubprogram(name: "test", line: 3, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, scope: null, function: void (i32**)* @test) +!2 = distinct !DISubprogram(name: "test", line: 3, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, scope: null) !3 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang version 3.5.0 ", isOptimized: false, emissionKind: 2, file: !5, subprograms: !4) !4 = !{!2} !5 = !DIFile(filename: "test.c", directory: "") diff --git a/test/Transforms/DeadArgElim/dbginfo.ll b/test/Transforms/DeadArgElim/dbginfo.ll index 8879b8d4867..a19d4b1fd1a 100644 --- a/test/Transforms/DeadArgElim/dbginfo.ll +++ b/test/Transforms/DeadArgElim/dbginfo.ll @@ -14,20 +14,21 @@ ; the function->debug info mapping on update to ensure it's accurate when used ; again for the next removal. -; CHECK: !DISubprogram(name: "f1",{{.*}} function: void ()* @_ZL2f1iz +; CHECK: define internal void @_ZL2f1iz({{.*}} !dbg [[SP:![0-9]+]] +; CHECK: [[SP]] = distinct !DISubprogram(name: "f1" ; Check that debug info metadata for subprograms stores pointers to ; updated LLVM functions. ; Function Attrs: uwtable -define void @_Z2f2v() #0 { +define void @_Z2f2v() #0 !dbg !4 { entry: call void (i32, ...) @_ZL2f1iz(i32 1), !dbg !15 ret void, !dbg !16 } ; Function Attrs: nounwind uwtable -define internal void @_ZL2f1iz(i32, ...) #1 { +define internal void @_ZL2f1iz(i32, ...) #1 !dbg !8 { entry: call void @llvm.dbg.value(metadata i32 %0, i64 0, metadata !17, metadata !18), !dbg !19 ret void, !dbg !20 @@ -51,11 +52,11 @@ attributes #2 = { nounwind readnone } !1 = !DIFile(filename: "dbg.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4, !8} -!4 = distinct !DISubprogram(name: "f2", linkageName: "_Z2f2v", line: 4, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !5, type: !6, function: void ()* @_Z2f2v, variables: !2) +!4 = distinct !DISubprogram(name: "f2", linkageName: "_Z2f2v", line: 4, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "dbg.cpp", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !7) !7 = !{null} -!8 = distinct !DISubprogram(name: "f1", linkageName: "_ZL2f1iz", line: 1, isLocal: true, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !9, function: void (i32, ...)* @_ZL2f1iz, variables: !2) +!8 = distinct !DISubprogram(name: "f1", linkageName: "_ZL2f1iz", line: 1, isLocal: true, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !9, variables: !2) !9 = !DISubroutineType(types: !10) !10 = !{null, !11, null} !11 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/Transforms/DeadStoreElimination/inst-limits.ll b/test/Transforms/DeadStoreElimination/inst-limits.ll index 78c8ba98924..5848ab89bc8 100644 --- a/test/Transforms/DeadStoreElimination/inst-limits.ll +++ b/test/Transforms/DeadStoreElimination/inst-limits.ll @@ -9,7 +9,7 @@ target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128" @x = global i32 0, align 4 ; Function Attrs: nounwind -define i32 @test_within_limit() { +define i32 @test_within_limit() !dbg !4 { entry: ; The first store; later there is a second store to the same location, ; so this store should be optimized away by DSE. @@ -249,7 +249,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) !1 = !DIFile(filename: "test.c", directory: "/home/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "test_within_limit", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !5, type: !6, function: i32 ()* @test_within_limit, variables: !2) +!4 = distinct !DISubprogram(name: "test_within_limit", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "test.c", directory: "/home/tmp") !6 = !DISubroutineType(types: !7) !7 = !{!8} diff --git a/test/Transforms/GCOVProfiling/function-numbering.ll b/test/Transforms/GCOVProfiling/function-numbering.ll index 5b2e0cc3fc0..f94d5ad30bb 100644 --- a/test/Transforms/GCOVProfiling/function-numbering.ll +++ b/test/Transforms/GCOVProfiling/function-numbering.ll @@ -22,16 +22,16 @@ target triple = "x86_64-apple-macosx10.10.0" ; GCNO-NOT: == bar ({{[0-9]+}}) @ ; GCNO: == baz (1) @ -define void @foo() { +define void @foo() !dbg !4 { ret void, !dbg !12 } -define void @bar() { +define void @bar() !dbg !7 { ; This function is referenced by the debug info, but no lines have locations. ret void } -define void @baz() { +define void @baz() !dbg !8 { ret void, !dbg !13 } @@ -44,11 +44,11 @@ define void @baz() { !1 = !DIFile(filename: ".../llvm/test/Transforms/GCOVProfiling/function-numbering.ll", directory: "") !2 = !{} !3 = !{!4, !7, !8} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: void ()* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: ".../llvm/test/Transforms/GCOVProfiling/function-numbering.ll", directory: "") !6 = !DISubroutineType(types: !2) -!7 = distinct !DISubprogram(name: "bar", line: 2, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, function: void ()* @bar, variables: !2) -!8 = distinct !DISubprogram(name: "baz", line: 3, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, function: void ()* @baz, variables: !2) +!7 = distinct !DISubprogram(name: "bar", line: 2, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) +!8 = distinct !DISubprogram(name: "baz", line: 3, isLocal: false, isDefinition: true, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !2) !9 = !{i32 2, !"Dwarf Version", i32 2} !10 = !{i32 2, !"Debug Info Version", i32 3} !11 = !{!"clang version 3.6.0 "} diff --git a/test/Transforms/GCOVProfiling/global-ctor.ll b/test/Transforms/GCOVProfiling/global-ctor.ll index 8c1f5baedbc..47600c7bfca 100644 --- a/test/Transforms/GCOVProfiling/global-ctor.ll +++ b/test/Transforms/GCOVProfiling/global-ctor.ll @@ -8,7 +8,7 @@ @llvm.global_ctors = appending global [1 x { i32, void ()*, i8* }] [{ i32, void ()*, i8* } { i32 65535, void ()* @_GLOBAL__sub_I_global-ctor.ll, i8* null }] ; Function Attrs: nounwind -define internal void @__cxx_global_var_init() #0 section ".text.startup" { +define internal void @__cxx_global_var_init() #0 section ".text.startup" !dbg !4 { entry: br label %0 @@ -42,11 +42,11 @@ attributes #1 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="false" " !1 = !DIFile(filename: "<stdin>", directory: "/home/nlewycky") !2 = !{} !3 = !{!4, !8} -!4 = distinct !DISubprogram(name: "__cxx_global_var_init", line: 2, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !5, scope: !6, type: !7, function: void ()* @__cxx_global_var_init, variables: !2) +!4 = distinct !DISubprogram(name: "__cxx_global_var_init", line: 2, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !5, scope: !6, type: !7, variables: !2) !5 = !DIFile(filename: "global-ctor.ll", directory: "/home/nlewycky") !6 = !DIFile(filename: "global-ctor.ll", directory: "/home/nlewycky") !7 = !DISubroutineType(types: !2) -!8 = distinct !DISubprogram(name: "", linkageName: "_GLOBAL__sub_I_global-ctor.ll", isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagArtificial, isOptimized: false, file: !1, scope: !9, type: !7, function: void ()* @_GLOBAL__sub_I_global-ctor.ll, variables: !2) +!8 = distinct !DISubprogram(name: "", linkageName: "_GLOBAL__sub_I_global-ctor.ll", isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagArtificial, isOptimized: false, file: !1, scope: !9, type: !7, variables: !2) !9 = !DIFile(filename: "<stdin>", directory: "/home/nlewycky") !10 = !{i32 2, !"Dwarf Version", i32 4} !11 = !{i32 2, !"Debug Info Version", i32 3} diff --git a/test/Transforms/GCOVProfiling/linezero.ll b/test/Transforms/GCOVProfiling/linezero.ll index 42d3271a0e4..e071c4e6dbf 100644 --- a/test/Transforms/GCOVProfiling/linezero.ll +++ b/test/Transforms/GCOVProfiling/linezero.ll @@ -9,7 +9,7 @@ target triple = "x86_64-unknown-linux-gnu" %struct.vector = type { i8 } ; Function Attrs: nounwind -define i32 @_Z4testv() #0 { +define i32 @_Z4testv() #0 !dbg !15 { entry: %retval = alloca i32, align 4 %__range = alloca %struct.vector*, align 8 @@ -75,7 +75,7 @@ declare i8* @_ZN6vector3endEv(%struct.vector*) #2 declare void @llvm.trap() #3 ; Function Attrs: nounwind -define void @_Z2f1v() #0 { +define void @_Z2f1v() #0 !dbg !20 { entry: br label %0 @@ -108,12 +108,12 @@ attributes #3 = { noreturn nounwind } !12 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS6vector") !13 = !DISubprogram(name: "end", linkageName: "_ZN6vector3endEv", line: 26, isLocal: false, isDefinition: false, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 26, file: !5, scope: !"_ZTS6vector", type: !8) !14 = !{!15, !20} -!15 = distinct !DISubprogram(name: "test", linkageName: "_Z4testv", line: 50, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 50, file: !5, scope: !16, type: !17, function: i32 ()* @_Z4testv, variables: !2) +!15 = distinct !DISubprogram(name: "test", linkageName: "_Z4testv", line: 50, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 50, file: !5, scope: !16, type: !17, variables: !2) !16 = !DIFile(filename: "linezero.cc", directory: "PATTERN") !17 = !DISubroutineType(types: !18) !18 = !{!19} !19 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!20 = distinct !DISubprogram(name: "f1", linkageName: "_Z2f1v", line: 54, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 54, file: !5, scope: !16, type: !21, function: void ()* @_Z2f1v, variables: !2) +!20 = distinct !DISubprogram(name: "f1", linkageName: "_Z2f1v", line: 54, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 54, file: !5, scope: !16, type: !21, variables: !2) !21 = !DISubroutineType(types: !22) !22 = !{null} !23 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/Transforms/GCOVProfiling/linkagename.ll b/test/Transforms/GCOVProfiling/linkagename.ll index e094045c044..65830bf7802 100644 --- a/test/Transforms/GCOVProfiling/linkagename.ll +++ b/test/Transforms/GCOVProfiling/linkagename.ll @@ -4,7 +4,7 @@ ; RUN: grep _Z3foov %T/linkagename.gcno ; RUN: rm %T/linkagename.gcno -define void @_Z3foov() { +define void @_Z3foov() !dbg !5 { entry: ret void, !dbg !8 } @@ -18,7 +18,7 @@ entry: !2 = !DIFile(filename: "hello.cc", directory: "/home/nlewycky") !3 = !{} !4 = !{!5} -!5 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foov", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !1, type: !6, function: void ()* @_Z3foov, variables: !3) +!5 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foov", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !1, type: !6, variables: !3) !6 = !DISubroutineType(types: !7) !7 = !{null} !8 = !DILocation(line: 1, scope: !5) diff --git a/test/Transforms/GCOVProfiling/return-block.ll b/test/Transforms/GCOVProfiling/return-block.ll index bc3bcdf7b96..9b502a14bfa 100644 --- a/test/Transforms/GCOVProfiling/return-block.ll +++ b/test/Transforms/GCOVProfiling/return-block.ll @@ -16,7 +16,7 @@ target triple = "x86_64-unknown-linux-gnu" @A = common global i32 0, align 4 ; Function Attrs: nounwind uwtable -define void @test() #0 { +define void @test() #0 !dbg !4 { entry: tail call void (...) @f() #2, !dbg !14 %0 = load i32, i32* @A, align 4, !dbg !15 @@ -48,7 +48,7 @@ attributes #2 = { nounwind } !1 = !DIFile(filename: ".../llvm/test/Transforms/GCOVProfiling/return-block.ll", directory: "") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "test", line: 5, isLocal: false, isDefinition: true, isOptimized: true, scopeLine: 5, file: !1, scope: !5, type: !6, function: void ()* @test, variables: !2) +!4 = distinct !DISubprogram(name: "test", line: 5, isLocal: false, isDefinition: true, isOptimized: true, scopeLine: 5, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: ".../llvm/test/Transforms/GCOVProfiling/return-block.ll", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{null} diff --git a/test/Transforms/GCOVProfiling/version.ll b/test/Transforms/GCOVProfiling/version.ll index cec8ae97705..67bfb3c9761 100644 --- a/test/Transforms/GCOVProfiling/version.ll +++ b/test/Transforms/GCOVProfiling/version.ll @@ -8,7 +8,7 @@ ; RUN: head -c8 %T/version.gcno | grep '^oncg.704' ; RUN: rm %T/version.gcno -define void @test() { +define void @test() !dbg !5 { ret void, !dbg !8 } @@ -20,7 +20,7 @@ define void @test() { !2 = !DIFile(filename: "version", directory: "/usr/local/google/home/nlewycky") !3 = !{} !4 = !{!5} -!5 = distinct !DISubprogram(name: "test", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !10, scope: !6, type: !7, function: void ()* @test, variables: !3) +!5 = distinct !DISubprogram(name: "test", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !10, scope: !6, type: !7, variables: !3) !6 = !DIFile(filename: "<stdin>", directory: ".") !7 = !DISubroutineType(types: !{null}) !8 = !DILocation(line: 1, scope: !5) diff --git a/test/Transforms/GVN/load-pre-nonlocal.ll b/test/Transforms/GVN/load-pre-nonlocal.ll index 8f5ec9c326f..e0e88665307 100644 --- a/test/Transforms/GVN/load-pre-nonlocal.ll +++ b/test/Transforms/GVN/load-pre-nonlocal.ll @@ -61,7 +61,7 @@ for.end: ; CHECK-NOT: %1 = load i32, i32* ; CHECK: [[LSHR_LOC]] = !DILocation(line: 101, column: 1, scope: !{{.*}}) -define i32 @overaligned_load(i32 %a, i32* nocapture %b) { +define i32 @overaligned_load(i32 %a, i32* nocapture %b) !dbg !13 { entry: %cmp = icmp sgt i32 %a, 0, !dbg !14 br i1 %cmp, label %if.then, label %if.else, !dbg !14 @@ -99,7 +99,7 @@ if.end: !10 = !{} !11 = !DISubroutineType(types: !10) !12 = !DIFile(filename: "test.cpp", directory: "/tmp") -!13 = distinct !DISubprogram(name: "test", scope: !12, file: !12, line: 99, type: !11, isLocal: false, isDefinition: true, scopeLine: 100, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32, i32*)* @overaligned_load, variables: !10) +!13 = distinct !DISubprogram(name: "test", scope: !12, file: !12, line: 99, type: !11, isLocal: false, isDefinition: true, scopeLine: 100, flags: DIFlagPrototyped, isOptimized: false, variables: !10) !14 = !DILocation(line: 100, column: 1, scope: !13) !15 = !DILocation(line: 101, column: 1, scope: !13) !16 = !DILocation(line: 102, column: 1, scope: !13) diff --git a/test/Transforms/GVN/phi-translate.ll b/test/Transforms/GVN/phi-translate.ll index 0661f393b21..67036ab9746 100644 --- a/test/Transforms/GVN/phi-translate.ll +++ b/test/Transforms/GVN/phi-translate.ll @@ -18,7 +18,7 @@ target datalayout = "e-p:64:64:64" ; CHECK-DAG: [[N_LOC]] = !DILocation(line: 47, column: 1, scope: !{{.*}}) @G = external global [100 x i32] -define i32 @foo(i32 %x, i32 %z) { +define i32 @foo(i32 %x, i32 %z) !dbg !6 { entry: %tobool = icmp eq i32 %z, 0, !dbg !7 br i1 %tobool, label %end, label %then, !dbg !7 @@ -44,7 +44,7 @@ end: !3 = !{} !4 = !DISubroutineType(types: !3) !5 = !DIFile(filename: "a.cc", directory: "/tmp") -!6 = distinct !DISubprogram(name: "foo", scope: !5, file: !5, line: 42, type: !4, isLocal: false, isDefinition: true, scopeLine: 43, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32, i32)* @foo, variables: !3) +!6 = distinct !DISubprogram(name: "foo", scope: !5, file: !5, line: 42, type: !4, isLocal: false, isDefinition: true, scopeLine: 43, flags: DIFlagPrototyped, isOptimized: false, variables: !3) !7 = !DILocation(line: 43, column: 1, scope: !6) !8 = !DILocation(line: 44, column: 1, scope: !6) !9 = !DILocation(line: 45, column: 1, scope: !6) diff --git a/test/Transforms/Inline/alloca-dbgdeclare-merge.ll b/test/Transforms/Inline/alloca-dbgdeclare-merge.ll index 5e10988cf50..5314f0b8397 100644 --- a/test/Transforms/Inline/alloca-dbgdeclare-merge.ll +++ b/test/Transforms/Inline/alloca-dbgdeclare-merge.ll @@ -32,7 +32,7 @@ target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-unknown-linux-gnu" ; Function Attrs: alwaysinline nounwind uwtable -define void @f() #0 { +define void @f() #0 !dbg !4 { entry: %aaa = alloca [100 x i8], align 16 call void @llvm.dbg.declare(metadata [100 x i8]* %aaa, metadata !12, metadata !17), !dbg !18 @@ -45,7 +45,7 @@ entry: declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; Function Attrs: alwaysinline nounwind uwtable -define void @g() #0 { +define void @g() #0 !dbg !7 { entry: %bbb = alloca [100 x i8], align 16 call void @llvm.dbg.declare(metadata [100 x i8]* %bbb, metadata !22, metadata !17), !dbg !23 @@ -55,7 +55,7 @@ entry: } ; Function Attrs: nounwind uwtable -define void @h() #2 { +define void @h() #2 !dbg !8 { entry: call void @f(), !dbg !27 call void @g(), !dbg !28 @@ -74,11 +74,11 @@ attributes #2 = { nounwind uwtable "disable-tail-calls"="false" "less-precise-fp !1 = !DIFile(filename: "../1.c", directory: "/code/llvm-git/build") !2 = !{} !3 = !{!4, !7, !8} -!4 = distinct !DISubprogram(name: "f", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, isOptimized: false, function: void ()* @f, variables: !2) +!4 = distinct !DISubprogram(name: "f", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{null} -!7 = distinct !DISubprogram(name: "g", scope: !1, file: !1, line: 6, type: !5, isLocal: false, isDefinition: true, scopeLine: 6, isOptimized: false, function: void ()* @g, variables: !2) -!8 = distinct !DISubprogram(name: "h", scope: !1, file: !1, line: 11, type: !5, isLocal: false, isDefinition: true, scopeLine: 11, isOptimized: false, function: void ()* @h, variables: !2) +!7 = distinct !DISubprogram(name: "g", scope: !1, file: !1, line: 6, type: !5, isLocal: false, isDefinition: true, scopeLine: 6, isOptimized: false, variables: !2) +!8 = distinct !DISubprogram(name: "h", scope: !1, file: !1, line: 11, type: !5, isLocal: false, isDefinition: true, scopeLine: 11, isOptimized: false, variables: !2) !9 = !{i32 2, !"Dwarf Version", i32 4} !10 = !{i32 2, !"Debug Info Version", i32 3} !11 = !{!"clang version 3.8.0 (trunk 248518) (llvm/trunk 248512)"} diff --git a/test/Transforms/Inline/alloca-dbgdeclare.ll b/test/Transforms/Inline/alloca-dbgdeclare.ll index 721cc3ce0e1..39575311b4b 100644 --- a/test/Transforms/Inline/alloca-dbgdeclare.ll +++ b/test/Transforms/Inline/alloca-dbgdeclare.ll @@ -34,7 +34,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 declare void @llvm.memcpy.p0i8.p0i8.i64(i8* nocapture, i8* nocapture readonly, i64, i32, i1) #2 ; Function Attrs: nounwind -define void @_Z3fn4v() #0 { +define void @_Z3fn4v() #0 !dbg !21 { entry: ; Test that the dbg.declare is moved together with the alloca. ; CHECK: define void @_Z3fn5v() @@ -61,7 +61,7 @@ _Z3fn31A.exit: ; preds = %entry, %if.then.i } ; Function Attrs: noreturn nounwind -define void @_Z3fn5v() #3 { +define void @_Z3fn5v() #3 !dbg !24 { entry: br label %while.body, !dbg !55 @@ -97,16 +97,16 @@ attributes #3 = { noreturn nounwind } !12 = !{!13} !13 = !DISubrange(count: 2) !14 = !{!15, !21, !24} -!15 = distinct !DISubprogram(name: "fn3", linkageName: "_Z3fn31A", line: 6, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 6, file: !5, scope: !16, type: !17, function: void (%struct.A*)* @_Z3fn31A, variables: !19) +!15 = distinct !DISubprogram(name: "fn3", linkageName: "_Z3fn31A", line: 6, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 6, file: !5, scope: !16, type: !17, variables: !19) !16 = !DIFile(filename: "test.cpp", directory: "") !17 = !DISubroutineType(types: !18) !18 = !{null, !"_ZTS1A"} !19 = !{!20} !20 = !DILocalVariable(name: "p1", line: 6, arg: 1, scope: !15, file: !16, type: !"_ZTS1A") -!21 = distinct !DISubprogram(name: "fn4", linkageName: "_Z3fn4v", line: 11, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 11, file: !5, scope: !16, type: !22, function: void ()* @_Z3fn4v, variables: !2) +!21 = distinct !DISubprogram(name: "fn4", linkageName: "_Z3fn4v", line: 11, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 11, file: !5, scope: !16, type: !22, variables: !2) !22 = !DISubroutineType(types: !23) !23 = !{null} -!24 = distinct !DISubprogram(name: "fn5", linkageName: "_Z3fn5v", line: 13, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 13, file: !5, scope: !16, type: !22, function: void ()* @_Z3fn5v, variables: !2) +!24 = distinct !DISubprogram(name: "fn5", linkageName: "_Z3fn5v", line: 13, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 13, file: !5, scope: !16, type: !22, variables: !2) !25 = !{!26, !27} !26 = !DIGlobalVariable(name: "a", line: 4, isLocal: false, isDefinition: true, scope: null, file: !16, type: !"_ZTS1A", variable: %struct.A* @a) !27 = !DIGlobalVariable(name: "b", line: 4, isLocal: false, isDefinition: true, scope: null, file: !16, type: !"_ZTS1A", variable: %struct.A* @b) diff --git a/test/Transforms/Inline/debug-info-duplicate-calls.ll b/test/Transforms/Inline/debug-info-duplicate-calls.ll index c69a0d48e4c..442ff325863 100644 --- a/test/Transforms/Inline/debug-info-duplicate-calls.ll +++ b/test/Transforms/Inline/debug-info-duplicate-calls.ll @@ -59,7 +59,7 @@ $_Z2f3v = comdat any $_Z2f2v = comdat any ; Function Attrs: uwtable -define void @_Z1fv() #0 { +define void @_Z1fv() #0 !dbg !4 { entry: call void @_Z2f4v(), !dbg !13 call void @_Z2f4v(), !dbg !13 @@ -67,14 +67,14 @@ entry: } ; Function Attrs: alwaysinline inlinehint uwtable -define linkonce_odr void @_Z2f4v() #1 comdat { +define linkonce_odr void @_Z2f4v() #1 comdat !dbg !7 { entry: call void @_Z2f3v(), !dbg !15 ret void, !dbg !16 } ; Function Attrs: alwaysinline inlinehint uwtable -define linkonce_odr void @_Z2f3v() #1 comdat { +define linkonce_odr void @_Z2f3v() #1 comdat !dbg !8 { entry: call void @_Z2f2v(), !dbg !17 call void @_Z2f2v(), !dbg !17 @@ -82,7 +82,7 @@ entry: } ; Function Attrs: alwaysinline inlinehint uwtable -define linkonce_odr void @_Z2f2v() #1 comdat { +define linkonce_odr void @_Z2f2v() #1 comdat !dbg !9 { entry: call void @_Z2f1v(), !dbg !19 ret void, !dbg !20 @@ -102,12 +102,12 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !1 = !DIFile(filename: "debug-info-duplicate-calls.cpp", directory: "/tmp/dbginfo") !2 = !{} !3 = !{!4, !7, !8, !9} -!4 = distinct !DISubprogram(name: "f", line: 13, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 13, file: !1, scope: !5, type: !6, function: void ()* @_Z1fv, variables: !2) +!4 = distinct !DISubprogram(name: "f", line: 13, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 13, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "debug-info-duplicate-calls.cpp", directory: "/tmp/dbginfo") !6 = !DISubroutineType(types: !2) -!7 = distinct !DISubprogram(name: "f4", line: 10, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !1, scope: !5, type: !6, function: void ()* @_Z2f4v, variables: !2) -!8 = distinct !DISubprogram(name: "f3", line: 7, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !5, type: !6, function: void ()* @_Z2f3v, variables: !2) -!9 = distinct !DISubprogram(name: "f2", line: 4, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !5, type: !6, function: void ()* @_Z2f2v, variables: !2) +!7 = distinct !DISubprogram(name: "f4", line: 10, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 10, file: !1, scope: !5, type: !6, variables: !2) +!8 = distinct !DISubprogram(name: "f3", line: 7, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !5, type: !6, variables: !2) +!9 = distinct !DISubprogram(name: "f2", line: 4, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 4, file: !1, scope: !5, type: !6, variables: !2) !10 = !{i32 2, !"Dwarf Version", i32 4} !11 = !{i32 2, !"Debug Info Version", i32 3} !12 = !{!"clang version 3.7.0 (trunk 226474) (llvm/trunk 226478)"} diff --git a/test/Transforms/Inline/inline_dbg_declare.ll b/test/Transforms/Inline/inline_dbg_declare.ll index 481eaea7614..3c701c41459 100644 --- a/test/Transforms/Inline/inline_dbg_declare.ll +++ b/test/Transforms/Inline/inline_dbg_declare.ll @@ -23,7 +23,7 @@ target datalayout = "e-m:w-p:32:32-i64:64-f80:32-n8:16:32-S32" target triple = "i686-pc-windows-msvc" ; Function Attrs: nounwind -define float @foo(float %x) #0 { +define float @foo(float %x) #0 !dbg !4 { entry: %x.addr = alloca float, align 4 store float %x, float* %x.addr, align 4 @@ -38,7 +38,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 ; CHECK: define void @bar ; Function Attrs: nounwind -define void @bar(float* %dst) #0 { +define void @bar(float* %dst) #0 !dbg !9 { entry: ; CHECK: [[x_addr_i:%[a-zA-Z0-9.]+]] = alloca float, align 4 @@ -71,12 +71,12 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "foo.c", directory: "") !2 = !{} !3 = !{!4, !9} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, function: float (float)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "foo.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{!8, !8} !8 = !DIBasicType(tag: DW_TAG_base_type, name: "float", size: 32, align: 32, encoding: DW_ATE_float) -!9 = distinct !DISubprogram(name: "bar", line: 6, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !5, type: !10, function: void (float*)* @bar, variables: !2) +!9 = distinct !DISubprogram(name: "bar", line: 6, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !5, type: !10, variables: !2) !10 = !DISubroutineType(types: !11) !11 = !{null, !12} !12 = !DIDerivedType(tag: DW_TAG_pointer_type, size: 32, align: 32, baseType: !8) diff --git a/test/Transforms/InstCombine/debug-line.ll b/test/Transforms/InstCombine/debug-line.ll index 1160daf0db0..4b1db9db353 100644 --- a/test/Transforms/InstCombine/debug-line.ll +++ b/test/Transforms/InstCombine/debug-line.ll @@ -3,7 +3,7 @@ @.str = private constant [3 x i8] c"%c\00" -define void @foo() nounwind ssp { +define void @foo() nounwind ssp !dbg !0 { ;CHECK: call i32 @putchar{{.+}} !dbg %1 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i32 0, i32 0), i32 97), !dbg !5 ret void, !dbg !7 @@ -15,7 +15,7 @@ declare i32 @printf(i8*, ...) !llvm.module.flags = !{!10} !llvm.dbg.sp = !{!0} -!0 = distinct !DISubprogram(name: "foo", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !8, scope: !1, type: !3, function: void ()* @foo) +!0 = distinct !DISubprogram(name: "foo", line: 4, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !8, scope: !1, type: !3) !1 = !DIFile(filename: "m.c", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang", isOptimized: true, emissionKind: 0, file: !8, enums: !{}, retainedTypes: !{}, subprograms: !9) !3 = !DISubroutineType(types: !4) diff --git a/test/Transforms/InstCombine/debuginfo.ll b/test/Transforms/InstCombine/debuginfo.ll index 54e33cd82a5..9c8b2a8e415 100644 --- a/test/Transforms/InstCombine/debuginfo.ll +++ b/test/Transforms/InstCombine/debuginfo.ll @@ -6,7 +6,7 @@ declare i64 @llvm.objectsize.i64.p0i8(i8*, i1) nounwind readnone declare i8* @foo(i8*, i32, i64, i64) nounwind -define hidden i8* @foobar(i8* %__dest, i32 %__val, i64 %__len) nounwind inlinehint ssp { +define hidden i8* @foobar(i8* %__dest, i32 %__val, i64 %__len) nounwind inlinehint ssp !dbg !1 { entry: %__dest.addr = alloca i8*, align 8 %__val.addr = alloca i32, align 4 @@ -32,7 +32,7 @@ entry: !llvm.module.flags = !{!30} !0 = !DILocalVariable(name: "__dest", line: 78, arg: 1, scope: !1, file: !2, type: !6) -!1 = distinct !DISubprogram(name: "foobar", line: 79, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 79, file: !27, scope: !2, type: !4, function: i8* (i8*, i32, i64)* @foobar, variables: !25) +!1 = distinct !DISubprogram(name: "foobar", line: 79, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 79, file: !27, scope: !2, type: !4, variables: !25) !2 = !DIFile(filename: "string.h", directory: "Game") !3 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 (trunk 127710)", isOptimized: true, emissionKind: 0, file: !28, enums: !29, retainedTypes: !29, subprograms: !24) !4 = !DISubroutineType(types: !5) diff --git a/test/Transforms/InstCombine/lifetime.ll b/test/Transforms/InstCombine/lifetime.ll index 57b19fb0a82..e5cbe340141 100644 --- a/test/Transforms/InstCombine/lifetime.ll +++ b/test/Transforms/InstCombine/lifetime.ll @@ -5,7 +5,7 @@ declare void @llvm.lifetime.start(i64, i8* nocapture) declare void @llvm.lifetime.end(i64, i8* nocapture) declare void @foo(i8* nocapture, i8* nocapture) -define void @bar(i1 %flag) { +define void @bar(i1 %flag) !dbg !4 { entry: ; CHECK-LABEL: @bar( ; CHECK: %[[T:[^ ]+]] = getelementptr inbounds [1 x i8], [1 x i8]* %text @@ -68,7 +68,7 @@ fin: !1 = !DIFile(filename: "test.cpp", directory: "/home/user") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "bar", linkageName: "bar", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, flags: DIFlagPrototyped, isOptimized: true, function: void (i1)* @bar, variables: !8) +!4 = distinct !DISubprogram(name: "bar", linkageName: "bar", scope: !1, file: !1, line: 2, type: !5, isLocal: false, isDefinition: true, scopeLine: 2, flags: DIFlagPrototyped, isOptimized: true, variables: !8) !5 = !DISubroutineType(types: !6) !6 = !{null, !7} !7 = !DIBasicType(name: "bool", size: 8, align: 8, encoding: DW_ATE_boolean) diff --git a/test/Transforms/LoopIdiom/debug-line.ll b/test/Transforms/LoopIdiom/debug-line.ll index de53752bfdc..a85e4899754 100644 --- a/test/Transforms/LoopIdiom/debug-line.ll +++ b/test/Transforms/LoopIdiom/debug-line.ll @@ -3,7 +3,7 @@ target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f3 target triple = "x86_64-apple-darwin10.0.0" -define void @foo(double* nocapture %a) nounwind ssp { +define void @foo(double* nocapture %a) nounwind ssp !dbg !0 { entry: tail call void @llvm.dbg.value(metadata double* %a, i64 0, metadata !5, metadata !DIExpression()), !dbg !8 tail call void @llvm.dbg.value(metadata i32 0, i64 0, metadata !10, metadata !DIExpression()), !dbg !14 @@ -30,7 +30,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.module.flags = !{!19} !llvm.dbg.sp = !{!0} -!0 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !18, scope: !1, type: !3, function: void (double*)* @foo) +!0 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !18, scope: !1, type: !3) !1 = !DIFile(filename: "li.c", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 2.9 (trunk 127165:127174)", isOptimized: true, emissionKind: 0, file: !18, enums: !9, retainedTypes: !9) !3 = !DISubroutineType(types: !4) diff --git a/test/Transforms/LoopReroll/reroll_with_dbg.ll b/test/Transforms/LoopReroll/reroll_with_dbg.ll index e239d0cad2c..78b457ed94a 100644 --- a/test/Transforms/LoopReroll/reroll_with_dbg.ll +++ b/test/Transforms/LoopReroll/reroll_with_dbg.ll @@ -11,7 +11,7 @@ target datalayout = "e-m:e-p:32:32-i64:64-v128:64:128-a:0:32-n32-S64" target triple = "armv4t--linux-gnueabi" ; Function Attrs: nounwind -define void @foo(float* noalias nocapture %a, float* noalias nocapture readonly %b, i32 %n) #0 { +define void @foo(float* noalias nocapture %a, float* noalias nocapture readonly %b, i32 %n) #0 !dbg !4 { entry: ;CHECK-LABEL: @foo @@ -89,7 +89,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "test.c", directory: "/home/weimingz/llvm-build/release/community-tip") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: true, function: void (float*, float*, i32)* @foo, variables: !11) +!4 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: true, variables: !11) !5 = !DISubroutineType(types: !6) !6 = !{null, !7, !7, !10} !7 = !DIDerivedType(tag: DW_TAG_restrict_type, baseType: !8) diff --git a/test/Transforms/LoopRotate/dbgvalue.ll b/test/Transforms/LoopRotate/dbgvalue.ll index 9dd5f00fbe6..d90841d1627 100644 --- a/test/Transforms/LoopRotate/dbgvalue.ll +++ b/test/Transforms/LoopRotate/dbgvalue.ll @@ -3,7 +3,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnone -define i32 @tak(i32 %x, i32 %y, i32 %z) nounwind ssp { +define i32 @tak(i32 %x, i32 %y, i32 %z) nounwind ssp !dbg !0 { ; CHECK-LABEL: define i32 @tak( ; CHECK: entry ; CHECK-NEXT: call void @llvm.dbg.value(metadata i32 %x @@ -84,7 +84,7 @@ for.end: !llvm.module.flags = !{!20} !llvm.dbg.sp = !{!0} -!0 = distinct !DISubprogram(name: "tak", line: 32, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !18, scope: !1, type: !3, function: i32 (i32, i32, i32)* @tak) +!0 = distinct !DISubprogram(name: "tak", line: 32, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !18, scope: !1, type: !3) !1 = !DIFile(filename: "/Volumes/Lalgate/cj/llvm/projects/llvm-test/SingleSource/Benchmarks/BenchmarkGame/recursive.c", directory: "/Volumes/Lalgate/cj/D/projects/llvm-test/SingleSource/Benchmarks/BenchmarkGame") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 2.9 (trunk 125492)", isOptimized: true, emissionKind: 0, file: !18, enums: !19, retainedTypes: !19) !3 = !DISubroutineType(types: !4) diff --git a/test/Transforms/LoopSimplify/dbg-loc.ll b/test/Transforms/LoopSimplify/dbg-loc.ll index 1395a210ffe..b0e14bbcfd7 100644 --- a/test/Transforms/LoopSimplify/dbg-loc.ll +++ b/test/Transforms/LoopSimplify/dbg-loc.ll @@ -16,7 +16,7 @@ declare void @f3() ; CHECK: for.end.loopexit: ; CHECK-NEXT: br label %for.end, !dbg [[LOOPEXIT_LOC:![0-9]+]] -define linkonce_odr hidden void @foo(%"Length"* %begin, %"Length"* %end) nounwind ssp uwtable align 2 { +define linkonce_odr hidden void @foo(%"Length"* %begin, %"Length"* %end) nounwind ssp uwtable align 2 !dbg !6 { entry: %cmp.4 = icmp eq %"Length"* %begin, %end, !dbg !7 br i1 %cmp.4, label %for.end, label %for.body, !dbg !8 @@ -80,7 +80,7 @@ eh.resume: ; preds = %catch !3 = !{} !4 = !DISubroutineType(types: !3) !5 = !DIFile(filename: "Vector.h", directory: "/tmp") -!6 = distinct !DISubprogram(name: "destruct", scope: !5, file: !5, line: 71, type: !4, isLocal: false, isDefinition: true, scopeLine: 72, flags: DIFlagPrototyped, isOptimized: false, function: void (%"Length"*, %"Length"*)* @foo, variables: !3) +!6 = distinct !DISubprogram(name: "destruct", scope: !5, file: !5, line: 71, type: !4, isLocal: false, isDefinition: true, scopeLine: 72, flags: DIFlagPrototyped, isOptimized: false, variables: !3) !7 = !DILocation(line: 73, column: 38, scope: !6) !8 = !DILocation(line: 73, column: 13, scope: !6) !9 = !DILocation(line: 73, column: 27, scope: !6) diff --git a/test/Transforms/LoopUnroll/runtime-loop1.ll b/test/Transforms/LoopUnroll/runtime-loop1.ll index 8ab5b66a4c7..dcf159a09a1 100644 --- a/test/Transforms/LoopUnroll/runtime-loop1.ll +++ b/test/Transforms/LoopUnroll/runtime-loop1.ll @@ -15,7 +15,7 @@ ; CHECK-DAG: [[PH_LOC]] = !DILocation(line: 101, column: 1, scope: !{{.*}}) ; CHECK-DAG: [[BODY_LOC]] = !DILocation(line: 102, column: 1, scope: !{{.*}}) -define i32 @test(i32* nocapture %a, i32 %n) nounwind uwtable readonly { +define i32 @test(i32* nocapture %a, i32 %n) nounwind uwtable readonly !dbg !6 { entry: %cmp1 = icmp eq i32 %n, 0, !dbg !7 br i1 %cmp1, label %for.end, label %for.body, !dbg !7 @@ -44,7 +44,7 @@ for.end: ; preds = %for.body, %entry !3 = !{} !4 = !DISubroutineType(types: !3) !5 = !DIFile(filename: "test.cpp", directory: "/tmp") -!6 = distinct !DISubprogram(name: "test", scope: !5, file: !5, line: 99, type: !4, isLocal: false, isDefinition: true, scopeLine: 100, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32*, i32)* @test, variables: !3) +!6 = distinct !DISubprogram(name: "test", scope: !5, file: !5, line: 99, type: !4, isLocal: false, isDefinition: true, scopeLine: 100, flags: DIFlagPrototyped, isOptimized: false, variables: !3) !7 = !DILocation(line: 100, column: 1, scope: !6) !8 = !DILocation(line: 101, column: 1, scope: !6) !9 = !DILocation(line: 102, column: 1, scope: !6) diff --git a/test/Transforms/LoopVectorize/X86/no_fpmath.ll b/test/Transforms/LoopVectorize/X86/no_fpmath.ll index a120e8e2e07..0bb78ce177f 100644 --- a/test/Transforms/LoopVectorize/X86/no_fpmath.ll +++ b/test/Transforms/LoopVectorize/X86/no_fpmath.ll @@ -8,7 +8,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-apple-macosx10.10.0" ; Function Attrs: nounwind readonly ssp uwtable -define double @cond_sum(i32* nocapture readonly %v, i32 %n) #0 { +define double @cond_sum(i32* nocapture readonly %v, i32 %n) #0 !dbg !4 { entry: %cmp.7 = icmp sgt i32 %n, 0, !dbg !3 br i1 %cmp.7, label %for.body.preheader, label %for.cond.cleanup, !dbg !8 @@ -39,7 +39,7 @@ for.body: ; preds = %for.body.preheader, } ; Function Attrs: nounwind readonly ssp uwtable -define double @cond_sum_loop_hint(i32* nocapture readonly %v, i32 %n) #0 { +define double @cond_sum_loop_hint(i32* nocapture readonly %v, i32 %n) #0 !dbg !20 { entry: %cmp.7 = icmp sgt i32 %n, 0, !dbg !19 br i1 %cmp.7, label %for.body.preheader, label %for.cond.cleanup, !dbg !21 @@ -78,7 +78,7 @@ attributes #0 = { nounwind } !1 = !{i32 1, !"PIC Level", i32 2} !2 = !{!"clang version 3.7.0"} !3 = !DILocation(line: 5, column: 20, scope: !4) -!4 = distinct !DISubprogram(name: "cond_sum", scope: !5, file: !5, line: 1, type: !6, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: true, function: double (i32*, i32)* @cond_sum, variables: !7) +!4 = distinct !DISubprogram(name: "cond_sum", scope: !5, file: !5, line: 1, type: !6, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: true, variables: !7) !5 = !DIFile(filename: "no_fpmath.c", directory: "") !6 = !DISubroutineType(types: !7) !7 = !{} @@ -94,7 +94,7 @@ attributes #0 = { nounwind } !17 = distinct !{!17, !18} !18 = !{!"llvm.loop.unroll.disable"} !19 = !DILocation(line: 16, column: 20, scope: !20) -!20 = distinct !DISubprogram(name: "cond_sum_loop_hint", scope: !5, file: !5, line: 12, type: !6, isLocal: false, isDefinition: true, scopeLine: 12, flags: DIFlagPrototyped, isOptimized: true, function: double (i32*, i32)* @cond_sum_loop_hint, variables: !7) +!20 = distinct !DISubprogram(name: "cond_sum_loop_hint", scope: !5, file: !5, line: 12, type: !6, isLocal: false, isDefinition: true, scopeLine: 12, flags: DIFlagPrototyped, isOptimized: true, variables: !7) !21 = !DILocation(line: 16, column: 3, scope: !20) !22 = !DILocation(line: 17, column: 14, scope: !20) !23 = !DILocation(line: 20, column: 3, scope: !20) diff --git a/test/Transforms/LoopVectorize/X86/vectorization-remarks-missed.ll b/test/Transforms/LoopVectorize/X86/vectorization-remarks-missed.ll index 1435e023eb9..02fab444734 100644 --- a/test/Transforms/LoopVectorize/X86/vectorization-remarks-missed.ll +++ b/test/Transforms/LoopVectorize/X86/vectorization-remarks-missed.ll @@ -45,7 +45,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" ; Function Attrs: nounwind optsize ssp uwtable -define void @_Z4testPii(i32* nocapture %A, i32 %Length) #0 { +define void @_Z4testPii(i32* nocapture %A, i32 %Length) #0 !dbg !4 { entry: %cmp10 = icmp sgt i32 %Length, 0, !dbg !12 br i1 %cmp10, label %for.body, label %for.end, !dbg !12, !llvm.loop !14 @@ -67,7 +67,7 @@ for.end: ; preds = %for.body, %entry } ; Function Attrs: nounwind optsize ssp uwtable -define void @_Z13test_disabledPii(i32* nocapture %A, i32 %Length) #0 { +define void @_Z13test_disabledPii(i32* nocapture %A, i32 %Length) #0 !dbg !7 { entry: %cmp4 = icmp sgt i32 %Length, 0, !dbg !25 br i1 %cmp4, label %for.body, label %for.end, !dbg !25, !llvm.loop !27 @@ -87,7 +87,7 @@ for.end: ; preds = %for.body, %entry } ; Function Attrs: nounwind optsize ssp uwtable -define void @_Z17test_array_boundsPiS_i(i32* nocapture %A, i32* nocapture readonly %B, i32 %Length) #0 { +define void @_Z17test_array_boundsPiS_i(i32* nocapture %A, i32* nocapture readonly %B, i32 %Length) #0 !dbg !8 { entry: %cmp9 = icmp sgt i32 %Length, 0, !dbg !32 br i1 %cmp9, label %for.body.preheader, label %for.end, !dbg !32, !llvm.loop !34 @@ -126,11 +126,11 @@ attributes #0 = { nounwind } !1 = !DIFile(filename: "source.cpp", directory: ".") !2 = !{} !3 = !{!4, !7, !8} -!4 = distinct !DISubprogram(name: "test", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !1, scope: !5, type: !6, function: void (i32*, i32)* @_Z4testPii, variables: !2) +!4 = distinct !DISubprogram(name: "test", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "source.cpp", directory: ".") !6 = !DISubroutineType(types: !2) -!7 = distinct !DISubprogram(name: "test_disabled", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 10, file: !1, scope: !5, type: !6, function: void (i32*, i32)* @_Z13test_disabledPii, variables: !2) -!8 = distinct !DISubprogram(name: "test_array_bounds", line: 16, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 16, file: !1, scope: !5, type: !6, function: void (i32*, i32*, i32)* @_Z17test_array_boundsPiS_i, variables: !2) +!7 = distinct !DISubprogram(name: "test_disabled", line: 10, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 10, file: !1, scope: !5, type: !6, variables: !2) +!8 = distinct !DISubprogram(name: "test_array_bounds", line: 16, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 16, file: !1, scope: !5, type: !6, variables: !2) !9 = !{i32 2, !"Dwarf Version", i32 2} !10 = !{i32 2, !"Debug Info Version", i32 3} !11 = !{!"clang version 3.5.0"} diff --git a/test/Transforms/LoopVectorize/X86/vectorization-remarks-profitable.ll b/test/Transforms/LoopVectorize/X86/vectorization-remarks-profitable.ll index 82c246e1857..df8c668f126 100644 --- a/test/Transforms/LoopVectorize/X86/vectorization-remarks-profitable.ll +++ b/test/Transforms/LoopVectorize/X86/vectorization-remarks-profitable.ll @@ -23,7 +23,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-apple-macosx10.10.0" ; Function Attrs: nounwind uwtable -define void @do_not_interleave(float** noalias nocapture readonly %in, float* noalias nocapture %out, i32 %size) #0 { +define void @do_not_interleave(float** noalias nocapture readonly %in, float* noalias nocapture %out, i32 %size) #0 !dbg !4 { entry: %cmp.4 = icmp eq i32 %size, 0, !dbg !10 br i1 %cmp.4, label %for.end, label %for.body.preheader, !dbg !11 @@ -53,7 +53,7 @@ for.end: ; preds = %for.end.loopexit, % } ; Function Attrs: nounwind uwtable -define void @interleave_not_profitable(float** noalias nocapture readonly %in, float* noalias nocapture %out, i32 %size) #0 { +define void @interleave_not_profitable(float** noalias nocapture readonly %in, float* noalias nocapture %out, i32 %size) #0 !dbg !6 { entry: %cmp.4 = icmp eq i32 %size, 0, !dbg !20 br i1 %cmp.4, label %for.end, label %for.body, !dbg !21 @@ -86,9 +86,9 @@ attributes #0 = { nounwind uwtable "disable-tail-calls"="false" "less-precise-fp !1 = !DIFile(filename: "vectorization-remarks-profitable.c", directory: "") !2 = !{} !3 = !{!4, !6} -!4 = distinct !DISubprogram(name: "do_not_interleave", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: false, function: void (float**, float*, i32)* @do_not_interleave, variables: !2) +!4 = distinct !DISubprogram(name: "do_not_interleave", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !2) -!6 = distinct !DISubprogram(name: "interleave_not_profitable", scope: !1, file: !1, line: 8, type: !5, isLocal: false, isDefinition: true, scopeLine: 8, flags: DIFlagPrototyped, isOptimized: false, function: void (float**, float*, i32)* @interleave_not_profitable, variables: !2) +!6 = distinct !DISubprogram(name: "interleave_not_profitable", scope: !1, file: !1, line: 8, type: !5, isLocal: false, isDefinition: true, scopeLine: 8, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !7 = !{i32 2, !"Dwarf Version", i32 4} !8 = !{i32 2, !"Debug Info Version", i32 3} !9 = !{!"clang version 3.8.0 (trunk 250016)"} diff --git a/test/Transforms/LoopVectorize/X86/vectorization-remarks.ll b/test/Transforms/LoopVectorize/X86/vectorization-remarks.ll index 17d6ec481b5..77a405ebb43 100644 --- a/test/Transforms/LoopVectorize/X86/vectorization-remarks.ll +++ b/test/Transforms/LoopVectorize/X86/vectorization-remarks.ll @@ -15,7 +15,7 @@ target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128" -define i32 @foo(i32 %n) #0 { +define i32 @foo(i32 %n) #0 !dbg !4 { entry: %diff = alloca i32, align 4 %cb = alloca [16 x i8], align 16 @@ -52,7 +52,7 @@ declare void @ibar(i32*) #1 !1 = !DIFile(filename: "vectorization-remarks.c", directory: ".") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 6, file: !1, scope: !5, type: !6, function: i32 (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 6, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "vectorization-remarks.c", directory: ".") !6 = !DISubroutineType(types: !2) !7 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/Transforms/LoopVectorize/conditional-assignment.ll b/test/Transforms/LoopVectorize/conditional-assignment.ll index 454966e9613..8d820e277b2 100644 --- a/test/Transforms/LoopVectorize/conditional-assignment.ll +++ b/test/Transforms/LoopVectorize/conditional-assignment.ll @@ -6,7 +6,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-apple-macosx10.9.0" ; Function Attrs: nounwind ssp uwtable -define void @conditional_store(i32* noalias nocapture %indices) #0 { +define void @conditional_store(i32* noalias nocapture %indices) #0 !dbg !4 { entry: br label %for.body, !dbg !10 @@ -40,7 +40,7 @@ attributes #0 = { nounwind } !1 = !DIFile(filename: "source.c", directory: ".") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "conditional_store", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !1, scope: !5, type: !6, function: void (i32*)* @conditional_store, variables: !2) +!4 = distinct !DISubprogram(name: "conditional_store", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "source.c", directory: ".") !6 = !DISubroutineType(types: !2) !7 = !{i32 2, !"Dwarf Version", i32 2} diff --git a/test/Transforms/LoopVectorize/control-flow.ll b/test/Transforms/LoopVectorize/control-flow.ll index 2f2b1fd8d46..a2fc69a6e90 100644 --- a/test/Transforms/LoopVectorize/control-flow.ll +++ b/test/Transforms/LoopVectorize/control-flow.ll @@ -20,7 +20,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" ; Function Attrs: nounwind optsize ssp uwtable -define i32 @_Z4testPii(i32* nocapture %A, i32 %Length) #0 { +define i32 @_Z4testPii(i32* nocapture %A, i32 %Length) #0 !dbg !4 { entry: %cmp8 = icmp sgt i32 %Length, 0, !dbg !10 br i1 %cmp8, label %for.body.preheader, label %end, !dbg !10 @@ -59,7 +59,7 @@ attributes #0 = { nounwind } !1 = !DIFile(filename: "source.cpp", directory: ".") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "test", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !1, scope: !5, type: !6, function: i32 (i32*, i32)* @_Z4testPii, variables: !2) +!4 = distinct !DISubprogram(name: "test", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "source.cpp", directory: ".") !6 = !DISubroutineType(types: !2) !7 = !{i32 2, !"Dwarf Version", i32 2} diff --git a/test/Transforms/LoopVectorize/dbg.value.ll b/test/Transforms/LoopVectorize/dbg.value.ll index ae949b37555..f68b6865b07 100644 --- a/test/Transforms/LoopVectorize/dbg.value.ll +++ b/test/Transforms/LoopVectorize/dbg.value.ll @@ -9,7 +9,7 @@ target triple = "x86_64-apple-macosx10.8.0" @C = global [1024 x i32] zeroinitializer, align 16 ; CHECK-LABEL: @test( -define i32 @test() #0 { +define i32 @test() #0 !dbg !3 { entry: tail call void @llvm.dbg.value(metadata i32 0, i64 0, metadata !9, metadata !DIExpression()), !dbg !18 br label %for.body, !dbg !18 @@ -47,7 +47,7 @@ attributes #1 = { nounwind readnone } !0 = distinct !DICompileUnit(language: DW_LANG_C_plus_plus, producer: "clang", isOptimized: true, emissionKind: 0, file: !25, enums: !1, retainedTypes: !1, subprograms: !2, globals: !11) !1 = !{} !2 = !{!3} -!3 = distinct !DISubprogram(name: "test", linkageName: "test", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !25, scope: !4, type: !5, function: i32 ()* @test, variables: !8) +!3 = distinct !DISubprogram(name: "test", linkageName: "test", line: 5, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !25, scope: !4, type: !5, variables: !8) !4 = !DIFile(filename: "test", directory: "/path/to/somewhere") !5 = !DISubroutineType(types: !6) !6 = !{!7} diff --git a/test/Transforms/LoopVectorize/debugloc.ll b/test/Transforms/LoopVectorize/debugloc.ll index c5277c36b3f..0214f1c4847 100644 --- a/test/Transforms/LoopVectorize/debugloc.ll +++ b/test/Transforms/LoopVectorize/debugloc.ll @@ -17,7 +17,7 @@ target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f3 ; CHECK: add <2 x i32> %{{.*}}, %rdx.shuf, !dbg ![[LOC2]] ; CHECK: extractelement <2 x i32> %bin.rdx, i32 0, !dbg ![[LOC2]] -define i32 @f(i32* nocapture %a, i32 %size) #0 { +define i32 @f(i32* nocapture %a, i32 %size) #0 !dbg !4 { entry: tail call void @llvm.dbg.value(metadata i32* %a, i64 0, metadata !13, metadata !DIExpression()), !dbg !19 tail call void @llvm.dbg.value(metadata i32 %size, i64 0, metadata !14, metadata !DIExpression()), !dbg !19 @@ -67,7 +67,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "-", directory: "/Volumes/Data/backedup/dev/os/llvm/debug") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !5, scope: !6, type: !7, function: i32 (i32*, i32)* @f, variables: !12) +!4 = distinct !DISubprogram(name: "f", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 3, file: !5, scope: !6, type: !7, variables: !12) !5 = !DIFile(filename: "<stdin>", directory: "/Volumes/Data/backedup/dev/os/llvm/debug") !6 = !DIFile(filename: "<stdin>", directory: "/Volumes/Data/backedup/dev/os/llvm/debug") !7 = !DISubroutineType(types: !8) diff --git a/test/Transforms/LoopVectorize/no_array_bounds.ll b/test/Transforms/LoopVectorize/no_array_bounds.ll index d8bcecf48bf..13cec71fc45 100644 --- a/test/Transforms/LoopVectorize/no_array_bounds.ll +++ b/test/Transforms/LoopVectorize/no_array_bounds.ll @@ -17,7 +17,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" ; Function Attrs: nounwind ssp uwtable -define void @_Z4testPiS_i(i32* nocapture %A, i32* nocapture %B, i32 %number) #0 { +define void @_Z4testPiS_i(i32* nocapture %A, i32* nocapture %B, i32 %number) #0 !dbg !4 { entry: %cmp25 = icmp sgt i32 %number, 0, !dbg !10 br i1 %cmp25, label %for.body.preheader, label %for.end15, !dbg !10, !llvm.loop !12 @@ -76,7 +76,7 @@ attributes #0 = { nounwind } !1 = !DIFile(filename: "no_array_bounds.cpp", directory: ".") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "test", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !1, scope: !5, type: !6, function: void (i32*, i32*, i32)* @_Z4testPiS_i, variables: !2) +!4 = distinct !DISubprogram(name: "test", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 2, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "no_array_bounds.cpp", directory: ".") !6 = !DISubroutineType(types: !2) !7 = !{i32 2, !"Dwarf Version", i32 2} diff --git a/test/Transforms/LoopVectorize/no_switch.ll b/test/Transforms/LoopVectorize/no_switch.ll index 5ba622eae63..842d262d319 100644 --- a/test/Transforms/LoopVectorize/no_switch.ll +++ b/test/Transforms/LoopVectorize/no_switch.ll @@ -19,7 +19,7 @@ target datalayout = "e-m:o-i64:64-f80:128-n8:16:32:64-S128" ; Function Attrs: nounwind optsize ssp uwtable -define void @_Z11test_switchPii(i32* nocapture %A, i32 %Length) #0 { +define void @_Z11test_switchPii(i32* nocapture %A, i32 %Length) #0 !dbg !4 { entry: %cmp18 = icmp sgt i32 %Length, 0, !dbg !10 br i1 %cmp18, label %for.body.preheader, label %for.end, !dbg !10, !llvm.loop !12 @@ -71,7 +71,7 @@ attributes #0 = { nounwind } !1 = !DIFile(filename: "source.cpp", directory: ".") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "test_switch", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !1, scope: !5, type: !6, function: void (i32*, i32)* @_Z11test_switchPii, variables: !2) +!4 = distinct !DISubprogram(name: "test_switch", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "source.cpp", directory: ".") !6 = !DISubroutineType(types: !2) !7 = !{i32 2, !"Dwarf Version", i32 2} diff --git a/test/Transforms/Mem2Reg/ConvertDebugInfo.ll b/test/Transforms/Mem2Reg/ConvertDebugInfo.ll index 6b6d8e4c84e..6aaf594b305 100644 --- a/test/Transforms/Mem2Reg/ConvertDebugInfo.ll +++ b/test/Transforms/Mem2Reg/ConvertDebugInfo.ll @@ -1,6 +1,6 @@ ; RUN: opt < %s -mem2reg -S | FileCheck %s -define double @testfunc(i32 %i, double %j) nounwind ssp { +define double @testfunc(i32 %i, double %j) nounwind ssp !dbg !1 { entry: %i_addr = alloca i32 ; <i32*> [#uses=2] %j_addr = alloca double ; <double*> [#uses=2] @@ -36,7 +36,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !llvm.module.flags = !{!14} !0 = !DILocalVariable(name: "i", line: 2, arg: 1, scope: !1, file: !2, type: !7) -!1 = distinct !DISubprogram(name: "testfunc", linkageName: "testfunc", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 2, file: !12, scope: !2, type: !4, function: double (i32, double)* @testfunc) +!1 = distinct !DISubprogram(name: "testfunc", linkageName: "testfunc", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 2, file: !12, scope: !2, type: !4) !2 = !DIFile(filename: "testfunc.c", directory: "/tmp") !3 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: true, emissionKind: 0, file: !12, enums: !13, retainedTypes: !13, subprograms: !{!1}) !4 = !DISubroutineType(types: !5) diff --git a/test/Transforms/Mem2Reg/ConvertDebugInfo2.ll b/test/Transforms/Mem2Reg/ConvertDebugInfo2.ll index 331ddc773b0..071d708e1fe 100644 --- a/test/Transforms/Mem2Reg/ConvertDebugInfo2.ll +++ b/test/Transforms/Mem2Reg/ConvertDebugInfo2.ll @@ -4,7 +4,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone declare void @foo(i32, i64, i8*) -define void @baz(i32 %a) nounwind ssp { +define void @baz(i32 %a) nounwind ssp !dbg !1 { ; CHECK-LABEL: entry: ; CHECK-NEXT: %"alloca point" = bitcast i32 0 to i32{{$}} ; CHECK-NEXT: call void @llvm.dbg.value(metadata i32 %a,{{.*}}, !dbg @@ -43,7 +43,7 @@ return: ; preds = %entry !llvm.dbg.cu = !{!3} !llvm.module.flags = !{!22} !0 = !DILocalVariable(name: "a", line: 8, arg: 1, scope: !1, file: !2, type: !6) -!1 = distinct !DISubprogram(name: "baz", linkageName: "baz", line: 8, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 8, file: !20, scope: !2, type: !4, function: void (i32)* @baz) +!1 = distinct !DISubprogram(name: "baz", linkageName: "baz", line: 8, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, scopeLine: 8, file: !20, scope: !2, type: !4) !2 = !DIFile(filename: "bar.c", directory: "/tmp/") !3 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: true, emissionKind: 0, file: !20, enums: !21, retainedTypes: !21, subprograms: !{!1}) !4 = !DISubroutineType(types: !5) diff --git a/test/Transforms/ObjCARC/ensure-that-exception-unwind-path-is-visited.ll b/test/Transforms/ObjCARC/ensure-that-exception-unwind-path-is-visited.ll index e4b3e4a2216..ef8d8e52d1c 100644 --- a/test/Transforms/ObjCARC/ensure-that-exception-unwind-path-is-visited.ll +++ b/test/Transforms/ObjCARC/ensure-that-exception-unwind-path-is-visited.ll @@ -34,7 +34,7 @@ target triple = "x86_64-apple-macosx10.9.0" @"\01L_OBJC_SELECTOR_REFERENCES_5" = internal global i8* getelementptr inbounds ([14 x i8], [14 x i8]* @"\01L_OBJC_METH_VAR_NAME_4", i64 0, i64 0), section "__DATA, __objc_selrefs, literal_pointers, no_dead_strip" @llvm.used = appending global [6 x i8*] [i8* bitcast (%struct._class_t** @"\01L_OBJC_CLASSLIST_REFERENCES_$_" to i8*), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @"\01L_OBJC_METH_VAR_NAME_", i32 0, i32 0), i8* bitcast (i8** @"\01L_OBJC_SELECTOR_REFERENCES_" to i8*), i8* bitcast (%struct._class_t** @"\01L_OBJC_CLASSLIST_REFERENCES_$_1" to i8*), i8* getelementptr inbounds ([14 x i8], [14 x i8]* @"\01L_OBJC_METH_VAR_NAME_4", i32 0, i32 0), i8* bitcast (i8** @"\01L_OBJC_SELECTOR_REFERENCES_5" to i8*)], section "llvm.metadata" -define i32 @main() uwtable ssp personality i8* bitcast (i32 (...)* @__objc_personality_v0 to i8*) { +define i32 @main() uwtable ssp personality i8* bitcast (i32 (...)* @__objc_personality_v0 to i8*) !dbg !5 { entry: %tmp = load %struct._class_t*, %struct._class_t** @"\01L_OBJC_CLASSLIST_REFERENCES_$_", align 8, !dbg !37 %tmp1 = load i8*, i8** @"\01L_OBJC_SELECTOR_REFERENCES_", align 8, !dbg !37, !invariant.load !38 @@ -84,7 +84,7 @@ declare void @objc_end_catch() declare void @objc_exception_rethrow() -define internal fastcc void @ThrowFunc(i8* %obj) uwtable noinline ssp { +define internal fastcc void @ThrowFunc(i8* %obj) uwtable noinline ssp !dbg !27 { entry: %tmp = call i8* @objc_retain(i8* %obj) nounwind call void @llvm.dbg.value(metadata i8* %obj, i64 0, metadata !32, metadata !DIExpression()), !dbg !55 @@ -116,7 +116,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !0 = distinct !DICompileUnit(language: DW_LANG_ObjC, producer: "clang version 3.3 ", isOptimized: true, runtimeVersion: 2, emissionKind: 0, file: !60, enums: !1, retainedTypes: !1, subprograms: !3, globals: !1) !1 = !{} !3 = !{!5, !27} -!5 = distinct !DISubprogram(name: "main", line: 9, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 10, file: !60, scope: !6, type: !7, function: i32 ()* @main, variables: !11) +!5 = distinct !DISubprogram(name: "main", line: 9, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, scopeLine: 10, file: !60, scope: !6, type: !7, variables: !11) !6 = !DIFile(filename: "test.m", directory: "/Volumes/Files/gottesmmcab/Radar/12906997") !7 = !DISubroutineType(types: !8) !8 = !{!9} @@ -137,7 +137,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !24 = !DIBasicType(tag: DW_TAG_base_type, name: "signed char", size: 8, align: 8, encoding: DW_ATE_signed_char) !25 = !DILocalVariable(name: "obj2", line: 15, scope: !26, file: !6, type: !14) !26 = distinct !DILexicalBlock(line: 14, column: 0, file: !60, scope: !22) -!27 = distinct !DISubprogram(name: "ThrowFunc", line: 4, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !60, scope: !6, type: !28, function: void (i8*)* @ThrowFunc, variables: !31) +!27 = distinct !DISubprogram(name: "ThrowFunc", line: 4, isLocal: true, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 5, file: !60, scope: !6, type: !28, variables: !31) !28 = !DISubroutineType(types: !29) !29 = !{null, !14} !31 = !{!32} diff --git a/test/Transforms/SLPVectorizer/X86/debug_info.ll b/test/Transforms/SLPVectorizer/X86/debug_info.ll index 1ced8bbcaf8..4472225811b 100644 --- a/test/Transforms/SLPVectorizer/X86/debug_info.ll +++ b/test/Transforms/SLPVectorizer/X86/debug_info.ll @@ -21,7 +21,7 @@ target triple = "x86_64-apple-macosx10.7.0" ;CHECK: ![[LOC]] = !DILocation(line: 4, scope: ;CHECK: ![[LOC2]] = !DILocation(line: 7, scope: -define i32 @depth(double* nocapture %A, i32 %m) #0 { +define i32 @depth(double* nocapture %A, i32 %m) #0 !dbg !4 { entry: tail call void @llvm.dbg.value(metadata double* %A, i64 0, metadata !12, metadata !DIExpression()), !dbg !19 tail call void @llvm.dbg.value(metadata i32 %m, i64 0, metadata !13, metadata !DIExpression()), !dbg !19 @@ -61,7 +61,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "file.c", directory: "/Users/nadav") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "depth", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 (double*, i32)* @depth, variables: !11) +!4 = distinct !DISubprogram(name: "depth", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !11) !5 = !DIFile(filename: "file.c", directory: "/Users/nadav") !6 = !DISubroutineType(types: !7) !7 = !{!8, !9, !8} diff --git a/test/Transforms/SafeStack/debug-loc.ll b/test/Transforms/SafeStack/debug-loc.ll index d157ee6e65a..57d565f8cfd 100644 --- a/test/Transforms/SafeStack/debug-loc.ll +++ b/test/Transforms/SafeStack/debug-loc.ll @@ -24,7 +24,7 @@ target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-unknown-linux-gnu" ; Function Attrs: safestack uwtable -define void @f() #0 { +define void @f() #0 !dbg !4 { entry: %buf = alloca [100 x i32], align 16 %0 = bitcast [100 x i32]* %buf to i8*, !dbg !16 @@ -63,7 +63,7 @@ attributes #4 = { nounwind } !1 = !DIFile(filename: "1.cc", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f", scope: !1, file: !1, line: 4, type: !5, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: true, function: void ()* @f, variables: !7) +!4 = distinct !DISubprogram(name: "f", scope: !1, file: !1, line: 4, type: !5, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: true, variables: !7) !5 = !DISubroutineType(types: !6) !6 = !{null} !7 = !{!8} diff --git a/test/Transforms/SampleProfile/branch.ll b/test/Transforms/SampleProfile/branch.ll index 9ee124b8d8c..1700749f0be 100644 --- a/test/Transforms/SampleProfile/branch.ll +++ b/test/Transforms/SampleProfile/branch.ll @@ -28,7 +28,7 @@ @.str = private unnamed_addr constant [15 x i8] c"result is %lf\0A\00", align 1 ; Function Attrs: uwtable -define i32 @main(i32 %argc, i8** %argv) #0 { +define i32 @main(i32 %argc, i8** %argv) #0 !dbg !6 { ; CHECK: Printing analysis 'Branch Probability Analysis' for function 'main': entry: @@ -163,7 +163,7 @@ attributes #4 = { nounwind readonly } !3 = !{!4} !4 = !DIBasicType(name: "double", size: 64, align: 64, encoding: DW_ATE_float) !5 = !{!6} -!6 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 4, type: !7, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32, i8**)* @main, variables: !2) +!6 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 4, type: !7, isLocal: false, isDefinition: true, scopeLine: 4, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !7 = !DISubroutineType(types: !8) !8 = !{!9, !9, !10} !9 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/Transforms/SampleProfile/calls.ll b/test/Transforms/SampleProfile/calls.ll index aa176434cc2..53ea9297d7d 100644 --- a/test/Transforms/SampleProfile/calls.ll +++ b/test/Transforms/SampleProfile/calls.ll @@ -24,7 +24,7 @@ @.str = private unnamed_addr constant [11 x i8] c"sum is %d\0A\00", align 1 ; Function Attrs: nounwind uwtable -define i32 @_Z3sumii(i32 %x, i32 %y) { +define i32 @_Z3sumii(i32 %x, i32 %y) !dbg !4 { entry: %x.addr = alloca i32, align 4 %y.addr = alloca i32, align 4 @@ -37,7 +37,7 @@ entry: } ; Function Attrs: uwtable -define i32 @main() { +define i32 @main() !dbg !7 { entry: %retval = alloca i32, align 4 %s = alloca i32, align 4 @@ -96,10 +96,10 @@ declare i32 @printf(i8*, ...) #2 !1 = !DIFile(filename: "calls.cc", directory: ".") !2 = !{} !3 = !{!4, !7} -!4 = distinct !DISubprogram(name: "sum", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, function: i32 (i32, i32)* @_Z3sumii, variables: !2) +!4 = distinct !DISubprogram(name: "sum", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "calls.cc", directory: ".") !6 = !DISubroutineType(types: !2) -!7 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !2) +!7 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !5, type: !6, variables: !2) !8 = !{i32 2, !"Dwarf Version", i32 4} !9 = !{i32 1, !"Debug Info Version", i32 3} !10 = !{!"clang version 3.5 "} diff --git a/test/Transforms/SampleProfile/coverage-warning.ll b/test/Transforms/SampleProfile/coverage-warning.ll index f96068002dd..7407bef9e9d 100644 --- a/test/Transforms/SampleProfile/coverage-warning.ll +++ b/test/Transforms/SampleProfile/coverage-warning.ll @@ -1,5 +1,5 @@ ; RUN: opt < %s -sample-profile -sample-profile-file=%S/Inputs/coverage-warning.prof -sample-profile-check-coverage=90 2>& 1 | FileCheck %s -define i32 @foo(i32 %i) { +define i32 @foo(i32 %i) !dbg !4 { ; The profile has samples for line locations that are no longer present. ; Coverage does not reach 90%, so we should get this warning: ; @@ -33,7 +33,7 @@ return: ; preds = %if.end, %if.then !1 = !DIFile(filename: "coverage-warning.c", directory: ".") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !2) !6 = !{i32 2, !"Dwarf Version", i32 4} !7 = !{i32 2, !"Debug Info Version", i32 3} diff --git a/test/Transforms/SampleProfile/discriminator.ll b/test/Transforms/SampleProfile/discriminator.ll index ffc474b82fd..0915fc884f8 100644 --- a/test/Transforms/SampleProfile/discriminator.ll +++ b/test/Transforms/SampleProfile/discriminator.ll @@ -21,7 +21,7 @@ ; This means that the predicate 'i < 5' (line 3) is executed 100 times, ; but the then branch (line 3.1) is only executed 5 times. -define i32 @foo(i32 %i) #0 { +define i32 @foo(i32 %i) #0 !dbg !4 { ; CHECK: Printing analysis 'Branch Probability Analysis' for function 'foo': entry: %i.addr = alloca i32, align 4 @@ -70,7 +70,7 @@ while.end: ; preds = %while.cond !1 = !DIFile(filename: "discriminator.c", directory: ".") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, function: i32 (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "discriminator.c", directory: ".") !6 = !DISubroutineType(types: !2) !7 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/Transforms/SampleProfile/entry_counts.ll b/test/Transforms/SampleProfile/entry_counts.ll index bfd65c0d651..50cd575295a 100644 --- a/test/Transforms/SampleProfile/entry_counts.ll +++ b/test/Transforms/SampleProfile/entry_counts.ll @@ -3,7 +3,7 @@ ; According to the profile, function empty() was called 13,293 times. ; CHECK: {{.*}} = !{!"function_entry_count", i64 13293} -define void @empty() { +define void @empty() !dbg !4 { entry: ret void, !dbg !9 } @@ -16,7 +16,7 @@ entry: !1 = !DIFile(filename: "entry_counts.c", directory: ".") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "empty", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, isOptimized: false, function: void ()* @empty, variables: !2) +!4 = distinct !DISubprogram(name: "empty", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !2) !6 = !{i32 2, !"Dwarf Version", i32 4} !7 = !{i32 2, !"Debug Info Version", i32 3} diff --git a/test/Transforms/SampleProfile/fnptr.ll b/test/Transforms/SampleProfile/fnptr.ll index f95bf9797d9..7b07ca9679b 100644 --- a/test/Transforms/SampleProfile/fnptr.ll +++ b/test/Transforms/SampleProfile/fnptr.ll @@ -46,7 +46,7 @@ @.str = private unnamed_addr constant [9 x i8] c"S = %lf\0A\00", align 1 -define double @_Z3fooi(i32 %x) #0 { +define double @_Z3fooi(i32 %x) #0 !dbg !3 { entry: %conv = sitofp i32 %x to double, !dbg !2 %call = tail call double @sin(double %conv) #3, !dbg !8 @@ -56,7 +56,7 @@ entry: declare double @sin(double) #1 -define double @_Z3bari(i32 %x) #0 { +define double @_Z3bari(i32 %x) #0 !dbg !10 { entry: %conv = sitofp i32 %x to double, !dbg !9 %call = tail call double @cos(double %conv) #3, !dbg !11 @@ -66,7 +66,7 @@ entry: declare double @cos(double) #1 -define i32 @main() #2 { +define i32 @main() #2 !dbg !13 { entry: br label %for.cond1.preheader, !dbg !12 @@ -130,17 +130,17 @@ declare i32 @printf(i8* nocapture readonly, ...) #1 !0 = !{i32 2, !"Debug Info Version", i32 3} !1 = !{!"clang version 3.6.0 "} !2 = !DILocation(line: 9, column: 3, scope: !3) -!3 = distinct !DISubprogram(name: "foo", line: 8, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 8, file: !4, scope: !5, type: !6, function: double (i32)* @_Z3fooi, variables: !7) +!3 = distinct !DISubprogram(name: "foo", line: 8, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 8, file: !4, scope: !5, type: !6, variables: !7) !4 = !DIFile(filename: "fnptr.cc", directory: ".") !5 = !DIFile(filename: "fnptr.cc", directory: ".") !6 = !DISubroutineType(types: !7) !7 = !{} !8 = !DILocation(line: 9, column: 14, scope: !3) !9 = !DILocation(line: 13, column: 3, scope: !10) -!10 = distinct !DISubprogram(name: "bar", line: 12, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 12, file: !4, scope: !5, type: !6, function: double (i32)* @_Z3bari, variables: !7) +!10 = distinct !DISubprogram(name: "bar", line: 12, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 12, file: !4, scope: !5, type: !6, variables: !7) !11 = !DILocation(line: 13, column: 14, scope: !10) !12 = !DILocation(line: 19, column: 3, scope: !13) -!13 = distinct !DISubprogram(name: "main", line: 16, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 16, file: !4, scope: !5, type: !6, function: i32 ()* @main, variables: !7) +!13 = distinct !DISubprogram(name: "main", line: 16, isLocal: false, isDefinition: true, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 16, file: !4, scope: !5, type: !6, variables: !7) !14 = !DILocation(line: 20, column: 5, scope: !13) !15 = !DILocation(line: 21, column: 15, scope: !13) !16 = !DILocation(line: 22, column: 11, scope: !13) diff --git a/test/Transforms/SampleProfile/gcc-simple.ll b/test/Transforms/SampleProfile/gcc-simple.ll index 75d54bf9304..1ae927158c1 100644 --- a/test/Transforms/SampleProfile/gcc-simple.ll +++ b/test/Transforms/SampleProfile/gcc-simple.ll @@ -24,7 +24,7 @@ ; $ perf record -b ./gcc-simple ; $ create_gcov --binary=gcc-simple --gcov=gcc-simple.afdo -define i64 @_Z3fool(i64 %i) #0 { +define i64 @_Z3fool(i64 %i) #0 !dbg !4 { ; CHECK: !prof ![[EC1:[0-9]+]] entry: %retval = alloca i64, align 8 @@ -66,7 +66,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 declare i32 @rand() #2 ; Function Attrs: nounwind uwtable -define i32 @main() #0 { +define i32 @main() #0 !dbg !9 { ; CHECK: !prof ![[EC2:[0-9]+]] entry: %retval = alloca i32, align 4 @@ -148,12 +148,12 @@ attributes #3 = { nounwind } !1 = !DIFile(filename: "discriminator.cc", directory: "/usr/local/google/home/dnovillo/llvm/test/autofdo") !2 = !{} !3 = !{!4, !9} -!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fool", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, function: i64 (i64)* @_Z3fool, variables: !2) +!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fool", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{!7, !8} !7 = !DIBasicType(name: "long long int", size: 64, align: 64, encoding: DW_ATE_signed) !8 = !DIBasicType(name: "long int", size: 64, align: 64, encoding: DW_ATE_signed) -!9 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 7, type: !10, isLocal: false, isDefinition: true, scopeLine: 7, flags: DIFlagPrototyped, isOptimized: false, function: i32 ()* @main, variables: !2) +!9 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 7, type: !10, isLocal: false, isDefinition: true, scopeLine: 7, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !10 = !DISubroutineType(types: !11) !11 = !{!12} !12 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/Transforms/SampleProfile/inline-coverage.ll b/test/Transforms/SampleProfile/inline-coverage.ll index 77927858983..4f87b1661a6 100644 --- a/test/Transforms/SampleProfile/inline-coverage.ll +++ b/test/Transforms/SampleProfile/inline-coverage.ll @@ -26,7 +26,7 @@ ; use: ; CHECK: warning: coverage.cc:7: 4 of 5 available profile records (80%) were applied -define i64 @_Z3fool(i64 %i) { +define i64 @_Z3fool(i64 %i) !dbg !4 { entry: %i.addr = alloca i64, align 8 store i64 %i, i64* %i.addr, align 8 @@ -42,7 +42,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) declare i32 @rand() -define i32 @main() { +define i32 @main() !dbg !9 { entry: %retval = alloca i32, align 4 %sum = alloca i64, align 8 @@ -89,12 +89,12 @@ for.end: ; preds = %for.cond !1 = !DIFile(filename: "coverage.cc", directory: ".") !2 = !{} !3 = !{!4, !9} -!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fool", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, function: i64 (i64)* @_Z3fool, variables: !2) +!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fool", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{!7, !8} !7 = !DIBasicType(name: "long long int", size: 64, align: 64, encoding: DW_ATE_signed) !8 = !DIBasicType(name: "long int", size: 64, align: 64, encoding: DW_ATE_signed) -!9 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 7, type: !10, isLocal: false, isDefinition: true, scopeLine: 7, flags: DIFlagPrototyped, isOptimized: false, function: i32 ()* @main, variables: !2) +!9 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 7, type: !10, isLocal: false, isDefinition: true, scopeLine: 7, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !10 = !DISubroutineType(types: !11) !11 = !{!12} !12 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/Transforms/SampleProfile/inline.ll b/test/Transforms/SampleProfile/inline.ll index 50f72811fbe..a128df56dbf 100644 --- a/test/Transforms/SampleProfile/inline.ll +++ b/test/Transforms/SampleProfile/inline.ll @@ -19,7 +19,7 @@ @.str = private unnamed_addr constant [11 x i8] c"sum is %d\0A\00", align 1 ; Function Attrs: nounwind uwtable -define i32 @_Z3sumii(i32 %x, i32 %y) { +define i32 @_Z3sumii(i32 %x, i32 %y) !dbg !4 { entry: %x.addr = alloca i32, align 4 %y.addr = alloca i32, align 4 @@ -32,7 +32,7 @@ entry: } ; Function Attrs: uwtable -define i32 @main() { +define i32 @main() !dbg !7 { entry: %retval = alloca i32, align 4 %s = alloca i32, align 4 @@ -84,10 +84,10 @@ declare i32 @printf(i8*, ...) #2 !1 = !DIFile(filename: "calls.cc", directory: ".") !2 = !{} !3 = !{!4, !7} -!4 = distinct !DISubprogram(name: "sum", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, function: i32 (i32, i32)* @_Z3sumii, variables: !2) +!4 = distinct !DISubprogram(name: "sum", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "calls.cc", directory: ".") !6 = !DISubroutineType(types: !2) -!7 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !2) +!7 = distinct !DISubprogram(name: "main", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 7, file: !1, scope: !5, type: !6, variables: !2) !8 = !{i32 2, !"Dwarf Version", i32 4} !9 = !{i32 1, !"Debug Info Version", i32 3} !10 = !{!"clang version 3.5 "} diff --git a/test/Transforms/SampleProfile/nolocinfo.ll b/test/Transforms/SampleProfile/nolocinfo.ll index d700e5f289a..08bca20984d 100644 --- a/test/Transforms/SampleProfile/nolocinfo.ll +++ b/test/Transforms/SampleProfile/nolocinfo.ll @@ -1,6 +1,6 @@ ; RUN: opt < %s -sample-profile -sample-profile-file=%S/Inputs/nolocinfo.prof -S -pass-remarks=sample-profile 2>&1 | FileCheck %s -define i32 @foo(i32 %i) { +define i32 @foo(i32 %i) !dbg !4 { entry: %i.addr = alloca i32, align 4 %0 = load i32, i32* %i.addr, align 4 @@ -27,7 +27,7 @@ if.end: !1 = !DIFile(filename: "nolocinfo.c", directory: ".") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32)* @foo, variables: !2) +!4 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 1, type: !5, isLocal: false, isDefinition: true, scopeLine: 1, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{!7, !7} !7 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/Transforms/SampleProfile/offset.ll b/test/Transforms/SampleProfile/offset.ll index 151fc0941ed..499b2826402 100644 --- a/test/Transforms/SampleProfile/offset.ll +++ b/test/Transforms/SampleProfile/offset.ll @@ -19,7 +19,7 @@ ; #5 } ; Function Attrs: nounwind uwtable -define i32 @_Z3fooi(i32 %a) #0 { +define i32 @_Z3fooi(i32 %a) #0 !dbg !4 { entry: %retval = alloca i32, align 4 %a.addr = alloca i32, align 4 @@ -58,7 +58,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "a.cc", directory: "/tmp") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooi", scope: !1, file: !1, line: 5, type: !5, isLocal: false, isDefinition: true, scopeLine: 5, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32)* @_Z3fooi, variables: !2) +!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3fooi", scope: !1, file: !1, line: 5, type: !5, isLocal: false, isDefinition: true, scopeLine: 5, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{!7, !7} !7 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) diff --git a/test/Transforms/SampleProfile/propagate.ll b/test/Transforms/SampleProfile/propagate.ll index 3945519f601..eef7b162eb7 100644 --- a/test/Transforms/SampleProfile/propagate.ll +++ b/test/Transforms/SampleProfile/propagate.ll @@ -40,7 +40,7 @@ target triple = "x86_64-unknown-linux-gnu" @.str = private unnamed_addr constant [24 x i8] c"foo(%d, %d, %ld) = %ld\0A\00", align 1 ; Function Attrs: nounwind uwtable -define i64 @_Z3fooiil(i32 %x, i32 %y, i64 %N) #0 { +define i64 @_Z3fooiil(i32 %x, i32 %y, i64 %N) #0 !dbg !4 { entry: %retval = alloca i64, align 8 %x.addr = alloca i32, align 4 @@ -167,7 +167,7 @@ return: ; preds = %if.end19, %if.then } ; Function Attrs: uwtable -define i32 @main() #1 { +define i32 @main() #1 !dbg !7 { entry: %retval = alloca i32, align 4 %x = alloca i32, align 4 @@ -202,10 +202,10 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !1 = !DIFile(filename: "propagate.cc", directory: ".") !2 = !{} !3 = !{!4, !7} -!4 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, function: i64 (i32, i32, i64)* @_Z3fooiil, variables: !2) +!4 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 3, file: !1, scope: !5, type: !6, variables: !2) !5 = !DIFile(filename: "propagate.cc", directory: ".") !6 = !DISubroutineType(types: !{null}) -!7 = distinct !DISubprogram(name: "main", line: 24, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 24, file: !1, scope: !5, type: !6, function: i32 ()* @main, variables: !2) +!7 = distinct !DISubprogram(name: "main", line: 24, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 24, file: !1, scope: !5, type: !6, variables: !2) !8 = !{i32 2, !"Dwarf Version", i32 4} !9 = !{i32 1, !"Debug Info Version", i32 3} !10 = !{!"clang version 3.5 "} diff --git a/test/Transforms/SampleProfile/remarks.ll b/test/Transforms/SampleProfile/remarks.ll index f6e9a4267f4..a0e6a9deb8a 100644 --- a/test/Transforms/SampleProfile/remarks.ll +++ b/test/Transforms/SampleProfile/remarks.ll @@ -27,7 +27,7 @@ ; CHECK: remark: remarks.cc:9:15: most popular destination for conditional branches at remarks.cc:6:9 ; Function Attrs: nounwind uwtable -define i64 @_Z3foov() #0 { +define i64 @_Z3foov() #0 !dbg !4 { entry: %sum = alloca i64, align 8 %i = alloca i32, align 4 @@ -104,7 +104,7 @@ declare i32 @rand() #3 declare void @llvm.lifetime.end(i64, i8* nocapture) #1 ; Function Attrs: nounwind uwtable -define i32 @main() #0 { +define i32 @main() #0 !dbg !13 { entry: %retval = alloca i32, align 4 store i32 0, i32* %retval, align 4 @@ -128,7 +128,7 @@ attributes #4 = { nounwind } !1 = !DIFile(filename: "remarks.cc", directory: ".") !2 = !{} !3 = !{!4, !13} -!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foov", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: true, function: i64 ()* @_Z3foov, variables: !8) +!4 = distinct !DISubprogram(name: "foo", linkageName: "_Z3foov", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: true, variables: !8) !5 = !DISubroutineType(types: !6) !6 = !{!7} !7 = !DIBasicType(name: "long long int", size: 64, align: 64, encoding: DW_ATE_signed) @@ -137,7 +137,7 @@ attributes #4 = { nounwind } !10 = !DILocalVariable(name: "i", scope: !11, file: !1, line: 5, type: !12) !11 = distinct !DILexicalBlock(scope: !4, file: !1, line: 5, column: 3) !12 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!13 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 13, type: !14, isLocal: false, isDefinition: true, scopeLine: 13, flags: DIFlagPrototyped, isOptimized: true, function: i32 ()* @main, variables: !2) +!13 = distinct !DISubprogram(name: "main", scope: !1, file: !1, line: 13, type: !14, isLocal: false, isDefinition: true, scopeLine: 13, flags: DIFlagPrototyped, isOptimized: true, variables: !2) !14 = !DISubroutineType(types: !15) !15 = !{!12} !16 = !{i32 2, !"Dwarf Version", i32 4} diff --git a/test/Transforms/ScalarRepl/debuginfo-preserved.ll b/test/Transforms/ScalarRepl/debuginfo-preserved.ll index 2929287cfed..4daa610ccdc 100644 --- a/test/Transforms/ScalarRepl/debuginfo-preserved.ll +++ b/test/Transforms/ScalarRepl/debuginfo-preserved.ll @@ -11,7 +11,7 @@ target triple = "x86_64-apple-macosx10.6.0" ; CHECK: llvm.dbg.value ; CHECK: llvm.dbg.value -define i32 @f(i32 %a, i32 %b) nounwind ssp { +define i32 @f(i32 %a, i32 %b) nounwind ssp !dbg !1 { entry: %a.addr = alloca i32, align 4 %b.addr = alloca i32, align 4 @@ -43,7 +43,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) nounwind readnone !llvm.module.flags = !{!20} !0 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 3.0 (trunk 131941)", isOptimized: false, emissionKind: 0, file: !18, enums: !19, retainedTypes: !19, subprograms: !17) -!1 = distinct !DISubprogram(name: "f", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !18, scope: !2, type: !3, function: i32 (i32, i32)* @f) +!1 = distinct !DISubprogram(name: "f", line: 1, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 1, file: !18, scope: !2, type: !3) !2 = !DIFile(filename: "/d/j/debug-test.c", directory: "/Volumes/Data/b") !3 = !DISubroutineType(types: !4) !4 = !{!5} diff --git a/test/Transforms/Scalarizer/dbginfo.ll b/test/Transforms/Scalarizer/dbginfo.ll index 539cf1fead8..09252a09d4b 100644 --- a/test/Transforms/Scalarizer/dbginfo.ll +++ b/test/Transforms/Scalarizer/dbginfo.ll @@ -2,7 +2,7 @@ target datalayout = "e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64-S128" ; Function Attrs: nounwind uwtable -define void @f1(<4 x i32>* nocapture %a, <4 x i32>* nocapture readonly %b, <4 x i32>* nocapture readonly %c) #0 { +define void @f1(<4 x i32>* nocapture %a, <4 x i32>* nocapture readonly %b, <4 x i32>* nocapture readonly %c) #0 !dbg !4 { ; CHECK: @f1( ; CHECK: %a.i0 = bitcast <4 x i32>* %a to i32* ; CHECK: %a.i1 = getelementptr i32, i32* %a.i0, i32 1 @@ -61,7 +61,7 @@ attributes #1 = { nounwind readnone } !1 = !DIFile(filename: "/tmp/add.c", directory: "/home/richards/llvm/build") !2 = !{} !3 = !{!4} -!4 = distinct !DISubprogram(name: "f1", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 4, file: !1, scope: !5, type: !6, function: void (<4 x i32>*, <4 x i32>*, <4 x i32>*)* @f1, variables: !14) +!4 = distinct !DISubprogram(name: "f1", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: true, scopeLine: 4, file: !1, scope: !5, type: !6, variables: !14) !5 = !DIFile(filename: "/tmp/add.c", directory: "/home/richards/llvm/build") !6 = !DISubroutineType(types: !7) !7 = !{null, !8, !8, !8} diff --git a/test/Transforms/SimplifyCFG/branch-fold-dbg.ll b/test/Transforms/SimplifyCFG/branch-fold-dbg.ll index ba9596c6a64..34871063bbc 100644 --- a/test/Transforms/SimplifyCFG/branch-fold-dbg.ll +++ b/test/Transforms/SimplifyCFG/branch-fold-dbg.ll @@ -4,7 +4,7 @@ @0 = external hidden constant [5 x %0], align 4 -define void @foo(i32) nounwind ssp { +define void @foo(i32) nounwind ssp !dbg !0 { Entry: %1 = icmp slt i32 %0, 0, !dbg !5 br i1 %1, label %BB5, label %BB1, !dbg !5 @@ -41,7 +41,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.dbg.sp = !{!0} -!0 = distinct !DISubprogram(name: "foo", line: 231, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !15, scope: !1, type: !3, function: void (i32)* @foo) +!0 = distinct !DISubprogram(name: "foo", line: 231, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !15, scope: !1, type: !3) !1 = !DIFile(filename: "a.c", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang (trunk 129006)", isOptimized: true, emissionKind: 0, file: !15, enums: !4, retainedTypes: !4) !3 = !DISubroutineType(types: !4) diff --git a/test/Transforms/SimplifyCFG/hoist-dbgvalue.ll b/test/Transforms/SimplifyCFG/hoist-dbgvalue.ll index 2222e4a7a20..887373a2d3d 100644 --- a/test/Transforms/SimplifyCFG/hoist-dbgvalue.ll +++ b/test/Transforms/SimplifyCFG/hoist-dbgvalue.ll @@ -1,6 +1,6 @@ ; RUN: opt -simplifycfg -S < %s | FileCheck %s -define i32 @foo(i32 %i) nounwind ssp { +define i32 @foo(i32 %i) nounwind ssp !dbg !0 { call void @llvm.dbg.value(metadata i32 %i, i64 0, metadata !6, metadata !DIExpression()), !dbg !7 call void @llvm.dbg.value(metadata i32 0, i64 0, metadata !9, metadata !DIExpression()), !dbg !11 %1 = icmp ne i32 %i, 0, !dbg !12 @@ -32,7 +32,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.module.flags = !{!21} !llvm.dbg.sp = !{!0} -!0 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !20, scope: !1, type: !3, function: i32 (i32)* @foo) +!0 = distinct !DISubprogram(name: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, file: !20, scope: !1, type: !3) !1 = !DIFile(filename: "b.c", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang", isOptimized: true, emissionKind: 0, file: !20, enums: !8, retainedTypes: !8) !3 = !DISubroutineType(types: !4) diff --git a/test/Transforms/SimplifyCFG/trap-debugloc.ll b/test/Transforms/SimplifyCFG/trap-debugloc.ll index 4a0537bc847..2887aaf52ee 100644 --- a/test/Transforms/SimplifyCFG/trap-debugloc.ll +++ b/test/Transforms/SimplifyCFG/trap-debugloc.ll @@ -1,7 +1,7 @@ ; RUN: opt -S -simplifycfg < %s | FileCheck %s ; Radar 9342286 ; Assign DebugLoc to trap instruction. -define void @foo() nounwind ssp { +define void @foo() nounwind ssp !dbg !0 { ; CHECK: call void @llvm.trap(), !dbg store i32 42, i32* null, !dbg !5 ret void, !dbg !7 @@ -11,7 +11,7 @@ define void @foo() nounwind ssp { !llvm.module.flags = !{!10} !llvm.dbg.sp = !{!0} -!0 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !8, scope: !1, type: !3, function: void ()* @foo) +!0 = distinct !DISubprogram(name: "foo", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !8, scope: !1, type: !3) !1 = !DIFile(filename: "foo.c", directory: "/private/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "Apple clang version 3.0 (tags/Apple/clang-206.1) (based on LLVM 3.0svn)", isOptimized: true, emissionKind: 0, file: !8, enums: !{}, retainedTypes: !{}, subprograms: !9) !3 = !DISubroutineType(types: !4) diff --git a/test/Transforms/StripSymbols/2010-06-30-StripDebug.ll b/test/Transforms/StripSymbols/2010-06-30-StripDebug.ll index 0a66df72c43..32d7e77b20d 100644 --- a/test/Transforms/StripSymbols/2010-06-30-StripDebug.ll +++ b/test/Transforms/StripSymbols/2010-06-30-StripDebug.ll @@ -4,7 +4,7 @@ @x = common global i32 0 ; <i32*> [#uses=0] -define void @foo() nounwind readnone optsize ssp { +define void @foo() nounwind readnone optsize ssp !dbg !0 { entry: tail call void @llvm.dbg.value(metadata i32 0, i64 0, metadata !5, metadata !{}), !dbg !10 ret void, !dbg !11 @@ -18,7 +18,7 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) nounwind readnon !llvm.dbg.lv.foo = !{!5} !llvm.dbg.gv = !{!8} -!0 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !12, scope: !1, type: !3, function: void ()* @foo) +!0 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 2, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !12, scope: !1, type: !3) !1 = !DIFile(filename: "b.c", directory: "/tmp") !2 = distinct !DICompileUnit(language: DW_LANG_C89, producer: "4.2.1 (Based on Apple Inc. build 5658) (LLVM build)", isOptimized: true, emissionKind: 0, file: !12) !3 = !DISubroutineType(types: !4) diff --git a/test/Transforms/StripSymbols/2010-08-25-crash.ll b/test/Transforms/StripSymbols/2010-08-25-crash.ll index 9779a103fe2..ba8979c9772 100644 --- a/test/Transforms/StripSymbols/2010-08-25-crash.ll +++ b/test/Transforms/StripSymbols/2010-08-25-crash.ll @@ -1,5 +1,5 @@ ; RUN: opt -strip-dead-debug-info -disable-output < %s -define i32 @foo() nounwind ssp { +define i32 @foo() nounwind ssp !dbg !0 { entry: ret i32 0, !dbg !8 } @@ -7,7 +7,7 @@ entry: !llvm.dbg.cu = !{!2} !llvm.module.flags = !{!14} -!0 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !10, scope: !1, type: !3, function: i32 ()* @foo) +!0 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 3, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: false, file: !10, scope: !1, type: !3) !1 = !DIFile(filename: "/tmp/a.c", directory: "/Volumes/Lalgate/clean/D.CW") !2 = distinct !DICompileUnit(language: DW_LANG_C99, producer: "clang version 2.8 (trunk 112062)", isOptimized: true, emissionKind: 1, file: !10, enums: !11, retainedTypes: !11, subprograms: !12, globals: !13) !3 = !DISubroutineType(types: !4) diff --git a/test/Transforms/StripSymbols/strip-dead-debug-info.ll b/test/Transforms/StripSymbols/strip-dead-debug-info.ll index 2160fcf4672..39038c95561 100644 --- a/test/Transforms/StripSymbols/strip-dead-debug-info.ll +++ b/test/Transforms/StripSymbols/strip-dead-debug-info.ll @@ -10,13 +10,13 @@ declare void @llvm.dbg.value(metadata, i64, metadata, metadata) #0 ; Function Attrs: nounwind readnone ssp -define i32 @fn() #1 { +define i32 @fn() #1 !dbg !6 { entry: ret i32 0, !dbg !18 } ; Function Attrs: nounwind readonly ssp -define i32 @foo(i32 %i) #2 { +define i32 @foo(i32 %i) #2 !dbg !10 { entry: tail call void @llvm.dbg.value(metadata i32 %i, i64 0, metadata !15, metadata !DIExpression()), !dbg !20 %.0 = load i32, i32* @xyz, align 4 @@ -36,11 +36,11 @@ attributes #2 = { nounwind readonly ssp } !3 = distinct !DISubprogram(name: "bar", line: 5, isLocal: true, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !1, scope: null, type: !4) !4 = !DISubroutineType(types: !2) !5 = !DIFile(filename: "g.c", directory: "/tmp/") -!6 = distinct !DISubprogram(name: "fn", linkageName: "fn", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !1, scope: null, type: !7, function: i32 ()* @fn) +!6 = distinct !DISubprogram(name: "fn", linkageName: "fn", line: 6, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !1, scope: null, type: !7) !7 = !DISubroutineType(types: !8) !8 = !{!9} !9 = !DIBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!10 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !1, scope: null, type: !11, function: i32 (i32)* @foo) +!10 = distinct !DISubprogram(name: "foo", linkageName: "foo", line: 7, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, file: !1, scope: null, type: !11) !11 = !DISubroutineType(types: !12) !12 = !{!9, !9} !13 = !DILocalVariable(name: "bb", line: 5, scope: !14, file: !5, type: !9) diff --git a/test/Verifier/metadata-function-dbg.ll b/test/Verifier/metadata-function-dbg.ll index 43c632babda..2a6fd8bbb48 100644 --- a/test/Verifier/metadata-function-dbg.ll +++ b/test/Verifier/metadata-function-dbg.ll @@ -1,6 +1,6 @@ ; RUN: not llvm-as %s -disable-output 2>&1 | FileCheck %s -define void @foo() !dbg !4 { +define void @foo() !dbg !4 !dbg !4 { unreachable } @@ -19,5 +19,5 @@ define void @bar() !dbg !6 { !1 = distinct !DICompileUnit(language: DW_LANG_C99, file: !2, subprograms: !3) !2 = !DIFile(filename: "t.c", directory: "/path/to/dir") !3 = !{!4} -!4 = distinct !DISubprogram(name: "foo", scope: !1, file: !2, function: void ()* @foo) +!4 = distinct !DISubprogram(name: "foo", scope: !1, file: !2) !6 = !{} diff --git a/test/tools/dsymutil/Inputs/frame-dw2.ll b/test/tools/dsymutil/Inputs/frame-dw2.ll index e750d072b95..d07c529d310 100644 --- a/test/tools/dsymutil/Inputs/frame-dw2.ll +++ b/test/tools/dsymutil/Inputs/frame-dw2.ll @@ -4,7 +4,7 @@ target datalayout = "e-m:o-p:32:32-f64:32:64-f80:128-n8:16:32-S128" target triple = "i386-apple-macosx10.11.0" ; Function Attrs: nounwind ssp -define i32 @bar(i32 %b) #0 { +define i32 @bar(i32 %b) #0 !dbg !4 { entry: %b.addr = alloca i32, align 4 %var = alloca i32, align 4 @@ -24,7 +24,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 declare i32 @foo(i32*) #2 ; Function Attrs: nounwind ssp -define i32 @baz(i32 %b) #0 { +define i32 @baz(i32 %b) #0 !dbg !8 { entry: %b.addr = alloca i32, align 4 store i32 %b, i32* %b.addr, align 4 @@ -46,11 +46,11 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !1 = !DIFile(filename: "frame.c", directory: "/tmp") !2 = !{} !3 = !{!4, !8} -!4 = distinct !DISubprogram(name: "bar", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32)* @bar, variables: !2) +!4 = distinct !DISubprogram(name: "bar", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{!7, !7} !7 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!8 = distinct !DISubprogram(name: "baz", scope: !1, file: !1, line: 8, type: !5, isLocal: false, isDefinition: true, scopeLine: 8, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32)* @baz, variables: !2) +!8 = distinct !DISubprogram(name: "baz", scope: !1, file: !1, line: 8, type: !5, isLocal: false, isDefinition: true, scopeLine: 8, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !9 = !{i32 2, !"Dwarf Version", i32 2} !10 = !{i32 2, !"Debug Info Version", i32 3} !11 = !{i32 1, !"PIC Level", i32 2} diff --git a/test/tools/dsymutil/Inputs/frame-dw4.ll b/test/tools/dsymutil/Inputs/frame-dw4.ll index f9ca275ffb8..f3df896a3bb 100644 --- a/test/tools/dsymutil/Inputs/frame-dw4.ll +++ b/test/tools/dsymutil/Inputs/frame-dw4.ll @@ -4,7 +4,7 @@ target datalayout = "e-m:o-p:32:32-f64:32:64-f80:128-n8:16:32-S128" target triple = "i386-apple-macosx10.11.0" ; Function Attrs: nounwind ssp -define i32 @bar(i32 %b) #0 { +define i32 @bar(i32 %b) #0 !dbg !4 { entry: %b.addr = alloca i32, align 4 %var = alloca i32, align 4 @@ -24,7 +24,7 @@ declare void @llvm.dbg.declare(metadata, metadata, metadata) #1 declare i32 @foo(i32*) #2 ; Function Attrs: nounwind ssp -define i32 @baz(i32 %b) #0 { +define i32 @baz(i32 %b) #0 !dbg !8 { entry: %b.addr = alloca i32, align 4 store i32 %b, i32* %b.addr, align 4 @@ -46,11 +46,11 @@ attributes #2 = { "less-precise-fpmad"="false" "no-frame-pointer-elim"="true" "n !1 = !DIFile(filename: "frame.c", directory: "/tmp") !2 = !{} !3 = !{!4, !8} -!4 = distinct !DISubprogram(name: "bar", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32)* @bar, variables: !2) +!4 = distinct !DISubprogram(name: "bar", scope: !1, file: !1, line: 3, type: !5, isLocal: false, isDefinition: true, scopeLine: 3, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !5 = !DISubroutineType(types: !6) !6 = !{!7, !7} !7 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed) -!8 = distinct !DISubprogram(name: "baz", scope: !1, file: !1, line: 8, type: !5, isLocal: false, isDefinition: true, scopeLine: 8, flags: DIFlagPrototyped, isOptimized: false, function: i32 (i32)* @baz, variables: !2) +!8 = distinct !DISubprogram(name: "baz", scope: !1, file: !1, line: 8, type: !5, isLocal: false, isDefinition: true, scopeLine: 8, flags: DIFlagPrototyped, isOptimized: false, variables: !2) !9 = !{i32 2, !"Dwarf Version", i32 4} !10 = !{i32 2, !"Debug Info Version", i32 3} !11 = !{i32 1, !"PIC Level", i32 2} |