[Top][All Lists]

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

Re: Larger GC thresholds for non-interactive Emacs

From: Stefan Monnier
Subject: Re: Larger GC thresholds for non-interactive Emacs
Date: Sat, 18 Jun 2022 09:26:08 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

>> 9.5M is actually exactly 10000000 bytes so I suspect these come from
>> either `cedet/semantic.el` or `international/mule-cmds.el` which both
>> set gc-cons-threshold to (max gc-cons-threshold 10000000).
> Ah, I see.  Perhaps those should increase that even more if it still
> leads to 18 GCs?

As I just explained in another message, I think messing with
`gc-cons-threshold` is a bad idea because it depends on the heap size.
We see this here where we end up thinking that maybe we should update
this magical number `10000000` with some other magical number.

The values of `gc-cons-percentage` aren't nearly as magical and they
automatically adjust to changes in heap sizes.  We can see that the
proposed `gc-cons-percentage` of 2.0 would result in a heap size almost
equal to that magical `10000000`, so rather than increase this number we
should likely just remove those hacks.

As for reducing the number of those 18 GCs, the data we have doesn't
tell us that it would bring any benefit.  Instead the data says we already
use up more than 3 times as much memory as what's truly needed (13.6MB
vs 4.1MB), which suggests to me that `10000000` is already rather high.


reply via email to

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