1*982b31faSIgor Kudrin; This checks that .debug_line can be generated in the DWARF64 format. 2*982b31faSIgor Kudrin 3*982b31faSIgor Kudrin; RUN: llc -mtriple=x86_64 -dwarf-version=3 -dwarf64 -filetype=obj %s -o %t3 4*982b31faSIgor Kudrin; RUN: llvm-dwarfdump -debug-line %t3 | FileCheck %s 5*982b31faSIgor Kudrin 6*982b31faSIgor Kudrin; CHECK: .debug_line contents: 7*982b31faSIgor Kudrin; CHECK-NEXT: debug_line[0x00000000] 8*982b31faSIgor Kudrin; CHECK-NEXT: Line table prologue: 9*982b31faSIgor Kudrin; CHECK-NEXT: total_length: 10*982b31faSIgor Kudrin; CHECK-NEXT: format: DWARF64 11*982b31faSIgor Kudrin 12*982b31faSIgor Kudrin; IR generated and reduced from: 13*982b31faSIgor Kudrin; $ cat foo.c 14*982b31faSIgor Kudrin; int foo; 15*982b31faSIgor Kudrin; $ clang -g -S -emit-llvm foo.c -o foo.ll 16*982b31faSIgor Kudrin 17*982b31faSIgor Kudrintarget triple = "x86_64-unknown-linux-gnu" 18*982b31faSIgor Kudrin 19*982b31faSIgor Kudrin@foo = dso_local global i32 0, align 4, !dbg !0 20*982b31faSIgor Kudrin 21*982b31faSIgor Kudrin!llvm.dbg.cu = !{!2} 22*982b31faSIgor Kudrin!llvm.module.flags = !{!7, !8, !9} 23*982b31faSIgor Kudrin!llvm.ident = !{!10} 24*982b31faSIgor Kudrin 25*982b31faSIgor Kudrin!0 = !DIGlobalVariableExpression(var: !1, expr: !DIExpression()) 26*982b31faSIgor Kudrin!1 = distinct !DIGlobalVariable(name: "foo", scope: !2, file: !3, line: 1, type: !6, isLocal: false, isDefinition: true) 27*982b31faSIgor Kudrin!2 = distinct !DICompileUnit(language: DW_LANG_C99, file: !3, producer: "clang version 12.0.0", isOptimized: false, runtimeVersion: 0, emissionKind: FullDebug, enums: !4, globals: !5, splitDebugInlining: false, nameTableKind: None) 28*982b31faSIgor Kudrin!3 = !DIFile(filename: "foo.c", directory: "/tmp") 29*982b31faSIgor Kudrin!4 = !{} 30*982b31faSIgor Kudrin!5 = !{!0} 31*982b31faSIgor Kudrin!6 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed) 32*982b31faSIgor Kudrin!7 = !{i32 7, !"Dwarf Version", i32 4} 33*982b31faSIgor Kudrin!8 = !{i32 2, !"Debug Info Version", i32 3} 34*982b31faSIgor Kudrin!9 = !{i32 1, !"wchar_size", i32 4} 35*982b31faSIgor Kudrin!10 = !{!"clang version 12.0.0"} 36