emacs-devel
[Top][All Lists]
Advanced

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

Re: Indentation and gc


From: Ihor Radchenko
Subject: Re: Indentation and gc
Date: Wed, 15 Mar 2023 10:29:51 +0000

Eli Zaretskii <eliz@gnu.org> writes:

>> At least, it can indirectly demonstrate the impact of GC threshold onto
>> Emacs memory footprint. I guess it is what we worry about at the end.
>> Or does the fragmentation cause other severe effects in addition to
>> higher memory usage?
>
> _Real_ memory fragmentation, if it happens in Emacs, should cause the
> memory footprint grow all the time without leveling out, and
> malloc-info should then show that most of the memory is in small
> chunks that cannot be spliced together.
>
> However, I have yet to see a platform where Emacs causes memory
> fragmentation.  Where the system malloc cannot be trusted, we use
> gmalloc (and in the past used ralloc).  Most modern platforms have
> reliable malloc these days (the single known exception is MSDOS), so
> this problem largely doesn't exist.

In other words, we should not worry about gc-cons-threshold causing
_real_ memory fragmentation. Just about increasing the memory footprint.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>



reply via email to

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