summaryrefslogtreecommitdiff
path: root/thread_local_alloc.c
diff options
context:
space:
mode:
authorIvan Maidanski <ivmai@mail.ru>2015-11-17 11:39:29 +0300
committerIvan Maidanski <ivmai@mail.ru>2015-11-18 00:46:07 +0300
commit02528757f439dfc5750e28fb3e5794303ccd21f9 (patch)
tree565c2ef0a89a0f4bde59b3e65ce92e35e97026e0 /thread_local_alloc.c
parent30702c2aa0f57ad3cf89226c8fece53bed3de30f (diff)
downloadbdwgc-02528757f439dfc5750e28fb3e5794303ccd21f9.tar.gz
Allow specific TLS attributes for GC_thread_key
* doc/README.macros (GC_ATTR_TLS_FAST): Document. * include/private/thread_local_alloc.h (GC_ATTR_TLS_FAST): New macro (empty by default). * include/private/thread_local_alloc.h (GC_thread_key): Use GC_ATTR_TLS_FAST. * thread_local_alloc.c (GC_thread_key): Likewise.
Diffstat (limited to 'thread_local_alloc.c')
-rw-r--r--thread_local_alloc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/thread_local_alloc.c b/thread_local_alloc.c
index 29a337b2..9db324eb 100644
--- a/thread_local_alloc.c
+++ b/thread_local_alloc.c
@@ -24,9 +24,9 @@
#include <stdlib.h>
#if defined(USE_COMPILER_TLS)
- __thread
+ __thread GC_ATTR_TLS_FAST
#elif defined(USE_WIN32_COMPILER_TLS)
- __declspec(thread)
+ __declspec(thread) GC_ATTR_TLS_FAST
#endif
GC_key_t GC_thread_key;