Subj : Re: JS_ARENAMETER To : Stephen Jones From : Brendan Eich Date : Fri Aug 22 2003 05:11 pm Stephen Jones wrote: >"Brendan Eich" wrote in message >news:3F430D1C.4070604@meer.net... > > >>Stephen Jones wrote: >> >> >> >>>I've uncovered what appears to be a consistent memnory leak in >>>JS_GetStringBytes. I looked at the archives for this list and saw similar >>>reports, but they weren't calling JS_ShutDown and I am. When I switched >>> >>> >from > > >>>JS_GetStringBytes to JS_GetStringChars, the leak went away. >>> >>> >>> >>What version of the engine sources are you using? >> >> > >1.5 rc4 > As I pointed out in a reply to what looked like a to-me-only email version of this post, the bug (http://bugzilla.mozilla.org/show_bug.cgi?id=132088) was fixed in RC4a, and we're up to RC5a now, which everyone should be using so as to avoid encountering fixed bugs. Phil pointed out http://www.mozilla.org/js/spidermonkey/release-notes/ as the place to check when in doubt. /be > > > >>>I'm still hemoragging memory somewhere in SpiderMonkey, but not as bad as >>>before. Does anyone have any suggestions on where to look? >>> >>> >>> >>When do you run the GC? When you think you leak via JS_GetStringBytes, >>do you see the GC collect the string associated via the >>deflated_string_cache with the bytes? >> >> > >I see some strings get collected and I see some strings being deleted from >deflated_string_cache, but not all. Like I said, when I replaced >JS_GetStringBytes with JS_GetStringChar, the reported memory leaks went >away. > >I'm only running GC when we run out of memory, but I have a debug terminal >window setup that allows me to run GC manually at any time. This is what I'm >using for testing purposes to make sure all memory is cleaned up. > >I'm trying the "GlowCode" product to help track down where all this memory >is being allocated. >- S > > > > .