guile-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Guile-commits] 26/27: Fix --without-threads against threaded BDW-GC


From: Andy Wingo
Subject: [Guile-commits] 26/27: Fix --without-threads against threaded BDW-GC
Date: Mon, 25 Jul 2016 09:53:47 +0000 (UTC)

wingo pushed a commit to branch master
in repository guile.

commit 401214313b03803d754ed8836a6cb50ba456b2cb
Author: Andy Wingo <address@hidden>
Date:   Sun Jul 24 15:29:48 2016 +0200

    Fix --without-threads against threaded BDW-GC
    
    * libguile/gc.c (scm_storage_prehistory): Prevent BDW-GC from spawning
      marker threads if Guile was built without threading support.
---
 libguile/gc.c |    8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/libguile/gc.c b/libguile/gc.c
index 13823c0..b75a688 100644
--- a/libguile/gc.c
+++ b/libguile/gc.c
@@ -1,5 +1,5 @@
 /* Copyright (C) 1995,1996,1997,1998,1999,2000,2001, 2002, 2003, 2006,
- *   2008, 2009, 2010, 2011, 2012, 2013, 2014 Free Software Foundation, Inc.
+ *   2008, 2009, 2010, 2011, 2012, 2013, 2014, 2016 Free Software Foundation, 
Inc.
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Lesser General Public License
@@ -608,6 +608,12 @@ scm_storage_prehistory ()
   setenv ("GC_MARKERS", "1", 1);
 #endif
 
+#if SCM_I_GSC_USE_NULL_THREADS
+  /* If we have disabled threads in Guile, ensure that the GC doesn't
+     spawn any marker threads.  */
+  setenv ("GC_MARKERS", "1", 1);
+#endif
+
   GC_INIT ();
 
   GC_expand_hp (DEFAULT_INITIAL_HEAP_SIZE);



reply via email to

[Prev in Thread] Current Thread [Next in Thread]