1 # RUN: llvm-mc -triple x86_64-pc-linux %s -filetype=obj | \
2 # RUN: llvm-dwarfdump -verify - | FileCheck %s
4 # CHECK: warning: Name Index @ 0x0 does not contain a hash table.
5 .section .debug_str,"MS",@progbits,1
9 .asciz "Hand-written dwarf"
11 .section .debug_abbrev,"",@progbits
13 .byte 1 # Abbreviation Code
14 .byte 17 # DW_TAG_compile_unit
15 .byte 1 # DW_CHILDREN_yes
16 .byte 37 # DW_AT_producer
17 .byte 14 # DW_FORM_strp
18 .byte 19 # DW_AT_language
19 .byte 5 # DW_FORM_data2
22 .byte 2 # Abbreviation Code
23 .byte 46 # DW_TAG_subprogram
24 .byte 0 # DW_CHILDREN_no
26 .byte 14 # DW_FORM_strp
27 .byte 63 # DW_AT_external
28 .byte 25 # DW_FORM_flag_present
33 .section .debug_info,"",@progbits
35 .long .Lcu_end0-.Lcu_start0 # Length of Unit
37 .short 4 # DWARF version number
38 .long .Lsection_abbrev # Offset Into Abbrev. Section
39 .byte 8 # Address Size (in bytes)
40 .byte 1 # Abbrev [1] DW_TAG_compile_unit
41 .long .Lstring_producer # DW_AT_producer
42 .short 12 # DW_AT_language
44 .byte 2 # Abbrev [2] DW_TAG_subprogram
45 .long .Lstring_foo # DW_AT_name
47 .byte 0 # End Of Children Mark
50 .section .debug_names,"",@progbits
51 .long .Lnames_end0-.Lnames_start0 # Header: contribution length
53 .short 5 # Header: version
54 .short 0 # Header: padding
55 .long 1 # Header: compilation unit count
56 .long 0 # Header: local type unit count
57 .long 0 # Header: foreign type unit count
58 .long 0 # Header: bucket count
59 .long 1 # Header: name count
60 .long .Lnames_abbrev_end0-.Lnames_abbrev_start0 # Header: abbreviation table size
61 .long 0 # Header: augmentation length
62 .long .Lcu_begin0 # Compilation unit 0
63 .long .Lstring_foo # String in Bucket 1: foo
64 .long .Lnames0-.Lnames_entries0 # Offset in Bucket 1
65 .Lnames_abbrev_start0:
66 .byte 46 # Abbrev code
67 .byte 46 # DW_TAG_subprogram
68 .byte 3 # DW_IDX_die_offset
69 .byte 19 # DW_FORM_ref4
70 .byte 0 # End of abbrev
71 .byte 0 # End of abbrev
72 .byte 0 # End of abbrev list
76 .byte 46 # Abbrev code
77 .long .Ldie_foo-.Lcu_begin0 # DW_IDX_die_offset
78 .long 0 # End of list: foo