• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: memory management question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: memory management question


  • Subject: Re: memory management question
  • From: Sherm Pendley <email@hidden>
  • Date: Thu, 18 Mar 2004 20:54:24 -0500

On Mar 18, 2004, at 6:36 PM, matt neuburg wrote:

In fact, this is apparently not a Cocoa memory management
issue - I'm not leaking memory, AFAIK - it's a system memory management
issue. It's like I'm fighting the virtual memory system.

Have you tried using memory-mapped files to read your TIFFs? -Ii.e. NSData's +dataWithContentsOfMappedFile: or -initWithContentsOfMappedFile:, or even the low-level mmap() function.

My thinking is that, because memory-mapped files are directly mapped into your app's virtual memory space, there's no system buffer to be held when the file is closed.

This assumes, naturally, that your files are <2GB. Bigger files than that won't be mmap()-able until we have 64-bit address spaces.

sherm--
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


References: 
 >memory management question (From: matt neuburg <email@hidden>)

  • Prev by Date: Autorelease pools?
  • Next by Date: Re: Autorelease pools?
  • Previous by thread: memory management question
  • Next by thread: Re: memory management question
  • Index(es):
    • Date
    • Thread