I am new to Instruments in iOS. I am trying to find the memory leak in instruments and using Xcode 4.5.2 and following this tutorial: http://soulwithmobiletechnology.blogspot.sg/2011/04/how-to-check-memory-leaks-in-xcode-4.html.
I am able to find the memory leak and able to press the arrow to go to history of the memory leak item. But when i double-click any of them, it doesn't show the line it is causing the memory leak.
The image is like this:
What am i doing wrong? Need some guidance... Thanks..
Diagnose the Memory Leak Now, it's time to open the leaks instrument: Choose “Xcode” in the top left of the screen. Expand “Open Developer Tool,” and select “Instruments” Now choose “Leaks,” and make sure you have chosen your target app and device at the top (“Choose a profiling template for…”):
The best approach to checking for the existence of a memory leak in your application is by looking at your RAM usage and investigating the total amount of memory been used versus the total amount available. Evidently, it is advisable to obtain snapshots of your memory's heap dump while in a production environment.
Where are memory leaks found? Explanation: Memory leaks happen when your code needs to consume memory in your application, which should be released after a given task is completed but isn't. Memory leaks occur when we are developing client-side reusable scripting objects.
I had trouble finding it at first too. Here's how:
Double clicking that (4), will take you directly to the file, and line of code in question:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With