Install Memory Analyzer Tool (MAT) on Eclipse
We need to install two eclipse plugins
- BIRT Chart Engine //For Getting Memory Info with Pie Chart diagrams
- MAT //For Getting Memory Info
——————————————————————————————
Install BIRT Chart Engine plugins
- Eclipse —> Help Menu —> Install New Software —> Add
- Enter below information
Name : BIRT Chart Engine.
Location: http://download.eclipse.org/birt/update-site/4.3
Source: http://wiki.eclipse.org/BIRT_Update_Site_URL
Now select only Birt Chart Engine and Go for Install.
——————————————————————————————
Install MAT plugins
- Eclipse —> Help Menu —> Install New Software —> Add
- Enter below information
Name : MAT
Location: http://download.eclipse.org/mat/1.5/update-site/
Source:http://www.eclipse.org/mat/downloads.php
Now select MAT and Birt Chart Plugin for MAT and Go for Install.
——————————————————————————————
Get Heap Dump of Android Project
Once you installed ..
- Connect Android Device for Debugging/Testing App
- Now Go the The project and Build/Run
- Open DDMS —> Devices —> Select Process (Project’s Package Name in List)
Click the "Dump HPROF File" icon in the Devices view's toolbar (looks like a half-filled can with a downward-pointing arrow)
Select the option Leak Suspects Report and click Finish.
- That’s it!!.. You Got the Project’s Memory Heap Report