[PPC64] Support relaxing R_PPC64_TLSGD16 in TlsGdtoLe relaxation.
authorSean Fertile <sfertile@ca.ibm.com>
Mon, 17 Sep 2018 20:27:02 +0000 (20:27 +0000)
committerSean Fertile <sfertile@ca.ibm.com>
Mon, 17 Sep 2018 20:27:02 +0000 (20:27 +0000)
commit72435e57019fd2a597b9bab472bc632630ff54d5
treed3d488af3ad58206eebccc69906e58b462eaef94
parenteed3e43e54eefb7bcd79d2f630ebb667c30d7688
[PPC64] Support relaxing R_PPC64_TLSGD16 in TlsGdtoLe relaxation.

A General-dynamic tls access can be written using a R_PPC64_TLSGD16 relocation
if the target got entry is within 16 bits of the TOC-base. This patch adds
support for R_PPC64_TLSGD16 by relaxing it the same as a R_PPC64_GOT_TLSGD16_LO.

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

llvm-svn: 342411
lld/ELF/Arch/PPC64.cpp
lld/test/ELF/ppc64-tls-gd-le-small.s [new file with mode: 0644]