[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Memory again
From: |
Jan Djärv |
Subject: |
Re: Memory again |
Date: |
Thu, 5 Jan 2012 23:37:54 +0100 |
Hello.
I see this increase also. Memory does not seem to be given back to the system
on OSX.
Maybe we should try using gmalloc on OSX. There is problem however, the unexec
for OSX
uses a special malloc for temacs and the normal one for the dumped emacs. I'm
not even sure gmalloc
works on OSX.
Jan D.
5 jan 2012 kl. 07:13 skrev emacs user:
> On Fri, Dec 23, 2011 at 12:44 PM, emacs user <address@hidden> wrote:
>> On Fri, Dec 23, 2011 at 2:39 AM, Stefan Monnier
>>
>>> The GC stats you posted indicate that the GC knows of about 27MB of data
>>> (10MB of which is actually unused but can't be returned to malloc due to
>>> fragmentation) which doesn't account for the 214MB you mention. So it
>>> looks like that data is held by the C code.
>>>
>>> Of course, I don't know what the 214MB represent, if it is resident set
>>> size, then there really seems to be a leak, whereas if it's the total
>>> virtual size, it may also be an artifact of various other things.
>>>
>>>
>>> Stefan
>>
>> here is something which I am hoping is reproducible by others:
>> download
>> http://emacsforosx.com/emacs-builds/Emacs-2011-12-23-universal-10.6.8.dmg
>> save to desktop.
>>
>> start emacs:
>> $ ~/Desktop/Emacs.app/Contents/MacOS/Emacs -Q&
>>
>> create a file that contains the following line many times
>> asdf asdf asdf asdf asdf asdf asdf asdf asdf asdf asdf asdf asdf asdf asdf
>> $ wc t : 687456 10311840 52246656 t
>> $ ls -l t: -rw------- 1 x staff 52246656 Dec 23 05:08 t
>>
>> edit it using the above emacs.
>> kill all buffers, do M-x garbage-collect
>>
>> look at the process:
>>
>> $ ps -vefl | head -1
>> PID STAT TIME SL RE PAGEIN VSZ RSS LIM TSIZ
>> %CPU %MEM COMMAND UID PPID C STIME TTY F
>> PRI NI WCHAN ADDR
>>
>> before editing the file:
>> $ ps -vefl | grep 62764
>> 62764 S 0:00.78 0 0 0 2571020 30852 - 0
>> 0.3 0.7 /Users/xxx/Deskt 501 62068 0 5:38AM ttys001 4006
>> 49 0 - ffffff8012762000
>>
>> after editing it, killing the buffer, and doing M-x garbage-collect
>> $ ps -vefl | grep 62764
>> 62764 S 0:01.85 0 0 0 2625752 83036 - 0
>> 0.6 2.0 /Users/xxx/Deskt 501 62068 0 5:38AM ttys001 4006
>> 48 0 - ffffff8012762000
>>
>> I am running on Lion, Macbook Air. does this help?
>
> just in case this is helpful, I see the same increase in RSS using
> emacs 23.3 too, but not under linux. is this a problem, or is this
> increase in RSS normal?