GNU bug report logs - #43389
28.0.50; Emacs memory leaks

Previous Next

Package: emacs;

Reported by: Michael Heerdegen <michael_heerdegen <at> web.de>

Date: Mon, 14 Sep 2020 00:44:01 UTC

Severity: normal

Merged with 43395, 43876, 44666

Found in version 28.0.50

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Carlos O'Donell <carlos <at> redhat.com>
To: Trevor Bentley <trevor <at> trevorbentley.com>, Eli Zaretskii <eliz <at> gnu.org>
Cc: fweimer <at> redhat.com, 43389 <at> debbugs.gnu.org, michael_heerdegen <at> web.de, dj <at> redhat.com, bugs <at> gnu.support
Subject: bug#43389: 28.0.50; Emacs memory leaks using hard disk all time
Date: Thu, 26 Nov 2020 23:54:21 -0500
On 11/26/20 10:19 AM, Trevor Bentley wrote:
>>> If it's one trace per thread, though, then we at least know that
>>> my emacs process in question is blazing through threads.
>> 
>> I don't see how this could be true, unless some library you use
>> (ImageMagick?) starts a lot of threads.  Emacs itself is
>> single-threaded, and the only other threads are those from GTK,
>> which should be very few (like, 4 or 5).  This assumes you didn't
>> use Lisp threads, of course.
> 
> Oh, it may be subprocesses instead of threads.  emacs-slack is doing
> all sorts of things, involving both ImageMagick and launching curl
> subprocesses.  Is there a way to prevent libmtrace from following
> children?

Each process generates a trace, and that trace contains the data for
all threads in the process.

I've just pushed MTRACE_CTL_CHILDREN, set that to 0 and the children
will not trace. Thanks for the feedback and enhancement.

commit 8a88a4840b5a573c50264f04f68f71d0496913d3
Author: Carlos O'Donell <carlos <at> redhat.com>
Date:   Thu Nov 26 23:50:57 2020 -0500

    mtrace: Add support for MTRACE_CTL_CHILDREN.
    
    Allow the tracer to only trace the parent process and disable
    tracing in all child processes unless those processes choose
    to programmatically re-eanble tracing via the exposed API.

-- 
Cheers,
Carlos.





This bug report was last modified 4 years and 57 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.