disable GC_all_interior_pointers
authorRobin Templeton <robin@terpri.org>
Fri, 26 Sep 2014 08:20:26 +0000 (04:20 -0400)
committerRobin Templeton <robin@terpri.org>
Mon, 20 Apr 2015 04:29:04 +0000 (00:29 -0400)
* src/emacs.c (main): Don't enable `GC_all_interior_pointers'.
* src/eval.c (specpdl_base): New variable.
  (init_eval_once, grow_specpdl): Save the dummy entry preceding the
  specpdl in `specpdl_base'.

src/emacs.c
src/eval.c

index 319f5ef..4777044 100644 (file)
@@ -718,8 +718,6 @@ static int main2 (void *, int, char **);
 int
 main (int argc, char **argv)
 {
-  /* Override Guile's libgc configuration. */
-  xputenv ("GC_ALL_INTERIOR_POINTERS=1");
   scm_boot_guile (argc, argv, main2, NULL);
 }
 
index 5edfa79..8e60e8e 100644 (file)
@@ -73,6 +73,10 @@ ptrdiff_t specpdl_size;
 
 union specbinding *specpdl;
 
+/* Pointer to the dummy entry before the specpdl.  */
+
+union specbinding *specpdl_base;
+
 /* Pointer to first unused element in specpdl.  */
 
 union specbinding *specpdl_ptr;
@@ -172,6 +176,7 @@ init_eval_once (void)
 {
   enum { size = 50 };
   union specbinding *pdlvec = xmalloc ((size + 1) * sizeof *specpdl);
+  specpdl_base = pdlvec;
   specpdl_size = size;
   specpdl = specpdl_ptr = pdlvec + 1;
   /* Don't forget to update docs (lispref node "Local Variables").  */
@@ -1460,6 +1465,7 @@ grow_specpdl (void)
                          Qnil);
        }
       pdlvec = xpalloc (pdlvec, &pdlvecsize, 1, max_size + 1, sizeof *specpdl);
+      specpdl_base = pdlvec;
       specpdl = pdlvec + 1;
       specpdl_size = pdlvecsize - 1;
       specpdl_ptr = specpdl + count;