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 7880721
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T04:12:41+00:00 2026-06-03T04:12:41+00:00

I’ve been reading a lot about tracking memory usage in Instrument’s but found little

  • 0

I’ve been reading a lot about tracking memory usage in Instrument’s but found little in combination with Monotouch.

There seem to be to three oposing claims here:

  1. Use the Allocations utility of Instruments. The number of “live bytes” is the amount of physical memory used by the application.
  2. Use the Memory Monitor plugin. From the list of processes, pick your app and check the “Real memory” column. That’s the amount of RAM currently in use.
  3. Use VM Tracker and make automatic snapshots. The “Dirty Size” if what you’re after.

From what I’ve noticed:

  • “Real Memory” drops as soon as GC is triggered
  • Even if my “Live Bytes” remain around 30MB I will eventually catch memory warnings
  • With constant “Live Bytes”, “Real Memory” can increase significantly and easily grow to 200MB or more.
  • While using QLPreviewController and viewing an insanly big Word document (1000 pages), scrolling through that document will grow real memory like crazy. If a memory warning is received, neither real memory, not live bytes drop at all. Eventually, the app will crash; Monotouch problem or Apple’s problem?
  • Sometimes, real memory seems to grow and nothing can stop it. Then again, GC seems to clear big chunks of it. There is no real pattern in this.

So what is the correct answer? Is there exactly one?

EDIT: I attached two images. One showing memory usage in a stage in the middle of my app’s life and the seconds one from way later. Both images reflect memory usage at the same point in the UI where nothing but two controllers are on screen. Maybe somebody can still comment what can be read from those number, especially the magic “Memory Tag 70”.

enter image description here
enter image description here

  • 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-06-03T04:12:43+00:00Added an answer on June 3, 2026 at 4:12 am

    Instruments is somewhat of a black box, but here is how I think it is:

    There seem to be to three opposing claims here:
    1. Use the *Allocation*s utility of Instruments. The number of “live bytes” is the amount of physical memory used by the application.

    I don’t know exactly what “Live Bytes” is, but it’s not the amount of physical memory used by the application. I think it is the amount of physical memory used by all ObjectiveC objects (if this theory is correct “Live Bytes” does not contain any memory used by managed code, nor any memory used indirectly by ObjectiveC objects (such as image data), which seems to be true). “Live Bytes” is definitively useful if you want to track down leaked objects, but it’s not (necessarily) a good indicator on how much memory is actually in use.

    2 . Use the Memory Monitor plugin. From the list of processes, pick your app and check the “Real memory” column. That’s the amount of RAM currently in use.

    This is a bit closer: “Real Mem” is the amount of physical memory the app is using which isn’t shared with other apps. The total amount of physical memory the app is using is “Virtual Mem”, but big chunks of “Virtual Mem” is shared between apps (i.e. a shared library will of course use memory when it’s loaded in memory, but since it’s immutable it will only be loaded once for all processes. It will however be added to each process’s “Virtual Mem”, so if you add up the “Virtual Mem” used by all processes you will go way beyond the actual physical memory your device has).

    3 . Use VM Tracker and make automatic snapshots. The “Dirty Size” if what you’re after.

    Correct. “Dirty Size” is what you’re after – this is however closely related to “Real Mem”, it’s just “Real Mem” split into categories so you can easily see what’s using the memory.

    For the typical case of using a lot of memory due to leaking images, the process goes like this:
    1. Verify with the Memory Monitor that your app really has a memory problem.
    2. See in VM Tracker / “Dirty Size” that a lot of memory is used by image data (that’s the magic “Memory Tag 70”).
    3. Use Allocations to find out where CGImages are created, see the corresponding stack trace and track down why those images aren’t freed.

    Each app is different though, so it’s not possible to come up with a short recipe which works for all cases.

    • “Real Memory” drops as soon as GC is triggered
    • Even if my “Live Bytes” remain around 30MB I will eventually catch memory warnings
    • With constant “Live Bytes”, “Real Memory” can increase significantly and easily grow to 200MB or more.

    All these are explained above.

    • While using QLPreviewController and viewing an insanly big Word document (1000 pages), scrolling through that document will grow real memory like crazy. If a memory warning is received, neither real memory, not live bytes drop at all. Eventually, the app will crash; Monotouch problem or Apple’s problem?

    It could be your problem too 🙂 It’s impossible to tell without actually knowing where the memory goes.

    • Sometimes, real memory seems to grow and nothing can stop it. Then again, GC seems to clear big chunks of it. There is no real pattern in this.

    You mean you’re watching real memory grow while your app is doing absolutely nothing? If you’re actually doing something in your app this is completely normal.

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

Sidebar

Related Questions

I am reading a book about Javascript and jQuery and using one of the
I have a jquery bug and I've been looking for hours now, I can't
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I want to count how many characters a certain string has in PHP, but
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
Seemingly simple, but I cannot find anything relevant on the web. What is the
I have a French site that I want to parse, but am running into
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I need to clean up various Word 'smart' characters in user input, including but
I want to construct a data frame in an Rcpp function, but when I

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.