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

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

Re: How to debug memory leaks


From: Arthur Miller
Subject: Re: How to debug memory leaks
Date: Fri, 26 Mar 2021 15:57:09 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Stefan Monnier <monnier@iro.umontreal.ca> writes:

>> I think you mentioned a while ago that you use shell-mode.  In that mode
>> Emacs keeps a buffer with all of the shell activity in it.  By default
>> it doesn't remove anything, at least on my Emacs.
>
> The `M-x memory-report` in Emacs's Git version makes these issues
> immediately visible.
>
> Sadly, in my experience the kinds of excessive memory use problems
> people experience come from elsewhere (such as the occasional need to
> load all the fonts that exist in your system to try and figure out if
> you have a font that can display that damn emoticon that your brother
> found cute).

:-)

Would there be any way for Emacs to unload unused fonts? GC?

As a thought, could it be possible to implement something like "clean
emacs state" or/and "clean buffer state". It would throw away undo
history, unload unused stuff, for example in eshell/term/ansi-term kill
the buffer text, etc. Something that would work either on entire Emacs state,
or just on a buffer state; or maybe on both.

Is it just to set some variables to nil and collect garbage or is it
more work than so?



reply via email to

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