summaryrefslogtreecommitdiffstats
path: root/llvm/test/DebugInfo/X86/inline-member-function.ll
diff options
context:
space:
mode:
authorDuncan P. N. Exon Smith <dexonsmith@apple.com>2015-03-28 02:26:45 +0000
committerDuncan P. N. Exon Smith <dexonsmith@apple.com>2015-03-28 02:26:45 +0000
commitce2b983425bb470bd5bf80a17ebc5d6c429c7332 (patch)
tree3c8a1b35447312735505020004bb8c57201f3058 /llvm/test/DebugInfo/X86/inline-member-function.ll
parent50b0956754ea437b8b4df3a53a1950ab9f987a0d (diff)
downloadbcm5719-llvm-ce2b983425bb470bd5bf80a17ebc5d6c429c7332.tar.gz
bcm5719-llvm-ce2b983425bb470bd5bf80a17ebc5d6c429c7332.zip
DebugInfo: Fix testcases with invalid MDSubprogram nodes
Fix testcases that don't pass the verifier after a WIP patch to check `MDSubprogram` operands more effectively. I found the following issues: - When `isDefinition: false`, the `variables:` field might point at `!{i32 786468}`, or at a tuple that pointed at an empty tuple with the comment "previously: invalid DW_TAG_base_type" (I vaguely recall adding those comments during an upgrade script). In these cases, I just dropped the array. - The `variables:` field might point at something like `!{!{!8}}`, where `!8` was an `MDLocation`. I removed the extra layer of indirection. - Invalid `type:` (not an `MDSubroutineType`). llvm-svn: 233466
Diffstat (limited to 'llvm/test/DebugInfo/X86/inline-member-function.ll')
-rw-r--r--llvm/test/DebugInfo/X86/inline-member-function.ll3
1 files changed, 1 insertions, 2 deletions
diff --git a/llvm/test/DebugInfo/X86/inline-member-function.ll b/llvm/test/DebugInfo/X86/inline-member-function.ll
index e5a4ff02355..c1a367e7e0f 100644
--- a/llvm/test/DebugInfo/X86/inline-member-function.ll
+++ b/llvm/test/DebugInfo/X86/inline-member-function.ll
@@ -71,12 +71,11 @@ attributes #1 = { nounwind readnone }
!3 = !{!4}
!4 = !MDCompositeType(tag: DW_TAG_structure_type, name: "foo", line: 1, size: 8, align: 8, file: !1, elements: !5, identifier: "_ZTS3foo")
!5 = !{!6}
-!6 = !MDSubprogram(name: "func", linkageName: "_ZN3foo4funcEi", line: 2, isLocal: false, isDefinition: false, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !"_ZTS3foo", type: !7, variables: !11)
+!6 = !MDSubprogram(name: "func", linkageName: "_ZN3foo4funcEi", line: 2, isLocal: false, isDefinition: false, virtualIndex: 6, flags: DIFlagPrototyped, isOptimized: false, scopeLine: 2, file: !1, scope: !"_ZTS3foo", type: !7)
!7 = !MDSubroutineType(types: !8)
!8 = !{!9, !10, !9}
!9 = !MDBasicType(tag: DW_TAG_base_type, name: "int", size: 32, align: 32, encoding: DW_ATE_signed)
!10 = !MDDerivedType(tag: DW_TAG_pointer_type, size: 64, align: 64, flags: DIFlagArtificial | DIFlagObjectPointer, baseType: !"_ZTS3foo")
-!11 = !{i32 786468}
!12 = !{!13, !17}
!13 = !MDSubprogram(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)
!14 = !MDFile(filename: "inline.cpp", directory: "/tmp/dbginfo")
OpenPOWER on IntegriCloud