2

I have three UIViewControllers and all of their dealloc methods are called whenever I dismiss them. This is exactly what I want to happen so that the memory won't balloon up.

However, when I ran the Profile to test the memory usage and for some leakages, I noticed that even if the dealloc was called, the live memory doesn't decrease somehow. What's more is that it keeps on increasing whenever I switch from one UIViewController to another (which is expected by the way). Sometimes it will decrease, but only a few memory will be decreased.

I am sure that the dealloc methods of each UIViewControllers were called since I put a log inside of the methods. Also, no there are no leakages recorded when I used Profile.

So can anyone explain why the memory does not decrease at all?

4

1 回答 1

1

正如其他人所说,没有看到您的代码很难弄清楚发生了什么。因此,我将为您留下这篇这篇关于使用仪器分析堆的文章。

于 2012-10-19T09:43:31.553 回答