2

I'm getting a lot of "dalvikvm: GC_CONCURRENT..." messages in logcat, and googling around resulted in me downloading the Eclipse Memory Analyzer... I've figured out how to use it, but I don't know how to understand it. I've never dealt with memory leaks before, so bear with me.

The "Leak Suspects" include "android.content.res.Resources", "android.graphics.Bitmap", and "org.apache.harmony.xnet.provider.jsse.TrustManagerImpl" loaded by "system class loader". I don't really know what that means or how that's supposed to help me; I don't even use bitmaps in the app I'm trying to make.

How is this supposed to help me?

Kalina
  • 5,504
  • 16
  • 64
  • 101

1 Answers1

4

The "Leak Suspects" include "android.content.res.Resources", "android.graphics.Bitmap", and "org.apache.harmony.xnet.provider.jsse.TrustManagerImpl" loaded by "system class loader".

Those are there for every Android application and represent memory allocated by the Android base classes.

How is this supposed to help me?

You can start by finding references to your own objects from your own classes, then tracing their roots to find out what is keeping those objects in memory.

You may wish to watch this presentation from Google I|O 2011, which covers this process.

CommonsWare
  • 986,068
  • 189
  • 2,389
  • 2,491
  • I see. Unfortunately those are the only three Leak Suspects that the Eclipse Memory Analyzer informed me about. Should I just not worry about that, then? I am getting a whole lot of GC_CONCURRENT messages. – Kalina Apr 05 '12 at 12:47
  • 1
    @TheBeatlemaniac: Garbage collection is perfectly normal. MAT helps you find things that are *not* being garbage collected. If you are experiencing specific performance problems related to excessive garbage collections, you need to track your allocations -- see http://developer.android.com/guide/developing/debugging/ddms.html#alloc – CommonsWare Apr 05 '12 at 12:49
  • Yes, it is running incredibly slow and I am getting a wall of text with the GC_CONCURRENT stuff :( – Kalina Apr 05 '12 at 18:02