[clang] [Clang] Access tls_guard via llvm.threadlocal.address (PR #96633)
John McCall via cfe-commits
cfe-commits at lists.llvm.org
Wed Jul 3 10:23:22 PDT 2024
================
@@ -769,9 +777,10 @@ void CodeGenModule::EmitCXXModuleInitFunc(Module *Primary) {
CharUnits GuardAlign = CharUnits::One();
Guard->setAlignment(GuardAlign.getAsAlign());
GuardAddr = ConstantAddress(Guard, Int8Ty, GuardAlign);
+ IsTLS = Guard->isThreadLocal();
----------------
rjmccall wrote:
This is always just `false`. And I believe that's correct, module initialization is global, not thread-local.
https://github.com/llvm/llvm-project/pull/96633
More information about the cfe-commits
mailing list