summaryrefslogtreecommitdiff
path: root/libmudflap/mf-hooks3.c
diff options
context:
space:
mode:
authorjiez <jiez@138bc75d-0d04-0410-961f-82ee72b054a4>2009-01-23 04:58:03 +0000
committerjiez <jiez@138bc75d-0d04-0410-961f-82ee72b054a4>2009-01-23 04:58:03 +0000
commit5a88eb87265ab500347a22f3969195246d5f5358 (patch)
tree6ddfe08d3b1988039a3b83beaf42660efeaa2cc4 /libmudflap/mf-hooks3.c
parenta0fa583951228f287a6b2b986a0ddfb434ae0f2f (diff)
downloadgcc-5a88eb87265ab500347a22f3969195246d5f5358.tar.gz
libmudflap/
* mf-impl.h (__mf_get_state, __mf_set_state): Don't use __thread when TLS support is emulated. * mf-hooks3.c (__mf_get_state, __mf_set_state): Likewise. * mf-runtime.c (__mf_state_1): Likewise. * configure.ac: Use GCC_CHECK_EMUTLS. * configure: Regenerate. * config.h.in: Regenerate. config/ * tls.m4 (GCC_CHECK_EMUTLS): Define. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@143583 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libmudflap/mf-hooks3.c')
-rw-r--r--libmudflap/mf-hooks3.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libmudflap/mf-hooks3.c b/libmudflap/mf-hooks3.c
index dec4cd63b83..5792a14f5db 100644
--- a/libmudflap/mf-hooks3.c
+++ b/libmudflap/mf-hooks3.c
@@ -78,7 +78,7 @@ DECLARE(int, pthread_create, pthread_t *thr, const pthread_attr_t *attr,
/* Multithreading support hooks. */
-#ifndef HAVE_TLS
+#if !defined(HAVE_TLS) || defined(USE_EMUTLS)
/* We don't have TLS. Ordinarily we could use pthread keys, but since we're
commandeering malloc/free that presents a few problems. The first is that
we'll recurse from __mf_get_state to pthread_setspecific to malloc back to
@@ -217,7 +217,7 @@ __mf_pthread_cleanup (void *arg)
if (__mf_opts.heur_std_data)
__mf_unregister (&errno, sizeof (errno), __MF_TYPE_GUESS);
-#ifndef HAVE_TLS
+#if !defined(HAVE_TLS) || defined(USE_EMUTLS)
struct mf_thread_data *data = __mf_find_threadinfo (0);
if (data)
data->used_p = 0;