bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#36566: 27.0.50; debug is sometimes horribly slow


From: Stefan Monnier
Subject: bug#36566: 27.0.50; debug is sometimes horribly slow
Date: Sat, 14 May 2022 09:52:32 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

>> Changing `edebug-print-level' helps... Maybe the default is too
>> large?
> Changing it to 20 doesn't seem to have much effect, but at 10, things
> are pretty speedy.  The problem then is that the output is all dots:

How 'bout using a `print-char-length` limit after which we truncate?
The truncation could "respect trees" in the sense that we'd truncate

    (((a b c) (d e f) (g h k)))

to something like

    (((a b c) (d e ...) ...))

rather than to

    (((a b c) (d e ...

if the `print-char-length` is 14.

I suspect that with such a limit we should eliminate "all" performance
issues, because printing should then have a complexity
O(print-char-length) rather than O(sizeof(object)), except for the
`print--preprocess` part which would still be O(sizeof(object)), but
since that one is all written in C (and performs a lot less work) the
constant is such much lower that it rarely dominates.


        Stefan






reply via email to

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