aboutsummaryrefslogtreecommitdiffstats
path: root/src/eval.c
diff options
context:
space:
mode:
authorTom Tromey2012-08-15 13:01:36 -0600
committerTom Tromey2012-08-15 13:01:36 -0600
commit2d525b793f1b0fd2b6f66881310bec8684bceffe (patch)
tree932fb8b75974ac4c16ecfc5bc216fe362b0a4d27 /src/eval.c
parent68b32482437e05f0994c4dd0ab5b0c27d39f0f6d (diff)
downloademacs-2d525b793f1b0fd2b6f66881310bec8684bceffe.tar.gz
emacs-2d525b793f1b0fd2b6f66881310bec8684bceffe.zip
This parameterizes the GC a bit to make it thread-ready.
The basic idea is that whenever a thread "exits lisp" -- that is, releases the global lock in favor of another thread -- it must save its stack boundaries in the thread object. This way the boundaries are always available for marking. This is the purpose of flush_stack_call_func. I haven't tested this under all the possible GC configurations. There is a new FIXME in a spot that i didn't convert. Arguably all_threads should go in the previous patch.
Diffstat (limited to 'src/eval.c')
-rw-r--r--src/eval.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/eval.c b/src/eval.c
index 768cdc1a8f8..49ead499044 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -165,6 +165,19 @@ init_eval (void)
165 when_entered_debugger = -1; 165 when_entered_debugger = -1;
166} 166}
167 167
168#if (GC_MARK_STACK == GC_MAKE_GCPROS_NOOPS \
169 || GC_MARK_STACK == GC_MARK_STACK_CHECK_GCPROS)
170void
171mark_catchlist (struct catchtag *catch)
172{
173 for (; catch; catch = catch->next)
174 {
175 mark_object (catch->tag);
176 mark_object (catch->val);
177 }
178}
179#endif
180
168/* Unwind-protect function used by call_debugger. */ 181/* Unwind-protect function used by call_debugger. */
169 182
170static Lisp_Object 183static Lisp_Object