Question

I am referencing this to memory profiling of my application, when I launched TraceView with my trace file, there are several colors and items shows on TraceView window.

So how can I understand where memory leaks, and what is means of colors.

Was it helpful?

Solution

I don't think you should use TraceView for memory leaks finding. It's a tool for getting information about performance and memory usage of applications. Try Memory Analyzer Plugin for Eclipse. You can make a dump of your app's memory with Dump HPROF file button in DDMS and look for memory leaks in this dump using MAT.

UPDATE:
When the memory dump is made you'll see MAT's Getting Started Wizard with Leak Suspects Report radio button checked. Click Finish button and you'll see Leak Suspects window. There will be a diagram of memory usage and a list of potential leaks. Some leaks are false-positive. If you think that a particular leak is the real one, you can click on a Detail link to get more information about this leak.

When the Detail tab opens you will see a path to a leaked object. You can click any objects in the path and get some useful information about these objects. For example you can get a list of objects that have a reference to the selected object (List objects -> with outgoing reference).

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top