7

Eclipse has a powerful memory analyzer tool: MAT.

Does Android Studio have such a powerful tool, too ?

p.s. I have found a "Allocation Tracking" in the Android DDMS page. And I also know the "Memory Monitor".

But they seem very simple. Take "Memory Monitor" for example, it is only a wave graph. I don't even know which object are still connecting with the GC root.

snwr
  • 103
  • 1
  • 1
  • 7
  • https://developer.android.com/tools/debugging/debugging-memory.html – aga Mar 11 '15 at 07:27
  • Currenty, I think Android Studio has no built-in tool which could be compared to eclipse MAT. The features of "Memory Monitor" are very limited, IMHO. But you could use MAT as an external tool. – Christopher Mar 11 '15 at 07:49
  • yes, my temporary way is to Use "MAT alone version" to analyze a .hprof file – snwr Mar 11 '15 at 09:09
  • Possible duplicate of [How to analyze memory using android studio](http://stackoverflow.com/questions/24547555/how-to-analyze-memory-using-android-studio) – Renjith K N Nov 04 '15 at 06:30

4 Answers4

4

With 1.3, they have integrated heap viewer in studio.

Android studio 1.3 preview

Akshat
  • 4,515
  • 4
  • 27
  • 28
  • In 2.0 its in the Alt-6 Android Monitor-tab, under 'Memory|Cpu', 'Dump Java Heap' button on the left. Wait a while and a tab opens, where you can see currently allocated heap objects and references from code and sort by 'retained size'. – arberg Jan 21 '16 at 20:22
1

Android Studio 3.0 preview has much a much better tool, comparable to MAT, that also offers CPU and network activity profiling.

https://developer.android.com/studio/preview/features/android-profiler.html

kodi
  • 2,195
  • 1
  • 14
  • 20
-1

Yes obviously! Android Studio has very powerful tools for these purposes.

You can find these tools in the "Tools" tab.

Search for Tools > Android > Then you can explore "Memory Monitor" and "Android Device Monitor" as well.

Mohammad Arman
  • 7,020
  • 2
  • 36
  • 50
  • 3
    "Memory Monitor" only shows a wave graph. I don't even know which object is still connecting with the GC root. – snwr Mar 11 '15 at 09:08
  • You can check detailed instruction from the following link: http://stackoverflow.com/questions/24547555/how-to-analyze-memory-using-android-studio – Mohammad Arman Mar 11 '15 at 12:31
  • 2
    You cannot compare the two... MAT is a ton more powerful! – TacB0sS Jul 15 '15 at 09:12
-2

Try Tools > Android > Memory Monitor if you are looking for a high level overview.

Andrea Thacker
  • 3,440
  • 1
  • 25
  • 37
  • "Memory Monitor" only shows a wave graph. I don't even know which object is still connecting with the GC root. – snwr Mar 11 '15 at 09:08