OSDN Git Service

[X86] Handle localdynamic TLS model in x32 mode
authorHarald van Dijk <harald@gigawatt.nl>
Tue, 8 Dec 2020 21:06:00 +0000 (21:06 +0000)
committerHarald van Dijk <harald@gigawatt.nl>
Tue, 8 Dec 2020 21:06:00 +0000 (21:06 +0000)
commit29c8ea6f1abd6606b65dafd3db8f15c8104c2593
tree9d089201045bd14ba9e461b8c0dda2b31e1843bd
parent51f3432f4b5217b35dc2694c6e46d6cfc7defad6
[X86] Handle localdynamic TLS model in x32 mode

D92346 added TLS_(base_)addrX32 to handle TLS in x32 mode, but missed the
different TLS models. This diff fixes the logic for the local dynamic model
where `RAX` was used when `EAX` should be, and extends the tests to cover
all four TLS models.

Fixes https://bugs.llvm.org/show_bug.cgi?id=26472.

Reviewed By: RKSimon

Differential Revision: https://reviews.llvm.org/D92737
llvm/lib/Target/X86/X86ISelLowering.cpp
llvm/test/CodeGen/X86/pic.ll