1

I am writing game which has native engine, I could easily run it on Samung Galaxy II but I am trying to run it on Beagleboard which has Jellybean installed on it. The main process of my app/game is com.xxx.yy. The process restarts after launching. I the only logcat information I get is

I/dalvikvm-heap(1802): Grow heap (frag case) to 10.448MB for 1233535-byte allocation

I assume that this the cause for an error. If So can some one suggest me what is going wrong in here, and what is the work around .

Note: This might be possible duplicate of How to increase heap size of an android application? I tried his solution, but this doesn't work.

Community
  • 1
  • 1
Shri
  • 1,223
  • 5
  • 22
  • 31
  • That logcat information is nothing unusual. Is com.xxx.yyy your game or is it something else? – Lieuwe Jan 23 '13 at 10:27
  • 2
    you are running out of memory. get a dump from DDMS and analyze it from eclipse memory analyzer – Asanka Senavirathna Jan 23 '13 at 10:34
  • @AsankaSenavirathna: I vote you up for general answer, I am not sure how can really analyse c++ out of memory dump here, I also wanted to check if there is any option to automatically heap when it goes OOM. – Shri Jan 23 '13 at 11:43
  • 1
    1) doesn't matter even if this is c++(NDK). in eclipse, run your app on the device. in eclipse , go o the DDMS tab and you will see your device in device tab. expand it and you will see the list of package names. select your app and click on dump. you will find more information here [link](http://android-developers.blogspot.com/2011/03/memory-analysis-for-android.html) – Asanka Senavirathna Jan 23 '13 at 11:51
  • @AsankaSenavirathna: I know what want me to do. I know that process under common circumstances especially when you want to check for memory leaks. But my point is "when do click on the dump button?" Immediately after I start my app, The app is closed and process is restarted. So it doesn't give me chance to click on dump if I start my APP. If you follow this [link](http://stackoverflow.com/questions/6131769/is-there-a-way-to-have-an-android-process-produce-a-heap-dump-on-an-outofmemorye) Is there something available for native side? – Shri Jan 23 '13 at 12:18
  • @techjeevi sorry i forgot to mention that. according to [this article](http://www.vogella.com/articles/EclipseMemoryAnalyser/article.html) that can be done. however it didn't worked for me. what i did was i keep looking at the logcat. in the logcat, you can see GC logs with freed/available memory. in this way i was able to dump it before app crashes. – Asanka Senavirathna Jan 23 '13 at 12:33
  • @AsankaSenavirathna I tried that bit as well, Since android has its own dalvik VM, and doesn't support oom flags which are mentioned in your link above. I can see where actually memory goes into OOM but I am not sure to dump as before even I open DDMS my app is back into restart state – Shri Jan 23 '13 at 12:41
  • let us [continue this discussion in chat](http://chat.stackoverflow.com/rooms/23220/discussion-between-techjeevi-and-asanka-senavirathna) – Shri Jan 23 '13 at 12:57

0 Answers0