[llvm] [llvm-c] Add EmulatedTLS and EnableTLSDESC to LLVMTargetMachineOptions (PR #161155)
Julien Portalier via llvm-commits
llvm-commits at lists.llvm.org
Mon Feb 16 08:47:28 PST 2026
ysbaddaden wrote:
After further code reading and testing, the default configuration for the triple, such as `hasDefaultEmulatedTLS`, was never considered when creating the target options. I must enable EmulatedTLS for the `__emutls_*` symbols to show up when compiling for the `x86_64-opensd` target for example.
The updated patch now uses `std::optional` to know if the values have been explicitly set then ask the target triple, in the same vein as `llvm::codegen::InitTargetOptionsFromCodeGenFlags()`:
https://github.com/llvm/llvm-project/blob/20aff2085c358d3e112b245494161ddb9ffe0410/llvm/lib/CodeGen/CommandFlags.cpp#L617-L620
https://github.com/llvm/llvm-project/pull/161155
More information about the llvm-commits
mailing list