Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1085905
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T22:44:50+00:00 2026-05-16T22:44:50+00:00

Heres the problem. I have an app that is essentially an image gallery, it

  • 0

Heres the problem. I have an app that is essentially an image gallery, it pulls images down from an xml feed, and archives them locally, then gradually loads 5 images at a time into the scroll view to be displayed.

I have had thousands of problems with using [UIImage imageNamed:…] and NSURLRequest/NSData as both cause the app to cache excessive amounts of data. Anyway, I now have the app running at an almost constant 25-30MB, with no sudden spikes, and with only a few kB of data being leaked from memory (due to NSKeyedArchiver and me retaining some values). However the app ALWAYS gets terminated by the OS for (what seems like) no apparent reason.

Sorry if I’m being a bit stupid and not spotting something, the crash report does appear to be telling me that tonnes of memory has been paged by the app, however the allocations and leaks instrument is telling a different story… and really I supposed my question is more along the lines of “why is instruments lying to me?”

Incident Identifier: D258E503-D024-4265-B079-E6C47DE5DA29
CrashReporter Key:   c3904eb2c9cf4bf4f89f53fb9c836ad44586684f
OS Version:          iPhone OS 3.2.1 (7B405)
Date:                2010-09-21 13:27:50 +0100

Free pages:        464
Wired pages:       12587
Purgeable pages:   0
Largest process:   MediaLib

Processes
         Name                 UUID                    Count resident pages
        MediaLib <6db92ce87a5d7e287702f2cb87ba8c53>   30579 (jettisoned) (active)
     debugserver <f885fe2348e72988381a73137cc90c7b>     127
notification_pro <4c9a7ee0a5bbe160465991228f2d2f2e>      64
notification_pro <4c9a7ee0a5bbe160465991228f2d2f2e>      64
            afcd <ddda2413b8953e5c56721dfe05a82d78>      68
    syslog_relay <1c73f841b191556b6911bc6b4736b50f>      63
      DTMobileIS <b34df288cd9a07a995933bbd6b66717a>    1169
notification_pro <4c9a7ee0a5bbe160465991228f2d2f2e>      64
            ptpd <e3f855cfd629600a4812e7e90c77667e>     191
         syslogd <6990426209e51a8ee13c91cd1a050a2e>      78
    mediaserverd <2eda3ce5e1c8a1a4d7b8271cef1f2d12>     314
     debugserver <f885fe2348e72988381a73137cc90c7b>      74
     debugserver <f885fe2348e72988381a73137cc90c7b>      74
     debugserver <f885fe2348e72988381a73137cc90c7b>      74
             lsd <eb108595d2a932a8d244d1ab7386cd0f>     121
            apsd <0775f0d80d1cd1fb4b562d2f94caf051>     172
         notifyd <74e4a487a89c31f68917b22605baf6c6>      68
        BTServer <21dd98c0ab29b910cd51cb703a9cb9b9>     107
      CommCenter <e4b9cc04f083f22232c92ee1363fe669>     170
     SpringBoard <745085d9a24a8529f0ceb6c33d766873>    4821 (active)
      accessoryd <59ca0ba146c28bf5c8ab6e3d2e81bbad>      97
         configd <36001fe17103f8af6d3b525cb23ac8a0>     305
   fairplayd.K48 <2d997ffca1a568f9c5400ac32d8f0782>      85
       locationd <60fd4d90fec18a76ffc0b8a45351fe54>     600
   mDNSResponder <a6f01dd493e3d2bfe318f5d44f8508e2>     107
       lockdownd <378f09833cdc57b1b60e42d79c355938>     273
MobileStorageMou <7f2cd9f90fab302a42a63460b1c4d775>      67
         launchd <880e75c2db9c0f670516c58935e89b58>      80

**End**

Many thanks in advance for someone who can give me a slap and point me in the right direction 😉

EDIT:

I have just run the app through the activity monitor instrument and this is giving me a “Real Memory” readout of 65-80MB, could this be due to allocation of memory on another thread, which isn’t picked up by the allocations instrument?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T22:44:51+00:00Added an answer on May 16, 2026 at 10:44 pm

    You should know that NSImage#imageNamed: caches the image. In other words, you lose fine control over the life cycle of those images. Use NSImage#initWith... instead and the cache will not be used.

    Also know that a .png image that is a 2KB download can easily be a 6MB image when loaded into an UIImage. Image data is decompressed when loaded into an UIImage so don’t look too much to the original size. Look at the size of the bitmap. Usually simply width * height * 4.

    You mention that NSURLConnection and NSData are causing memory issues. This is probably because of improper usage. Like failing to do proper memory management.

    Post code or more details if you want better hints about resource management.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Very strange problem with my iPhone App. We have an App that has been
Recently I've encountered a problem. I have an app that talks to the server.
Here's my problem: I have a virtual method defined in a .h file that
Here's my problem.I have 2 xmlfiles with identical structure, with the second xml containing
Here's the problem: 1.) We have page here... www.blah.com/mypage.html 2.) That page requests a
Small problem here with an MVC app that I'm not sure how to figure
I have an app that uses fragments.I'm using backward compability package with Android 2.2.
I have an app that loads several resources when it's first run, which are
Here's my problem - I have some code like this: <mx:Canvas width=300 height=300> <mx:Button
Here's my problem: I have to call a web service with a secure header

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.