HomePhabricator

[TLS] use emulated TLS if the target supports only this mode

Authored by chh on Feb 28 2018, 9:48 AM.

Description

[TLS] use emulated TLS if the target supports only this mode

Emulated TLS is enabled by llc flag -emulated-tls,
which is passed by clang driver.
When llc is called explicitly or from other drivers like LTO,
missing -emulated-tls flag would generate wrong TLS code for targets
that supports only this mode.
Now use useEmulatedTLS() instead of Options.EmulatedTLS to decide whether
emulated TLS code should be generated.
Unit tests are modified to run with and without the -emulated-tls flag.

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

llvm-svn: 326341

Details

Committed
chhFeb 28 2018, 9:48 AM
Differential Revision
D42999: [TLS] use emulated TLS if the target supports only this mode
Parents
rG29abfe4a8fe0: [WebAssembly] Use toArrayRef. NFC.
Branches
Unknown
Tags
Unknown