emacs-devel
[Top][All Lists]
Advanced

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

Re: GC and stack marking


From: Eli Zaretskii
Subject: Re: GC and stack marking
Date: Wed, 21 May 2014 19:53:30 +0300

> Date: Wed, 21 May 2014 19:57:42 +0400
> From: Dmitry Antipov <address@hidden>
> CC: Stefan Monnier <address@hidden>, 
>  address@hidden, address@hidden
> 
> On 05/21/2014 07:39 PM, Eli Zaretskii wrote:
> 
> > Now, I have a question: mark_stack stops examining the stack when it
> > gets to its own stack frame.  That is certainly safe, but it sounds
> > too conservative: it should stop at the stack frame of
> > Fgarbage_collect, I think, because no live Lisp object can appear
> > while Fgarbage_collect runs, right?
> 
> 1) Yes, but you need ABI- and machine-specific tricks to find the stack frame 
> boundaries. I.e.
> while in mark_stack, there is no easy way to find start and end of 
> Fgarbage_collect's stack frame.

I thought of passing that to mark_stack as argument when
Fgarbage_collect calls it.  That should work as well as what we do in
mark_stack to find its own stack frame, no?

> 3) But even if 2) works on all platforms we have to support, I don't see a 
> reasons to complicate
>     GC just to avoid scanning a few tens of bytes of an extra stack frame.

The issue discussed in this thread _is_ that reason: we are dumping
Emacs with a dead object, for no good reason, and that object is quite
large (around 1MB).



reply via email to

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