This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: reproducible cygwin memory problems


Eli, here is a response from the cygwin list. thanks to Reini Urban for this.


Date: Sat, 12 Aug 2006 11:32:01 +0200 From: Reini Urban <rurban at x-ray dot at> To: cygwin at cygwin dot com Subject: Re: reproducible cygwin memory problems Sender: cygwin-owner at cygwin dot com


emacs user schrieb:
Dear cygwin friends, while debugging some emacs related problem, we seem to come to the conclusion that there is a cygwin issue here. can someone please comment on this?

From: Eli Zaretskii <eliz@gnu.org>
> From: "emacs user" <emacs_user@hotmail.com>
> Cc: emacs-pretest-bug@gnu.org
> Bcc:
> Date: Thu, 10 Aug 2006 01:06:22 -0400
>
> #kill it
> #(clear-image-cache t)
> I am here1
> I am here2
> I am here4
> I am here5
> I am here6
> I am here5
> I am here6

Okay, thanks. This shows that free_image does get called.

What image types did you try till now?  If you tried with only one
image type, please see if other image types exhibit the same problem
(i.e. that memory is not returned to system when an image is killed
and the image cache cleared).

problem occurs with both jpeg and gif. I didnt try others


If you already tried all the supported image types, I cannot think of
any reason but one: that the Cygwin implementation of malloc/free does
not return freed memory to the OS.  If this is the conclusion, then it
should probably be taken up with Cygwin maintainers on their mailing
list.

Look Eli, that's really a bold statement, esp. when elisp is involved. cygwin uses the newlib libc. How does it come to your mind that newlib's free() and subsequently Microsoft's VirtualFree (,MEM_RELEASE) doesn't work as advertised? Please see the src for newlib's free() at src/newlib/libc/stdlib/mallocr.c http://cygwin.com/cgi-bin/cvsweb.cgi/src/newlib/libc/stdlib/mallocr.c?rev=1.15&content-type=text/x-cvsweb-markup&cvsroot=src


POSIX free() is not like perl or lisp, where there's no such concept of free(), if by lazyness or better strategies.

POSIX free() and cygwin's free() does give back it's malloc'ed buffers
back to the OS, and the OS does list them correctly as free.

What you have here is an ELISP issue, which doesn't free it's interim's
memory, and you falsely accuse the C part of the image library. Please
have a look again in some lisp allocated buffers and then check if some
free() is missing.


-- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/

_________________________________________________________________
Don?t just search. Find. Check out the new MSN Search! http://search.msn.click-url.com/go/onm00200636ave/direct/01/



-- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]