On 04/07/2014 09:28 AM, Stefan Monnier wrote: >> Anyway, I'd like to get a fix into emacs-24 soon so we can make sure >> we've fixed the GC bug. > > I installed a fix into emacs-24, which lets all symbols be uninterned. > >> Are you vetoing the general approach used in this patch? > > No: I think disallowing unintern is a good idea, but not for emacs-24. Thanks. I'll install my change in trunk. How should we prevent your change merging into trunk? > Indeed, as it turns out, the only non-pure objects referenced from pure > space are symbols and distinguishing uninterned from interned reduces > the number of such "pinned" objects from about 10K to about 250. > > Rather than scan all symbols to find the pinned ones, the code > I installed into emacs-24 keeps a pointer to the first symbol_block > that contains a pinned symbol. This way we only scan about 15K symbols > at the beginning of every GC cycle to mark those 10K pinned symbols. > Compared to keeping a vector of 10K object, this seems like > a good tradeoff. It's unfortunate that we still have to mark Vobarray even though we're separately marking most of the symbols it contains, but I suppose it doesn't matter all that much: because we've already marked most of the symbols in the interned symbol chains, we'll short-circuit in mark_object anyway.