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: Sat, 11 Mar 2023 20:49:31 +0200

> From: Gregor Zattler <telegraph@gmx.net>
> Cc: yantar92@posteo.net, spacibba@aol.com, arne_bab@web.de, 
> emacs-devel@gnu.org
> Date: Sat, 11 Mar 2023 19:35:13 +0100
> 
> > No.  The limitation on the _increment_ should have nothing to do with
> > how much memory is already consumed or how much total memory is
> > available on the system.  Imagine an Emacs with N MiB of memory
> > footprint on a system that has N+1 MiB of memory available.
> >
> > IOW, what matters is how much is _left_, not how much is already used
> > or totally available.
> 
> At the moment Emacs does not adjust gc-cons-threshold
> to how much memory is left but uses a static
> gc-cons-threshold which is rather low.  Ihor's
> calculations use the same conservative rather low value
> but scales it with overall memory.

No, Ihor proposed to _enlarge_ the threshold if the total amount of
memory is large enough.  So the proposal does not keep the same
conservative low value.

> > "Therefore"? how does this follow from what you did?  Your tuning is
> > static and is appropriate for your usage.  Others will most probably
> > come up with different numbers using the same procedure.  How do you
> > propose to make this into some kind of auto-adjustment, when how much
> > garbage is generated and the amount of slowdown this incurs depends on
> > the Lisp programs that typically run?
> 
> I did it statically because I lack the ability to
> program an auto-adjusting solution.
> 
> But it would be nice if gc-cons-threshold would be
> adjusted after each garbage collection in relation to
> the amount of time consumed in the last garbage
> collections.

We are discussing how to do that.  I don't think there's a
disagreement that if we can find a reasonable way of doing that, it
will be nice to have it.



reply via email to

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