summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/MicrosoftCXXABI.cpp
diff options
context:
space:
mode:
authorRichard Smith <richard-llvm@metafoo.co.uk>2013-04-14 23:01:42 +0000
committerRichard Smith <richard-llvm@metafoo.co.uk>2013-04-14 23:01:42 +0000
commitdbf74baee576ba200009bcead0117cc641d39071 (patch)
tree98577d678a6974765c016c31024abc4ee444b2d8 /clang/lib/CodeGen/MicrosoftCXXABI.cpp
parente45f58d8a90c2e9fbf4cf46dcf29f27e0deb3077 (diff)
downloadbcm5719-llvm-dbf74baee576ba200009bcead0117cc641d39071.tar.gz
bcm5719-llvm-dbf74baee576ba200009bcead0117cc641d39071.zip
CodeGen support for function-local static thread_local variables with
non-constant constructors or non-trivial destructors. Plus bugfixes for thread_local references bound to temporaries (the temporaries themselves are lifetime-extended to become thread_local), and the corresponding case for std::initializer_list. llvm-svn: 179496
Diffstat (limited to 'clang/lib/CodeGen/MicrosoftCXXABI.cpp')
-rw-r--r--clang/lib/CodeGen/MicrosoftCXXABI.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/clang/lib/CodeGen/MicrosoftCXXABI.cpp b/clang/lib/CodeGen/MicrosoftCXXABI.cpp
index 2c7f89aa508..a0e4f4d3847 100644
--- a/clang/lib/CodeGen/MicrosoftCXXABI.cpp
+++ b/clang/lib/CodeGen/MicrosoftCXXABI.cpp
@@ -392,6 +392,9 @@ void MicrosoftCXXABI::EmitGuardedInit(CodeGenFunction &CGF, const VarDecl &D,
// Not sure whether we want thread-safe static local variables as VS
// doesn't make them thread-safe.
+ if (D.getTLSKind())
+ CGM.ErrorUnsupported(&D, "dynamic TLS initialization");
+
// Emit the initializer and add a global destructor if appropriate.
CGF.EmitCXXGlobalVarDeclInit(D, DeclPtr, PerformInit);
}
OpenPOWER on IntegriCloud