1 ## An object with many files and directories in a single debug_line contribution
2 ## meant to test the handling of directory_count and file_name_count fields.
4 # RUN: llvm-mc -triple x86_64-pc-linux -filetype=obj %s -o %t
5 # RUN: llvm-dwarfdump -debug-line %t | FileCheck %s
7 # CHECK: include_directories[ 0] = "/d000"
8 # CHECK: include_directories[299] = "/d299"
9 # CHECK: file_names[ 0]:
10 # CHECK-NEXT: name: "000.c"
11 # CHECK-NEXT: dir_index: 0
12 # CHECK: file_names[299]:
13 # CHECK-NEXT: name: "299.c"
14 # CHECK-NEXT: dir_index: 299
16 .section .debug_line,"",@progbits
17 .long .Lunit_end0-.Lunit_start0 # Length of Unit
19 .short 5 # DWARF version number
20 .byte 8 # Address Size
21 .byte 0 # Segment Selector Size
22 .long .Lunit_header_end0 - .Lunit_params0 # Length of Prologue (invalid)
24 .byte 1 # Minimum Instruction Length
25 .byte 1 # Maximum Operations per Instruction
26 .byte 1 # Default is_stmt
29 .byte 13 # Opcode Base
30 .byte 0, 1, 1, 1, 1, 0, 0, 0, 1, 0, 0, 1 # Standard Opcode Lengths
32 # Directory table format
33 .byte 1 # One element per directory entry
34 .byte 1 # DW_LNCT_path
35 .byte 0x08 # DW_FORM_string
37 # Directory table entries
38 .uleb128 300 # 300 directories
42 .byte '/', 'd', '0'+\a, '0'+\b, '0'+\c, 0
48 .byte 2 # 2 elements per file entry
49 .byte 1 # DW_LNCT_path
50 .byte 0x08 # DW_FORM_string
51 .byte 2 # DW_LNCT_directory_index
52 .byte 0x05 # DW_FORM_data2
55 .uleb128 300 # 300 files
59 .byte '0'+\a, '0'+\b, '0'+\c, '.', 'c', 0 # File name
60 .word \a*100+\b*10+\c # Dir index
66 .byte 0, 1, 1 # DW_LNE_end_sequence