[Top][All Lists]

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

Re: Conservative GC isn't safe

From: Eli Zaretskii
Subject: Re: Conservative GC isn't safe
Date: Mon, 28 Nov 2016 20:00:55 +0200

> From: Daniel Colascione <address@hidden>
> Date: Mon, 28 Nov 2016 09:51:37 -0800
> struct foo* f = something();
> int* x = f->&field;
> something_else(); // invalidate global memory
> *x = 5; // f is dead here, but still in scope
> Even if you don't write this kind of code, the compiler is allowed to 
> generate it.

But there's no such code in Emacs, and will never be.  Lisp objects we
create are either temporaries that can be GC'ed, or values that cannot
be GC'ed, in which case they are passed to some other code, either a
callee or returned as a value.  The only ones that can be dead as
above are the first variety, about which we don't care.

reply via email to

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