LGTM
================
Comment at: lib/CodeGen/ItaniumCXXABI.cpp:1842-1844
@@ -1832,7 +1841,5 @@
- // All accesses to the thread_local variable go through the thread wrapper.
- // However, this means that we cannot allow the thread wrapper to get inlined
- // into any functions.
- if (VD->getTLSKind() == VarDecl::TLS_Dynamic &&
- CGM.getTarget().getTriple().isMacOSX())
- return llvm::GlobalValue::WeakAnyLinkage;
+ // The thread wrapper can't be inlined if the backing variable cannot always
+ // be referenced. However, the thread wrapper can be replaced by a different
+ // definition in another translation unit.
+ if (isThreadWrapperReplaceable(VD, CGM)) {
----------------
Can you reword this? The reference to inlining doesn't make much sense here. I
think we just want to say "If the thread wrapper is replaceable, give it
appropriate linkage." -- but even this is kinda obvious from the code.
http://reviews.llvm.org/D4109
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits