emacs-devel
[Top][All Lists]
Advanced

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

Re: Indentation and gc


From: Eli Zaretskii
Subject: Re: Indentation and gc
Date: Sun, 12 Mar 2023 17:26:04 +0200

> From: Ihor Radchenko <yantar92@posteo.net>
> Cc: arne_bab@web.de, spacibba@aol.com, emacs-devel@gnu.org
> Date: Sun, 12 Mar 2023 15:04:30 +0000
> 
> > We are talking about changing the threshold for the session itself,
> > not just for the initial load.  So the statistics of the initial load
> > is not what is needed.
> 
> Session statistics is much harder to gather.
> It is more realistic to ask people about benchmarking their init.el if
> we want to be serious about bumping gc-cons-threshold.

We should ask them to report statistics after running a session for
enough time.  What exactly qualifies as "enough time" depends on the
usage patterns: there are people, like me, who run a single session
for weeks on end, and there are others who start a new session every
day or even more frequently.  What is interesting is the statistics
near the end of the session.

Statistics from loading init.el is much less interesting, mainly
because reducing GC impact during such short intervals is easy and
well-understood.  We could collect such statistics as well, but it is
not the main goal from where I stand.

> That's why I am seeing reducing the frequency of GCs as more important
> than trying to reduce GC time, which cannot be even halved easily.

A single very long GC will be annoying even if it happens rarely.  So
I don't agree the frequency of GCs is so much more important than the
time it takes to perform a GC.

> >> - memory-limit 6,518,516, stable
> >
> > ??? That's 6 GiB.  Didn't you say your memory footprint stabilizes at
> > 1 GiB?
> 
> memory-limit is a natively compiled function defined in subr.el.
> 
> Signature
> (memory-limit)
> 
> Documentation
> Return an estimate of Emacs virtual memory usage, divided by 1024.
> 
> It is different from Lisp object storage size, which is about 1.3Gb.
> And Emacs memory usage in system monitor is about 1.7Gb.

If the Emacs memory usage in system monitor is 1.7 Gib, how come
memory-limit says it's 6.5 GiB?

> Shall we ask about benchmarking init.el with different gc-cons-threshold
> values as a start?

See above: I'm more interested in statistics of the session than in
statistics of the initial load.



reply via email to

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