Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android Studio heap dump is empty

Android Studio 4.0.2 is exporting empty hprof files from memory that is not empty. Empty memory The profiler shows memory correctly, but I would like to use MAT to analyze the heap because Android Studio does not give the information in an easy to parse way. Non empty memory

Is there a way to fix this?

like image 653
John Glen Avatar asked Apr 10 '26 03:04

John Glen


1 Answers

I know this is an older post, but have you tried using ADB to collect the dumpheap of your application?

adb shell ps | grep app-name

adb shell am dumpheap pid /data/local/tmp/android.hprof

adb pull /data/local/tmp/android.hprof

You will then need to use the HPROF-Converter to view in Android Studio https://stuff.mit.edu/afs/sipb/project/android/docs/tools/help/hprof-conv.html

like image 53
Ryan Burch Avatar answered Apr 12 '26 15:04

Ryan Burch



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!