HomePhabricator

[X86] Add TLS_(base_)addrX32 for X32 mode

Authored by hvdijk on Dec 2 2020, 2:20 PM.

Description

[X86] Add TLS_(base_)addrX32 for X32 mode

LLVM has TLS_(base_)addr32 for 32-bit TLS addresses in 32-bit mode, and
TLS_(base_)addr64 for 64-bit TLS addresses in 64-bit mode. x32 mode wants 32-bit
TLS addresses in 64-bit mode, which were not yet handled. This adds
TLS_(base_)addrX32 as copies of TLS_(base_)addr64, except that they use
tls32(base)addr rather than tls64(base)addr, and then restricts
TLS_(base_)addr64 to 64-bit LP64 mode, TLS_(base_)addrX32 to 64-bit ILP32 mode.

Reviewed By: RKSimon

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

Details

Committed
hvdijkDec 2 2020, 2:20 PM
Reviewer
RKSimon
Differential Revision
D92346: [X86] Add TLS_(base_)addrX32 for X32 mode
Parents
rG18ce61235379: Use PC-relative address for x32 TLS address
Branches
Unknown
Tags
Unknown