Subject: bug#60237: 30.0.50; tree sitter core dumps when I edebug view a node

From: Po Lu <[email-masked]>
Date: Sat, 11 Mar 2023 11:29:44 +0800

Stefan Monnier <[email-masked]> writes:

> In the text you quote I simply try and describe the kinds of situations
> where I think the problem can appear.  I don't know which of those are
> actually possible, nor do I suggest what should be done about it.
>
> And yes, maybe we can use `gc_in_progress`.
> So far I haven't taken a look at that, but feel free to do so.

I thought you'd know a problem or two with `gc_in_progress', which is
why you decided to check for QAutomatic_GC in the backtrace.

> Probably.  At the same time, if we're sampling while running
> `post-gc-hook`, then it's safe to do the "normal" job of the sampling
> code (the GC proper is completed already), so maybe the better thing to
> do in that case is to treat it as a backtrace which has `Automatic GC`
> as its root (i.e. ignore the part of the backtrace that's above
> `Automatic GC`).

That makes sense, yes.