[m-rev.] diff: make boehm gc work with pthreads-win32

Julien Fischer juliensf at csse.unimelb.edu.au
Sat Dec 4 03:15:16 AEDT 2010


Branches: main, 10.04

Apply a patch to the Boehm collector from Sergey Khorev that enables
it to work with the pthreads-win32 library.

boehm_gc/include/gc_pthread_redirects.h:
boehm_gc/include/private/gc_priv.h:
 	Avoid some things that don't exist on Windows.

Julien.

Index: boehm_gc/include/gc_pthread_redirects.h
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/boehm_gc/include/gc_pthread_redirects.h,v
retrieving revision 1.5
diff -u -r1.5 gc_pthread_redirects.h
--- boehm_gc/include/gc_pthread_redirects.h	24 Feb 2010 07:04:37 -0000	1.5
+++ boehm_gc/include/gc_pthread_redirects.h	3 Dec 2010 16:00:40 -0000
@@ -31,7 +31,7 @@

  #include <pthread.h>

-#ifndef GC_DARWIN_THREADS
+#if !defined(GC_DARWIN_THREADS) && !defined(GC_WIN32_PTHREADS)
  # include <signal.h>
  # include <dlfcn.h>

Index: boehm_gc/include/private/gc_priv.h
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/boehm_gc/include/private/gc_priv.h,v
retrieving revision 1.9
diff -u -r1.9 gc_priv.h
--- boehm_gc/include/private/gc_priv.h	1 Mar 2010 02:27:30 -0000	1.9
+++ boehm_gc/include/private/gc_priv.h	3 Dec 2010 16:00:41 -0000
@@ -2113,7 +2113,8 @@
         /* Linuxthreads itself uses SIGUSR1 and SIGUSR2.                 */
  #      define SIG_SUSPEND SIGPWR
  #    endif
-#   elif !defined(GC_OPENBSD_THREADS) && !defined(GC_DARWIN_THREADS)
+#   elif !defined(GC_OPENBSD_THREADS) && !defined(GC_DARWIN_THREADS) \
+                                      && !defined(GC_WIN32_PTHREADS)
  #     if defined(_SIGRTMIN)
  #       define SIG_SUSPEND _SIGRTMIN + 6
  #     else



--------------------------------------------------------------------------
mercury-reviews mailing list
Post messages to:       mercury-reviews at csse.unimelb.edu.au
Administrative Queries: owner-mercury-reviews at csse.unimelb.edu.au
Subscriptions:          mercury-reviews-request at csse.unimelb.edu.au
--------------------------------------------------------------------------



More information about the reviews mailing list