From 82a47cc06d25af774b15aa1d0037afde8ca3d7cb Mon Sep 17 00:00:00 2001 From: Jonathon Penix Date: Fri, 26 Jan 2024 15:16:34 -0800 Subject: [PATCH] kconfig: llvm: riscv: Advertise TLS support when using llvm for RISC-V clang and lld support TLS for RISC-V, so advertise this support in Kconfig. I believe other non-RISC-V targets also have TLS support in LLVM, but I'm not sure on the exact subset. As TLS support in LLVM wasn't automatically advertised previously, gate this on RISC-V for now as it a) shouldn't break other targets and b) prevents us from improperly claiming support for unsupported targets. Signed-off-by: Jonathon Penix --- cmake/toolchain/llvm/Kconfig | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/cmake/toolchain/llvm/Kconfig b/cmake/toolchain/llvm/Kconfig index b16d0273939..0e2e3e85863 100644 --- a/cmake/toolchain/llvm/Kconfig +++ b/cmake/toolchain/llvm/Kconfig @@ -17,3 +17,8 @@ config LLVM_USE_LLD Use LLVM built-in lld linker with llvm/clang. endchoice + +config TOOLCHAIN_LLVM_SUPPORTS_THREAD_LOCAL_STORAGE + depends on RISCV + def_bool y + select TOOLCHAIN_SUPPORTS_THREAD_LOCAL_STORAGE