brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.3 KiB · c26cba6 Raw
31 lines · plain
1; RUN: llc %s -o /dev/null2; Here variable bar is optimized away. Do not trip over while trying to generate debug info.3 4source_filename = "test/DebugInfo/Generic/2009-11-05-DeadGlobalVariable.ll"5 6; Function Attrs: nounwind readnone ssp uwtable7define i32 @foo() #0 !dbg !6 {8entry:9  ret i32 42, !dbg !1110}11 12attributes #0 = { nounwind readnone ssp uwtable }13 14!llvm.dbg.cu = !{!0}15!llvm.module.flags = !{!10}16 17!0 = distinct !DICompileUnit(language: DW_LANG_C99, file: !1, producer: "clang version 3.0 (trunk 139632)", isOptimized: true, runtimeVersion: 0, emissionKind: FullDebug, enums: !2, retainedTypes: !2, globals: !3)18!1 = !DIFile(filename: "fb.c", directory: "/private/tmp")19!2 = !{}20!3 = !{!4}21!4 = !DIGlobalVariableExpression(var: !5, expr: !DIExpression())22!5 = !DIGlobalVariable(name: "bar", scope: !6, file: !1, line: 2, type: !9, isLocal: true, isDefinition: true)23!6 = distinct !DISubprogram(name: "foo", scope: !1, file: !1, line: 1, type: !7, isLocal: false, isDefinition: true, virtualIndex: 6, isOptimized: true, unit: !0)24!7 = !DISubroutineType(types: !8)25!8 = !{!9}26!9 = !DIBasicType(name: "int", size: 32, align: 32, encoding: DW_ATE_signed)27!10 = !{i32 1, !"Debug Info Version", i32 3}28!11 = !DILocation(line: 3, column: 3, scope: !12)29!12 = distinct !DILexicalBlock(scope: !6, file: !1, line: 1, column: 11)30 31