diff options
author | KISHIMOTO, Makoto <ksmakoto@dd.iij4u.or.jp> | 2012-06-17 04:02:28 +0400 |
---|---|---|
committer | KISHIMOTO, Makoto <ksmakoto@dd.iij4u.or.jp> | 2012-06-17 04:02:28 +0400 |
commit | 0247946cd95c04865bb6fcdd347c2733e470ccd1 (patch) | |
tree | e3cbb7902886f2d251191a5d2b255282ec5fd873 | |
parent | ab3835c3f3cba44e32a54781d0212f5d9d39ee7a (diff) |
To use thread local alloc in FreeBSD
-rw-r--r-- | libgc/configure.in | 1 | ||||
-rw-r--r-- | libgc/pthread_support.c | 1 | ||||
-rw-r--r-- | mono/metadata/threads.c | 2 |
3 files changed, 3 insertions, 1 deletions
diff --git a/libgc/configure.in b/libgc/configure.in index f4b43792912..97d548f03a4 100644 --- a/libgc/configure.in +++ b/libgc/configure.in @@ -122,6 +122,7 @@ case "$THREADS" in else THREADDLLIBS="$PTHREAD_LIBS" fi + AC_DEFINE(THREAD_LOCAL_ALLOC) ;; *-*-solaris*) AC_DEFINE(GC_SOLARIS_THREADS) diff --git a/libgc/pthread_support.c b/libgc/pthread_support.c index d1f3b129ea8..75c9009d0f1 100644 --- a/libgc/pthread_support.c +++ b/libgc/pthread_support.c @@ -69,6 +69,7 @@ # if (defined(GC_DGUX386_THREADS) || defined(GC_OSF1_THREADS) || \ defined(GC_DARWIN_THREADS) || defined(GC_AIX_THREADS)) || \ defined(GC_NETBSD_THREADS) && !defined(USE_PTHREAD_SPECIFIC) || \ + defined(GC_FREEBSD_THREADS) && !defined(USE_PTHREAD_SPECIFIC) || \ defined(GC_OPENBSD_THREADS) # define USE_PTHREAD_SPECIFIC # endif diff --git a/mono/metadata/threads.c b/mono/metadata/threads.c index f01f5a97cbb..0728e6a05ce 100644 --- a/mono/metadata/threads.c +++ b/mono/metadata/threads.c @@ -17,7 +17,7 @@ #include <signal.h> #include <string.h> -#if defined(__OpenBSD__) +#if defined(__OpenBSD__) || defined(__FreeBSD__) #include <pthread.h> #include <pthread_np.h> #endif |