1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-20 03:23:01 +02:00
llvm-mirror/test/tools/llvm-objcopy/dynamic-relocations.test
Jake Ehrlich f096324571 [llvm-objcopy] Add support for dynamic relocations
This change adds support for dynamic relocations (allocated
SHT_REL/SHT_RELA sections with a dynamic symbol table as their link).

The binary I added for the test is here:
https://drive.google.com/file/d/0B3gtIAmiMwZXSjJUZE9pUjd4M0k/view?usp=sharing

Unless support for dynamic symbol tables in yaml2obj is added this is
needed.

Differential Revision: https://reviews.llvm.org/D37915

llvm-svn: 314227
2017-09-26 18:02:25 +00:00

20 lines
626 B
Plaintext

# RUN: llvm-objcopy %p/Inputs/dynrel.elf %t
# RUN: llvm-readobj -sections -section-data %t | FileCheck %s
#CHECK: Name: .rela.plt
#CHECK-NEXT: Type: SHT_RELA
#CHECK-NEXT: Flags [
#CHECK-NEXT: SHF_ALLOC
#CHECK-NEXT: ]
#CHECK-NEXT: Address:
#CHECK-NEXT: Offset:
#CHECK-NEXT: Size: 24
#CHECK-NEXT: Link:
#CHECK-NEXT: Info:
#CHECK-NEXT: AddressAlignment: 8
#CHECK-NEXT: EntrySize: 24
#CHECK-NEXT: SectionData (
#CHECK-NEXT: 0000: 18202000 00000000 07000000 01000000 |. .............|
#CHECK-NEXT: 0010: 00000000 00000000 |........|
#CHECK-NEXT: )