38 lines · plain
1## Test that llvm-objdump can handle SHN_XINDEX. The relocation points to a section2## symbol that has st_shndx == SHN_XINDEX. To print the section name llvm-objdump3## has to use the SHT_SYMTAB_SHNDX section.4 5# RUN: yaml2obj %s -o %t6# RUN: llvm-objdump -r %t | FileCheck %s7 8# CHECK: RELOCATION RECORDS FOR [.text]:9# CHECK-NEXT: OFFSET TYPE VALUE10# CHECK-NEXT: 0000000000000000 R_X86_64_32 bar11 12--- !ELF13FileHeader:14 Class: ELFCLASS6415 Data: ELFDATA2LSB16 Type: ET_REL17 Machine: EM_X86_6418Sections:19 - Name: .text20 Type: SHT_PROGBITS21 - Name: .rela.text22 Type: SHT_RELA23 Info: .text24 Relocations:25 - Offset: 0x000000000000000026 Symbol: bar27 Type: R_X86_64_3228 - Name: bar29 Type: SHT_PROGBITS30 - Name: .symtab_shndx31 Type: SHT_SYMTAB_SHNDX32 Link: .symtab33 Entries: [ 0, 3 ]34Symbols:35 - Name: bar36 Type: STT_SECTION37 Index: SHN_XINDEX38