diff options
author | ro <ro@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-11-08 14:58:57 +0000 |
---|---|---|
committer | ro <ro@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-11-08 14:58:57 +0000 |
commit | 0e5877a5377f57f1c6f0536ee65d4fb0c03bbdc1 (patch) | |
tree | 38aea815839b6631ca1ae2c86e06be82652369da /libitm/config | |
parent | 69e5eea59afd65e47f55de7b6c20b4f063142573 (diff) | |
download | gcc-0e5877a5377f57f1c6f0536ee65d4fb0c03bbdc1.tar.gz |
Fix Solaris/x86 libitm build
* configure.tgt: Handle i386 like i[456]86.
* config/generic/tls.h [!HAVE_ARCH_GTM_THREAD] (gtm_thr): Don't
take address.
* config/generic/tls.cc [!HAVE_ARCH_GTM_THREAD ||
!HAVE_ARCH_GTM_THREAD_DISP] (_gtm_thr_tls): New variable.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@181163 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libitm/config')
-rw-r--r-- | libitm/config/generic/tls.cc | 4 | ||||
-rw-r--r-- | libitm/config/generic/tls.h | 2 |
2 files changed, 5 insertions, 1 deletions
diff --git a/libitm/config/generic/tls.cc b/libitm/config/generic/tls.cc index 3e82cff0902..c6421113c86 100644 --- a/libitm/config/generic/tls.cc +++ b/libitm/config/generic/tls.cc @@ -26,6 +26,10 @@ namespace GTM HIDDEN { +#if !defined(HAVE_ARCH_GTM_THREAD) || !defined(HAVE_ARCH_GTM_THREAD_DISP) +__thread gtm_thread_tls _gtm_thr_tls; +#endif + // Filter out any updates that overlap the libitm stack, as defined by // TOP (entry point to library) and BOT (below current function). This // definition should be fine for all stack-grows-down architectures. diff --git a/libitm/config/generic/tls.h b/libitm/config/generic/tls.h index e282e54817b..6bbdccf2be1 100644 --- a/libitm/config/generic/tls.h +++ b/libitm/config/generic/tls.h @@ -49,7 +49,7 @@ extern __thread gtm_thread_tls _gtm_thr_tls; #ifndef HAVE_ARCH_GTM_THREAD // If the target does not provide optimized access to the thread-local // data, simply access the TLS variable defined above. -static inline gtm_thread *gtm_thr() { return &_gtm_thr_tls.thr; } +static inline gtm_thread *gtm_thr() { return _gtm_thr_tls.thr; } static inline void set_gtm_thr(gtm_thread *x) { _gtm_thr_tls.thr = x; } #endif |