unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: "Jan Djärv" <jan.h.d@swipnet.se>
To: Steve Purcell <steve@sanityinc.com>
Cc: 17751@debbugs.gnu.org
Subject: bug#17751: 24.4.50; More memory leaks under OS X Mavericks
Date: Wed, 11 Jun 2014 07:04:31 +0200	[thread overview]
Message-ID: <BAE9EDE1-44AF-40D7-970D-47ADB89B106E@swipnet.se> (raw)
In-Reply-To: <4E76EFA4-1364-44C7-BBEC-7B8AA30675C7@sanityinc.com>

Hello.

10 jun 2014 kl. 22:55 skrev Steve Purcell <steve@sanityinc.com>:

> Even with this recent nightly Emacs build from emacsformacosx.com, I've
> been suffering from the distnoted memory/CPU-ballooning issue addressed in
> #15946, with that process reaching > 100% CPU and several GB in
> memory. Quitting Emacs solves the problem.
> 
> In the discussion on #15946, Jan D suggested running "leaks" on Emacs to
> see what's going on, so I tried that:
> 
> Starting with an "emacs -Q", I can fire up the "leaks" command in a loop
> and watch Emacs start to leak memory.
> 
> While Emacs is the front-most application and the mouse is moving above
> it, new leaks appear. When the mouse stops, the leaks stop appearing.
> 
> While the cursor blinks (as it does, by default), new leaks appear. When
> the cursor stops blinking after a few seconds, the leaks stop
> appearing. (Unless the mouse is also moving.)
> 
> As I write this message in the clean "emacs -Q" instance, "leaks" tells
> me:
> 
>   Process 60460: 53511 leaks for 11106784 total leaked bytes.
> 
> So 11MB leaked in the space of a few minutes and a few lines typed, with
> just a couple of buffers open!
> 
> The leaks look like this:
> 
>  Leak: 0x10c1d62a0  size=160  zone: DefaultMallocZone_0x1006c5000   OS_dispatch_source  ObjC  libdispatch.dylib
>        0x762d8c20 0x00007fff 0x00000001 0x00000000      .-v............
>        0x89abcdef 0xffffffff 0x762da480 0x00007fff     ..........-v....
>        0x00000000 0x00000000 0x00000000 0x00000000     ................
>        0x00000000 0x00000000 0x00000000 0x00000000     ................
>        0x00000000 0x00000000 0x00000000 0x00000000     ................
>        0x00000001 0x00000000 0x00009cc4 0x00000000     ................
>        0x8979a90c 0x00007fff 0x014002f0 0x00000001     ..y.......@.....
>        0x0c1d6390 0x00000001 0x00000002 0x0000004c     .c..........L...
>        ...

You can not tuncate leaks output without loosing important information.  Post the whole leaks output, comressed.

Leaks is sometimes confused by Emacs memory allocation.  Relevant output can only be gotten just after you have run garbage-collect in Emacs.

Dmitry wrote:

> I don't know how 'leaks' works, but this doesn't look too representative for me.
> Could you please try valgrind? According to http://valgrind.org/info/platforms.html,
> it should work on OSX. Unfortunately you have to compile Emacs yourself to get
> bare (temacs) executable because regular binary will not work.

Valgrind really does not work on OSX, except for the simplest programs.  It is a waste of time to try it.

	Jan D.






  parent reply	other threads:[~2014-06-11  5:04 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-10 20:55 bug#17751: 24.4.50; More memory leaks under OS X Mavericks Steve Purcell
2014-06-11  3:57 ` Dmitry Antipov
2014-06-11  5:04 ` Jan Djärv [this message]
2014-06-11  6:10   ` Jan D.
2014-06-11  6:18     ` Jan D.
2014-06-11  7:12       ` Steve Purcell
2014-06-11  7:15       ` martin rudalics
2014-06-11 16:40         ` Steve Purcell
2014-06-11 17:29           ` Jan D.
     [not found]             ` <099A5827-C02A-40E6-AA0B-2836CCE9A907@sanityinc.com>
2014-06-11 18:05               ` Jan D.
2015-12-26 15:27                 ` Lars Ingebrigtsen
2014-06-11 17:22         ` Jan D.

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=BAE9EDE1-44AF-40D7-970D-47ADB89B106E@swipnet.se \
    --to=jan.h.d@swipnet.se \
    --cc=17751@debbugs.gnu.org \
    --cc=steve@sanityinc.com \
    /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).