1

i face a problem on understand the GC log.

Log: GC_EXTERNAL_ALLOC freed 82K, 48% free 2829K/5379K, external 1702K/2137K, paused 28ms

Anyone can explain the meaning of the log?

Thanks.

King Wu
  • 387
  • 1
  • 8
  • 22
  • Means Dalvik is trying to collect collectable objects to make some space for non-collectable ones. Most likely you've memory leaks. – fardjad Aug 19 '12 at 10:20
  • 1
    http://stackoverflow.com/questions/4976566/what-do-gc-for-malloc-gc-explicit-and-other-gc-mean-in-android-logcat – Dalmas Aug 19 '12 at 10:26
  • @fardjad how to you know memory leak @@?? – King Wu Aug 19 '12 at 15:05

2 Answers2

2

In this Google IO I once watched I believe the presenter (Patrick Dubroy) states the different logs, and their association: Google I/O: Memory Management for Android Apps

I hope this helps.

Luke Taylor
  • 9,481
  • 13
  • 41
  • 73
0

I don't think those log messages are documented.

If you're developing with Eclipse you are supposed to use DDMS perspective | Allocation Tracker to track your memory allocations.

Alexander Kulyakhtin
  • 47,782
  • 38
  • 107
  • 158
  • In fact, i don't know how to check the memory usage on runtime. Do you have any idea to check memory used? – King Wu Aug 19 '12 at 15:03
  • @King Wu One can watch 'Allocation Size' in DDMS|Allocation Tracker (probably, while doing things with the application). If it steadily increases all the time somewhere then it's a bad sign. – Alexander Kulyakhtin Aug 19 '12 at 15:20