[AIX][TLS] Add support for TLSGD relocations to XCOFF objects
authorVictor Huang <wei.huang@ibm.com>
Thu, 6 May 2021 13:37:09 +0000 (08:37 -0500)
committerVictor Huang <wei.huang@ibm.com>
Thu, 6 May 2021 14:01:47 +0000 (09:01 -0500)
commitbb113b984565b01355a7f6bb4a5fa2eb8284c2e1
tree4a7f49c289b4c1bf09da583b28093ac6eb49e3a0
parent3761b9a2345aff197707d23a68d4a178489f60e4
[AIX][TLS] Add support for TLSGD relocations to XCOFF objects

- Add branch absolute reloction R_RBA, R_TLS relocation for the variable offset
  for the tlsgd model and R_TLSM for the region handle for the tlsgd model
- Properly set the relocation fixed values for R_TLS and R_TLSM
- Emit the TCEntry with the variant kind in the XCOFFStreamer

Reviewed by: sfertile, nemanjai, DiggerLin

Differential Revision: https://reviews.llvm.org/D100214
llvm/lib/MC/XCOFFObjectWriter.cpp
llvm/lib/Target/PowerPC/MCTargetDesc/PPCMCTargetDesc.cpp
llvm/lib/Target/PowerPC/MCTargetDesc/PPCXCOFFObjectWriter.cpp
llvm/test/CodeGen/PowerPC/aix-tls-xcoff-reloc-large.ll [new file with mode: 0644]
llvm/test/CodeGen/PowerPC/aix-tls-xcoff-reloc.ll [new file with mode: 0644]