Re: After Autoreleasing Still Getting Leaked
Re: After Autoreleasing Still Getting Leaked
- Subject: Re: After Autoreleasing Still Getting Leaked
- From: Scott Ribe <email@hidden>
- Date: Wed, 15 Jun 2011 10:33:51 -0600
On Jun 15, 2011, at 10:22 AM, Bing Li wrote:
> In addition, according to Activity Monitor, the memory consumed by the
> program increased only when some new threads are added. After the threads
> were dead, the memory was lowered to a fixed amount. Is it fine?
Each thread has data structures associated with it, besides any memory you may allocate within the thread, which cannot be freed until the thread terminates (the thread's stack for instance). So it's a question of how much the memory went up. If you want to find out if it's system overhead or your allocations, you could experiment with creating some "empty" threads that just sleep() long enough to give you a chance to watch them, and compare the memory usage to what you see with your real threads.
--
Scott Ribe
email@hidden
http://www.elevated-dev.com/
(303) 722-0567 voice
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden