From: Dmitrii Korobeinikov <dim1212k@gmail.com>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: Eli Zaretskii <eliz@gnu.org>, emacs-devel <emacs-devel@gnu.org>
Subject: Re: Garbage collector: is 800kb a good default?
Date: Fri, 10 Apr 2020 22:26:19 +0600 [thread overview]
Message-ID: <CA+Yh0SRz8Z-0PU5Vn8kMFwv4DxzRJUNmt+demwjY5ZUJxNnNeA@mail.gmail.com> (raw)
In-Reply-To: <jwvo8s032hv.fsf-monnier+emacs@gnu.org>
> It's called "incremental GC". XEmacs does it this way.
That's cool, didn't know that!
> to have, indeed. It's often not too hard to go from "incremental" to
> "concurrent", tho, so I think if we want to go there we should aim for
> a concurrent GC.
I see.
> I'm personally not too worried about that (I don't run much more than
> Emacs on my machines), but a high GC threshold tends to lead to a large
> heap indeed and the problem with it (for me) is that it tends to make
> the GC yet slower (to which the naive reaction would be to increase the
> threshold yet further to make GC even less frequent) and it can also
> slow down the non-GC execution by increasing pressure on the memory
> hierarchy (using more VM pages and more cache lines, reducing
> effectiveness of the CPU's prefetcher) because the heap is more
> sparsely populated.
>
> This is not documented with precise measurements, sadly.
> So it's far from clear how much is too much.
Thanks for expanding on these, I didn't know the details.
For a start, I guess, just timing garbage-collect would work? Then
what's left is to pick a few various ways to generate the garbage.
Best,
DK
пт, 10 апр. 2020 г. в 01:05, Stefan Monnier <monnier@iro.umontreal.ca>:
>
> > Maybe it would be possible to garbage collect in chunks and check
> > after each chunk for input?
>
> It's called "incremental GC". XEmacs does it this way. It'd be nice
> to have, indeed. It's often not too hard to go from "incremental" to
> "concurrent", tho, so I think if we want to go there we should aim for
> a concurrent GC.
>
>
> Stefan
>
next prev parent reply other threads:[~2020-04-10 16:26 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-09 11:59 Garbage collector: is 800kb a good default? Dmitrii Korobeinikov
2020-04-09 12:33 ` Eli Zaretskii
2020-04-09 13:44 ` Dmitrii Korobeinikov
2020-04-09 14:02 ` Eli Zaretskii
2020-04-09 14:46 ` Dmitrii Korobeinikov
2020-04-09 16:42 ` Eli Zaretskii
2020-04-10 16:40 ` Dmitrii Korobeinikov
2020-04-09 19:05 ` Stefan Monnier
2020-04-10 16:26 ` Dmitrii Korobeinikov [this message]
2020-04-09 18:48 ` Stefan Monnier
2020-04-10 14:26 ` Bruno Félix Rezende Ribeiro
2020-04-10 16:49 ` Eli Zaretskii
2020-04-10 18:26 ` Bruno Félix Rezende Ribeiro
2020-04-10 18:53 ` Paul Eggert
2020-04-09 13:47 ` Stefan Monnier
2020-04-09 14:20 ` Dmitrii Korobeinikov
2020-04-09 14:23 ` Eli Zaretskii
2020-04-09 18:42 ` Stefan Monnier
2020-04-09 19:08 ` Eli Zaretskii
2020-04-09 19:31 ` Stefan Monnier
2020-04-10 6:19 ` Eli Zaretskii
2020-04-10 13:03 ` Stefan Monnier
2020-04-10 13:42 ` Eli Zaretskii
2020-04-10 14:34 ` Stefan Monnier
2020-04-10 14:38 ` Stefan Monnier
2020-04-10 15:37 ` Eli Zaretskii
2020-04-10 15:52 ` Andrea Corallo
2020-04-10 16:45 ` Stefan Monnier
2020-04-10 17:18 ` Andrea Corallo
2020-04-09 14:48 ` Andrea Corallo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CA+Yh0SRz8Z-0PU5Vn8kMFwv4DxzRJUNmt+demwjY5ZUJxNnNeA@mail.gmail.com \
--to=dim1212k@gmail.com \
--cc=eliz@gnu.org \
--cc=emacs-devel@gnu.org \
--cc=monnier@iro.umontreal.ca \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).