brintos

brintos / llvm-project-archived public Read only

0
0
Text · 6.2 KiB · 9bc6639 Raw
141 lines · plain
1## The test checks that v5 compile units in package files read their2## location tables from .debug_loclists.dwo sections.3## See dwp-v2-loc.s for pre-v5 units.4 5# RUN: llvm-mc -triple x86_64-unknown-linux %s -filetype=obj -o - | \6# RUN:   llvm-dwarfdump -debug-info -debug-loclists - | \7# RUN:   FileCheck %s8 9# CHECK:      .debug_info.dwo contents:10# CHECK:      DW_TAG_compile_unit11# CHECK:      DW_TAG_variable12# CHECK-NEXT:   DW_AT_name ("a")13# CHECK-NEXT:   DW_AT_location (0x{{[0-9a-f]+}}:14# CHECK-NEXT:     DW_LLE_startx_length (0x0000000000000001, 0x0000000000000010): DW_OP_reg5 RDI)15# CHECK:      DW_TAG_variable16# CHECK-NEXT:   DW_AT_name ("b")17# CHECK-NEXT:   DW_AT_location (indexed (0x1) loclist = 0x{{[0-9a-f]+}}:18# CHECK-NEXT:     DW_LLE_startx_length (0x0000000000000005, 0x0000000000000020): DW_OP_regx RDI)19 20# CHECK:      .debug_loclists.dwo contents:21# CHECK:      locations list header:22# CHECK:      locations list header:23# CHECK:      offsets:24# CHECK:      0x{{[0-9a-f]+}}:25# CHECK-NEXT:   DW_LLE_startx_length (0x0000000000000001, 0x0000000000000010): DW_OP_reg5 RDI26# CHECK:      0x{{[0-9a-f]+}}:27# CHECK-NEXT:   DW_LLE_startx_length (0x0000000000000005, 0x0000000000000020): DW_OP_regx RDI28 29.section .debug_abbrev.dwo, "e", @progbits30.LAbbrevBegin:31    .uleb128 1                          # Abbreviation Code32    .uleb128 17                         # DW_TAG_compile_unit33    .byte 1                             # DW_CHILDREN_yes34    .byte 0                             # EOM(1)35    .byte 0                             # EOM(2)36    .uleb128 2                          # Abbreviation Code37    .uleb128 52                         # DW_TAG_variable38    .byte 0                             # DW_CHILDREN_no39    .uleb128 3                          # DW_AT_name40    .uleb128 8                          # DW_FORM_string41    .uleb128 2                          # DW_AT_location42    .uleb128 23                         # DW_FORM_sec_offset43    .byte 0                             # EOM(1)44    .byte 0                             # EOM(2)45    .uleb128 3                          # Abbreviation Code46    .uleb128 52                         # DW_TAG_variable47    .byte 0                             # DW_CHILDREN_no48    .uleb128 3                          # DW_AT_name49    .uleb128 8                          # DW_FORM_string50    .uleb128 2                          # DW_AT_location51    .uleb128 34                         # DW_FORM_loclistx52    .byte 0                             # EOM(1)53    .byte 0                             # EOM(2)54    .byte 0                             # EOM(3)55.LAbbrevEnd:56 57    .section .debug_info.dwo, "e", @progbits58.LCUBegin:59    .long .LCUEnd-.LCUVersion           # Length of Unit60.LCUVersion:61    .short 5                            # Version62    .byte 5                             # DW_UT_split_compile63    .byte 8                             # Address size64    .long 0                             # Abbrev offset65    .quad 0x1100001122222222            # DWO id66    .uleb128 1                          # Abbrev [1] DW_TAG_compile_unit67    .uleb128 2                          # Abbrev [2] DW_TAG_variable68    .asciz "a"                          # DW_AT_name69    .long .LLL0-.LLLBegin               # DW_AT_location (DW_FORM_sec_offset)70    .uleb128 3                          # Abbrev [3] DW_TAG_variable71    .asciz "b"                          # DW_AT_name72    .uleb128 1                          # DW_AT_location (DW_FORM_loclistx)73    .byte 0                             # End Of Children Mark74.LCUEnd:75 76.section .debug_loclists.dwo, "e", @progbits77## Start the section with an unused table to check that the reading offset78## of the real table is correctly adjusted.79    .long .LLLDummyEnd-.LLLDummyVersion # Length of Unit80.LLLDummyVersion:81    .short 5                            # Version82    .byte 8                             # Address size83    .byte 0                             # Segment selector size84    .long 0                             # Offset entry count85    .byte 0                             # DW_LLE_end_of_list86.LLLDummyEnd:87 88.LLLBegin:89    .long .LLLEnd-.LLLVersion           # Length of Unit90.LLLVersion:91    .short 5                            # Version92    .byte 8                             # Address size93    .byte 0                             # Segment selector size94    .long 2                             # Offset entry count95.LLLBase:96    .long .LLL0-.LLLBase97    .long .LLL1-.LLLBase98.LLL0:99    .byte 3                             # DW_LLE_startx_length100    .uleb128 1                          # Index101    .uleb128 0x10                       # Length102    .uleb128 1                          # Loc expr size103    .byte 85                            # DW_OP_reg5104    .byte 0                             # DW_LLE_end_of_list105.LLL1:106    .byte 3                             # DW_LLE_startx_length107    .uleb128 5                          # Index108    .uleb128 0x20                       # Length109    .uleb128 2                          # Loc expr size110    .byte 144                           # DW_OP_regx111    .uleb128 5                          # RDI112    .byte 0                             # DW_LLE_end_of_list113.LLLEnd:114 115    .section .debug_cu_index, "", @progbits116## Header:117    .short 5                            # Version118    .space 2                            # Padding119    .long 3                             # Section count120    .long 1                             # Unit count121    .long 2                             # Slot count122## Hash Table of Signatures:123    .quad 0x1100001122222222124    .quad 0125## Parallel Table of Indexes:126    .long 1127    .long 0128## Table of Section Offsets:129## Row 0:130    .long 1                             # DW_SECT_INFO131    .long 3                             # DW_SECT_ABBREV132    .long 5                             # DW_SECT_LOCLISTS133## Row 1:134    .long 0                             # Offset in .debug_info.dwo135    .long 0                             # Offset in .debug_abbrev.dwo136    .long .LLLBegin-.debug_loclists.dwo # Offset in .debug_loclists.dwo137## Table of Section Sizes:138    .long .LCUEnd-.LCUBegin             # Size in .debug_info.dwo139    .long .LAbbrevEnd-.LAbbrevBegin     # Size in .debug_abbrev.dwo140    .long .LLLEnd-.LLLBegin             # Size in .debug_loclists.dwo141