Checking Memory Usage While Application is Running

Viewed 35416

While running my app, I sometimes get Memory Warning. It doesn't always happen in same place in the code, but I suspect it has something to do with memory allocated from outside of my app; i.e. if there are many applications running on the iPhone in the background I will get the memory warning earlier, and if there are no applications running in the background I will not get the warning at all.

  1. Is there a method I can use to check how much memory my application is using at a certain point?
  2. Is there a method I can use to check how much memory the machine (iPhone/iPad) is using at a certain point? maybe even to check how much memory is still available to use?
  3. In general, maybe somebody knows where I can find data about the memory limitations for the different iOS based machines?

Thanks, Ohad

4 Answers
Related