[Top][All Lists]

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

Re: memory leak

From: Luc Teirlinck
Subject: Re: memory leak
Date: Fri, 28 Apr 2006 20:56:40 -0500 (CDT)

Robert Chassell wrote:

   Can anyone else reproduce a memory leak in the current CVS GNU/Emacs?

Not me.

First of all, I guess that you checked that building Emacs did not
overflow pure storage.  Doing so will definitely produce the results
you describe.  You can check whether the variable pure-space-overflow
is really non-nil or whether (garbage-collect) returns a non-nil value
(it should).

If that is not the problem, I definitely know a way to produce
something that looks very much like a memory leak, although it is not.
All you have to do is have a large number of large files open that
require a lot of fontification, with global-font-lock-mode enabled.
If you have ten or so files the size of lisp/Changelog open, then
after you completely quit using Emacs, the memory consumed by the
Emacs process can easily grow by more than 35 percent, or 8M or more,
over a period spanning an hour or more on a fast machine.  Except for
the apparent "memory leak" there also is an apparent rogue CPU usage.
There is no real memory leak however.  After an hour or more, when all
buffers are completely fontified, both CPU usage and "memory leak"
completely stop.

   These instances of GNU Emacs appear to consume RAM at a rate of 124 kb/min.

I got at least that in my experiments with opening many large files.
But the memory consumption eventually stops, maybe after many hours on
a slow machine.

I can not reproduce anything that even mimics a memory leak without
_both_ global-font-lock-mode being enabled _and_ a large number of
large files requiring heavy fontification being open.



reply via email to

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