OSDN Git Service

Enable disabling API-based TLS support.
authorNicolas Capens <capn@google.com>
Thu, 1 Sep 2016 20:53:49 +0000 (16:53 -0400)
committerNicolas Capens <nicolascapens@google.com>
Wed, 7 Sep 2016 17:55:47 +0000 (17:55 +0000)
BUG=swiftshader:7

Change-Id: I0ef3b0ab059bd48e0241eea13a5b77a193351108
Reviewed-on: https://chromium-review.googlesource.com/380275
Reviewed-by: Jim Stichnoth <stichnot@chromium.org>
Tested-by: Nicolas Capens <nicolascapens@google.com>
src/IceTLS.h
src/IceTypes.cpp

index 14865a9..947ae52 100644 (file)
 ///
 /// \def ICE_THREAD_LOCAL_HACK
 ///
-#define ICE_THREAD_LOCAL_HACK
-#ifdef ICE_THREAD_LOCAL_HACK
+#ifndef ICE_THREAD_LOCAL_HACK
+#define ICE_THREAD_LOCAL_HACK 1
+#endif
+
+#if ICE_THREAD_LOCAL_HACK
 
 // For a static thread_local field F of a class C, instead of declaring and
 // defining C::F, we create two static fields:
index e64d99a..f8cbaf9 100644 (file)
@@ -16,6 +16,8 @@
 
 #include "IceDefs.h"
 
+#include "llvm/Support/ErrorHandling.h"
+
 #include <climits>
 
 namespace Ice {