[phpBB Debug] PHP Notice: in file /viewtopic.php on line 981: date(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Berlin' for 'CEST/2.0/DST' instead
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 981: getdate(): It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'Europe/Berlin' for 'CEST/2.0/DST' instead
Tynsoe Projects • View topic - Bug: Memory Leak

Bug: Memory Leak

Bug: Memory Leak

Postby avogadro23 » Wed Apr 28, 2010 11:11 pm

Did a search and this didn't seem to be already on here, but I think I've identified a memory leak on my system.

I noticed in Activity Monitor that every time I open up the Geektool prefpane, Real Mem usage jumps 10-14MB. Virtual Memory allocation is not affected. Testing method was to disable Geektool, reenable, and then close and open prefpane several times. This can be repeated any number of times, and the memory is never reclaimed. I verified that this occurs even when I have disabled all my Geeklets.

I attached a screencap to show how I was able to boost the memory usage from the initial 23MB to 1/2 gig through this process.

System: MBP Unibody 15" (2009)
OSX 10.6.3
Geektool 3.0 RC5 (116)
Attachments
Screen shot 2010-04-28 at [Apr 28] 4.09PM.png
Activity Monitor Screenshot
Screen shot 2010-04-28 at [Apr 28] 4.09PM.png (26.87 KiB) Viewed 7058 times
avogadro23
 
Posts: 3
Joined: Wed Apr 28, 2010 11:00 pm

Re: Bug: Memory Leak

Postby ybizeul » Thu Apr 29, 2010 11:43 am

This is an excellent question.

In fact, I ran several diagnostic tools and am pretty confident that there is no leaks in that situation.

According to this excellent article http://www.mikeash.com/pyblog/friday-qa ... stics.html RSIZE is pretty tricky to account and mey be subject to inaccuracy.

If somebody has a better explanation, I'd be glad to hear !
ybizeul
Site Admin
 
Posts: 133
Joined: Fri Jan 22, 2010 4:34 pm

Re: Bug: Memory Leak

Postby avogadro23 » Thu Apr 29, 2010 4:06 pm

I read the last part of that link, that talks about RSIZE, etc. He gave some caveats about interpreting RSIZE, RPRVT, etc, but he never said RSIZE (physical memory used) isn't trustworthy.

So, it seems to me that this is still an improper behavior by Geektool. Maybe it's not strictly a leak, in the sense that the memory might be getting reclaimed, but rampant memory allocation is still a problem.

The article mentions "leaks" where can I find that, and is it difficult to use? I am willing to provide you with any info you need to help solve this.

Here's 4 more screenshots, using top this time.
01-restarted geektool
02-reloaded prefpane 5 times
03-reloaded prefpane additional 5 times (10 total)
04-waited a minute then took one last screenshot.
Attachments
avogadro23_top-memoryleak_screencaps.zip
Some more caps, using top
(174.45 KiB) Downloaded 488 times
avogadro23
 
Posts: 3
Joined: Wed Apr 28, 2010 11:00 pm

Re: Bug: Memory Leak

Postby ybizeul » Fri Apr 30, 2010 5:35 am

I think the "leaks" binary is installed with Xcode, it is a command that you can run in Terminal

Thanks for the help
ybizeul
Site Admin
 
Posts: 133
Joined: Fri Jan 22, 2010 4:34 pm

Re: Bug: Memory Leak

Postby avogadro23 » Mon May 03, 2010 5:25 pm

Installed Xcode. Here is the output from leaks. I hope it helps. Maybe what I described isn't even a real "leak" though. Maybe it is due to how things are loaded?

Anyway, cheers!
Attachments
geektool_leaksoutput.txt.zip
Output from leaks.
(73.44 KiB) Downloaded 525 times
avogadro23
 
Posts: 3
Joined: Wed Apr 28, 2010 11:00 pm

Re: Bug: Memory Leak

Postby ybizeul » Thu May 06, 2010 7:01 pm

Ok, this is definitively a big good old leak.

I think I identified it, and will commit a fixed release soon
ybizeul
Site Admin
 
Posts: 133
Joined: Fri Jan 22, 2010 4:34 pm


Return to GeekTool

Who is online

Users browsing this forum: No registered users and 4 guests

cron