Re: NSImage Memory Management: To Page Or Not To Page.
Re: NSImage Memory Management: To Page Or Not To Page.
- Subject: Re: NSImage Memory Management: To Page Or Not To Page.
- From: Andrew Farmer <email@hidden>
- Date: Sun, 15 Oct 2006 13:16:09 -0700
On 15 Oct 06, at 08:07, Jordan Evans wrote:
I am building an app that scrolls through a large amount of NSImages.
Should I be deallocating images at some point to avoid paging, or
should I allow the system to manage these images by allowing paging?
If I need to create my own memory management for these NSImages, how
can I tell when I my app will begin paging, as to avoid it by
deallocating the NSImages?
Do your own memory management. Forcing the system to swap out parts of
your program's memory will make it force other programs out as well,
which will lead to a significant slowdown when those programs are
reactivated.
The specifics are likely to be a bit of a black art. Best strategy is
probably to figure out how much physical memory the machine has, then
limit the cache to some percentage of that. If you feel like being
really good about it, add a preference setting for what that
percentage should be.
_______________________________________________
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