Re: Unconventional memory leak problem
Re: Unconventional memory leak problem
- Subject: Re: Unconventional memory leak problem
- From: Shawn Erickson <email@hidden>
- Date: Wed, 06 Sep 2006 08:04:13 -0700
On Sep 5, 2006, at 4:56 PM, Rodney Kennedy wrote:
I have something that appears like a memory leak with the
culprit allocations are related to drawing interface objects
such a NSTableView in 4 or so windows. This is a problem
when I run in a batch mode which induces a considerable amount of
screen drawing including rendering images. The odd thing is
when I interact with the running Application, such as click on
a window or activate or deactivate the application this induces
the AppKit deallocations. If I leave it alone as the active
application or it is not active the real and virtual memory uses
rise and the application will eventually crash.
This is not like a conventional memory leak since there are
deallocations.
I do run multiple threads but I put all drawing on the main thread.
It seems to be NSView related, induced by drawRect calls and it feels
like there needs to be periodic flushing required of something.
It sounds like you are spamming the main thread (its runloop) with
lots and lots of perform events. Each of these events retain the
objects related to them for one and two they are processed in a loop
that appears to not trigger the top level autorelease pool to be
drained.
Are you doing immediate drawing? How are you triggering your screen
drawing from the secondary thread(s)? etc.
-Shawn
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden