Subject: bug#47067: 28.0.50; [feature/native-comp] Crash while scrolling through dispnew.c

From: Eli Zaretskii <[email-masked]>
Date: Sun, 14 Mar 2021 14:17:59 +0200

> From: Pip Cet <[email-masked]>
> Date: Sat, 13 Mar 2021 15:45:52 +0000
> Cc: [email-masked], Andrea Corallo <[email-masked]>
> 
> >   (defcustom comp-debug 0
> >     "Debug level for native compilation, a number between 0 and 3.
> >   This is intended for debugging the compiler itself.
> >     0 no debugging output.
> >       This is the recommended value unless you are debugging the compiler itself.
> >     1 emit debug symbols and dump pseudo C code.
> >     2 dump gcc passes and libgccjit log file.
> >     3 dump libgccjit reproducers."
> >
> > The first line is somewhat deceptive, as it doesn't say portions of
> > the backtrace will be anonymous; the backtrace is useful even if not
> > "debugging the compiler itself".  And the description of level 1 says
> > it will also "dump pseudo C code", which I don't think is needed for
> > most of the debugging.  Maybe we need an intermediate level that just
> > leaves the symbols without dumping the pseudo code?
> 
> I think that's an excellent idea.

Andrea, is it possible to have debug level 1 produce only the debug
info within the generated code, and leave the pseudo-code dump for
higher levels?  If you don't have time to implement this yourself, can
you instruct me what changes need to be made?  I'd like to try
recompiling everything with debug level 1 and see if that helps with
the backtraces.

Thanks.