2015-01-28 9 views
0

이상한 문제가 있습니다.동일한 힙 크기를 가진 다른 장치가 OOM을 생성하지 않을 때 Xoom에서 OutOfMemory 오류가 발생했습니다.

삼성 갤럭시 S2 (힙 크기 48MB)에서 제대로 작동하는 앱을 만들었지 만 Motorola Xoom (힙 크기도 48MB)에서 테스트하면 OutOfMemory 오류가 발생하여 종료됩니다.

이것은 힙에 실제로 약 20MB의 데이터 만로드한다는 것을 알기 때문에 특히 이상합니다.

언제든지 같은 장소에서 충돌이 발생합니다. 사전 파일을 벡터에로드 할 때 발생합니다 (앱은 단어 게임이며로드되는 사전 파일은 약 2MB이며 자산 폴더). 사전은 R로 시작하는 단어까지 그것을 만든 다음 유령을 포기합니다. 삼성은 안드로이드 2.2를 실행하고 Xoom은 여기

4.0.3을 실행

은 사전로드 코드입니다 :

public class Dictionary { 
    Vector words = new Vector(); 

    public Dictionary() { 
    } 

    public void loadWords(String dFile) { 
     try { 
      InputStream is = AndroidFileIO.assets.open(dFile); 
      BufferedReader f = new BufferedReader(new InputStreamReader(is), 8192); 
      String word = null; 
      if (is != null) { 
       while ((word = f.readLine()) != null) { 
        words.addElement(word.toUpperCase()); 
       } 
      } 
      is.close(); 
      f = null; 
     } catch (Exception e) { 
      System.err.println("Unable to read from " + dFile); 
      // continue with empty dictionary 
     } 
    } 

을 ... 그리고 여기에 로그 캣 출력입니다 :

01-27 17:16:12.750: D/dalvikvm(9050): GC_FOR_ALLOC freed 63K, 4% free 6529K/6787K, paused 53ms 
01-27 17:16:12.760: I/dalvikvm-heap(9050): Grow heap (frag case) to 8.383MB for 2048016-byte allocation 
01-27 17:16:12.810: D/dalvikvm(9050): GC_CONCURRENT freed <1K, 4% free 8529K/8839K, paused 2ms+8ms 
01-27 17:16:12.870: D/dalvikvm(9050): GC_FOR_ALLOC freed 20K, 4% free 8543K/8839K, paused 25ms 
01-27 17:16:12.890: I/dalvikvm-heap(9050): Grow heap (frag case) to 12.302MB for 4096016-byte allocation 
01-27 17:16:12.940: D/dalvikvm(9050): GC_FOR_ALLOC freed 0K, 3% free 12543K/12871K, paused 24ms 
01-27 17:16:12.980: D/dalvikvm(9050): GC_CONCURRENT freed <1K, 3% free 12543K/12871K, paused 3ms+3ms 
01-27 17:16:13.350: D/libEGL(9050): loaded /system/lib/egl/libGLES_android.so 
01-27 17:16:13.360: D/libEGL(9050): loaded /system/lib/egl/libEGL_tegra.so 
01-27 17:16:13.390: D/libEGL(9050): loaded /system/lib/egl/libGLESv1_CM_tegra.so 
01-27 17:16:13.400: D/libEGL(9050): loaded /system/lib/egl/libGLESv2_tegra.so 
01-27 17:16:13.440: D/OpenGLRenderer(9050): Enabling debug mode 0 
01-27 17:16:13.840: D/dalvikvm(9050): GC_FOR_ALLOC freed 11K, 1% free 14001K/14087K, paused 20ms 
01-27 17:16:13.890: D/dalvikvm(9050): GC_CONCURRENT freed 1K, 1% free 16000K/16135K, paused 2ms+3ms 
01-27 17:16:13.990: D/dalvikvm(9050): GC_FOR_ALLOC freed <1K, 1% free 16001K/16135K, paused 19ms 
01-27 17:16:14.000: I/dalvikvm-heap(9050): Grow heap (frag case) to 19.585MB for 4096016-byte allocation 
01-27 17:16:14.060: D/dalvikvm(9050): GC_CONCURRENT freed <1K, 1% free 20001K/20167K, paused 1ms+20ms 
01-27 17:16:14.370: D/dalvikvm(9050): GC_FOR_ALLOC freed <1K, 1% free 20001K/20167K, paused 17ms 
01-27 17:16:14.380: I/dalvikvm-heap(9050): Grow heap (frag case) to 21.540MB for 2048016-byte allocation 
01-27 17:16:14.420: D/dalvikvm(9050): GC_CONCURRENT freed <1K, 1% free 22001K/22215K, paused 2ms+3ms 
01-27 17:16:14.510: D/dalvikvm(9050): GC_FOR_ALLOC freed <1K, 1% free 22001K/22215K, paused 17ms 
01-27 17:16:14.520: I/dalvikvm-heap(9050): Grow heap (frag case) to 25.446MB for 4096016-byte allocation 
01-27 17:16:14.540: D/dalvikvm(9050): GC_CONCURRENT freed <1K, 1% free 26001K/26247K, paused 2ms+3ms 
01-27 17:16:14.840: D/dalvikvm(9050): GC_FOR_ALLOC freed <1K, 1% free 26001K/26247K, paused 20ms 
01-27 17:16:14.840: I/dalvikvm-heap(9050): Grow heap (frag case) to 27.399MB for 2048016-byte allocation 
01-27 17:16:14.870: D/dalvikvm(9050): GC_CONCURRENT freed <1K, 2% free 28001K/28295K, paused 1ms+3ms 
01-27 17:16:15.070: D/dalvikvm(9050): GC_FOR_ALLOC freed <1K, 2% free 28389K/28743K, paused 20ms 
01-27 17:16:15.080: I/dalvikvm-heap(9050): Grow heap (frag case) to 31.683MB for 4096016-byte allocation 
01-27 17:16:15.130: D/dalvikvm(9050): GC_CONCURRENT freed <1K, 2% free 32388K/32775K, paused 2ms+3ms 
01-27 17:16:15.220: D/dalvikvm(9050): GC_FOR_ALLOC freed 1K, 2% free 32390K/32775K, paused 19ms 
01-27 17:16:15.220: I/dalvikvm-heap(9050): Grow heap (frag case) to 35.591MB for 4096016-byte allocation 
01-27 17:16:15.260: D/dalvikvm(9050): GC_CONCURRENT freed <1K, 2% free 36390K/36807K, paused 1ms+4ms 
01-27 17:16:16.510: D/dalvikvm(9050): GC_CONCURRENT freed 554K, 2% free 37925K/38535K, paused 2ms+5ms 
01-27 17:16:16.940: D/dalvikvm(9050): GC_CONCURRENT freed 1047K, 3% free 38914K/40071K, paused 2ms+6ms 
01-27 17:16:17.150: D/dalvikvm(9050): GC_CONCURRENT freed 982K, 3% free 39891K/41031K, paused 2ms+8ms 
01-27 17:16:17.430: D/dalvikvm(9050): GC_CONCURRENT freed 1012K, 3% free 40876K/42055K, paused 2ms+8ms 
01-27 17:16:17.770: D/dalvikvm(9050): GC_FOR_ALLOC freed 997K, 3% free 41820K/43015K, paused 65ms 
01-27 17:16:18.100: D/dalvikvm(9050): GC_FOR_ALLOC freed 989K, 3% free 42757K/43975K, paused 75ms 
01-27 17:16:18.480: D/dalvikvm(9050): GC_FOR_ALLOC freed 950K, 3% free 43636K/44871K, paused 81ms 
01-27 17:16:18.780: D/dalvikvm(9050): GC_FOR_ALLOC freed 940K, 3% free 44525K/45767K, paused 84ms 
01-27 17:16:19.130: D/dalvikvm(9050): GC_FOR_ALLOC freed 946K, 3% free 45421K/46663K, paused 94ms 
01-27 17:16:19.410: D/dalvikvm(9050): GC_FOR_ALLOC freed 905K, 3% free 46303K/47559K, paused 99ms 
01-27 17:16:19.770: I/dalvikvm-heap(9050): Clamp target GC heap from 48.105MB to 48.000MB 
01-27 17:16:19.770: D/dalvikvm(9050): GC_FOR_ALLOC freed 897K, 3% free 47157K/48455K, paused 106ms 
01-27 17:16:20.050: I/dalvikvm-heap(9050): Clamp target GC heap from 48.855MB to 48.000MB 
01-27 17:16:20.050: D/dalvikvm(9050): GC_FOR_ALLOC freed 793K, 3% free 47924K/49159K, paused 112ms 
01-27 17:16:20.220: I/dalvikvm-heap(9050): Clamp target GC heap from 49.239MB to 48.000MB 
01-27 17:16:20.220: D/dalvikvm(9050): GC_FOR_ALLOC freed 396K, 2% free 48317K/49159K, paused 112ms 
01-27 17:16:20.360: I/dalvikvm-heap(9050): Clamp target GC heap from 49.439MB to 48.000MB 
01-27 17:16:20.360: D/dalvikvm(9050): GC_FOR_ALLOC freed 206K, 2% free 48523K/49159K, paused 109ms 
01-27 17:16:20.480: I/dalvikvm-heap(9050): Clamp target GC heap from 49.541MB to 48.000MB 
01-27 17:16:20.480: D/dalvikvm(9050): GC_FOR_ALLOC freed 104K, 2% free 48626K/49159K, paused 107ms 
01-27 17:16:20.600: I/dalvikvm-heap(9050): Clamp target GC heap from 49.592MB to 48.000MB 
01-27 17:16:20.600: D/dalvikvm(9050): GC_FOR_ALLOC freed 53K, 1% free 48679K/49159K, paused 111ms 
01-27 17:16:20.720: I/dalvikvm-heap(9050): Clamp target GC heap from 49.618MB to 48.000MB 
01-27 17:16:20.730: D/dalvikvm(9050): GC_FOR_ALLOC freed 26K, 1% free 48706K/49159K, paused 117ms 
01-27 17:16:20.830: I/dalvikvm-heap(9050): Clamp target GC heap from 49.628MB to 48.000MB 
01-27 17:16:20.830: D/dalvikvm(9050): GC_FOR_ALLOC freed 11K, 1% free 48717K/49159K, paused 105ms 
01-27 17:16:20.950: I/dalvikvm-heap(9050): Clamp target GC heap from 49.631MB to 48.000MB 
01-27 17:16:20.950: D/dalvikvm(9050): GC_FOR_ALLOC freed 2K, 1% free 48719K/49159K, paused 114ms 
01-27 17:16:21.060: I/dalvikvm-heap(9050): Clamp target GC heap from 49.633MB to 48.000MB 
01-27 17:16:21.060: D/dalvikvm(9050): GC_FOR_ALLOC freed 1K, 1% free 48721K/49159K, paused 112ms 
01-27 17:16:21.170: I/dalvikvm-heap(9050): Clamp target GC heap from 49.636MB to 48.000MB 
01-27 17:16:21.170: D/dalvikvm(9050): GC_FOR_ALLOC freed 3K, 1% free 48724K/49159K, paused 108ms 
01-27 17:16:21.170: I/dalvikvm-heap(9050): Forcing collection of SoftReferences for 176-byte allocation 
01-27 17:16:21.300: I/dalvikvm-heap(9050): Clamp target GC heap from 49.628MB to 48.000MB 
01-27 17:16:21.300: D/dalvikvm(9050): GC_BEFORE_OOM freed 9K, 1% free 48715K/49159K, paused 127ms 
01-27 17:16:21.410: I/dalvikvm-heap(9050): Clamp target GC heap from 49.635MB to 48.000MB 
01-27 17:16:21.410: D/dalvikvm(9050): GC_FOR_ALLOC freed 8K, 1% free 48722K/49159K, paused 108ms 
01-27 17:16:21.520: I/dalvikvm-heap(9050): Clamp target GC heap from 49.639MB to 48.000MB 
01-27 17:16:21.520: D/dalvikvm(9050): GC_FOR_ALLOC freed 4K, 1% free 48727K/49159K, paused 109ms 
01-27 17:16:21.620: I/dalvikvm-heap(9050): Clamp target GC heap from 49.641MB to 48.000MB 
01-27 17:16:21.620: D/dalvikvm(9050): GC_FOR_ALLOC freed 2K, 1% free 48729K/49159K, paused 109ms 
01-27 17:16:21.730: I/dalvikvm-heap(9050): Clamp target GC heap from 49.643MB to 48.000MB 
01-27 17:16:21.730: D/dalvikvm(9050): GC_FOR_ALLOC freed 1K, 1% free 48730K/49159K, paused 105ms 
01-27 17:16:21.840: I/dalvikvm-heap(9050): Clamp target GC heap from 49.643MB to 48.000MB 
01-27 17:16:21.840: D/dalvikvm(9050): GC_FOR_ALLOC freed <1K, 1% free 48730K/49159K, paused 110ms 
01-27 17:16:21.950: I/dalvikvm-heap(9050): Clamp target GC heap from 49.643MB to 48.000MB 
01-27 17:16:21.950: D/dalvikvm(9050): GC_FOR_ALLOC freed <1K, 1% free 48730K/49159K, paused 106ms 
01-27 17:16:22.050: I/dalvikvm-heap(9050): Clamp target GC heap from 49.643MB to 48.000MB 
01-27 17:16:22.050: D/dalvikvm(9050): GC_FOR_ALLOC freed 0K, 1% free 48730K/49159K, paused 106ms 
01-27 17:16:22.050: I/dalvikvm-heap(9050): Forcing collection of SoftReferences for 44-byte allocation 
01-27 17:16:22.170: I/dalvikvm-heap(9050): Clamp target GC heap from 49.643MB to 48.000MB 
01-27 17:16:22.170: D/dalvikvm(9050): GC_BEFORE_OOM freed 0K, 1% free 48730K/49159K, paused 119ms 
01-27 17:16:22.170: E/dalvikvm-heap(9050): Out of memory on a 44-byte allocation. 
01-27 17:16:22.170: I/dalvikvm(9050): "Thread-1489" prio=5 tid=13 RUNNABLE 
01-27 17:16:22.170: I/dalvikvm(9050): | group="main" sCount=0 dsCount=0 obj=0x417e7bd8 self=0x1a6a168 
01-27 17:16:22.170: I/dalvikvm(9050): | sysTid=9119 nice=0 sched=0/0 cgrp=default handle=27700176 
01-27 17:16:22.180: I/dalvikvm(9050): | schedstat=(6918844000 741848000 1627) utm=668 stm=23 core=0 
01-27 17:16:22.180: I/dalvikvm(9050): at java.lang.String.<init>(String.java:~432) 
01-27 17:16:22.180: I/dalvikvm(9050): at java.io.BufferedReader.readLine(BufferedReader.java:363) 
01-27 17:16:22.180: I/dalvikvm(9050): at com.kittykazoo.game.Dictionary.loadWords(Dictionary.java:22) 
01-27 17:16:22.180: I/dalvikvm(9050): at com.kittykazoo.gamecore.ScreenLoading.loadAssets(ScreenLoading.java:232) 
01-27 17:16:22.180: I/dalvikvm(9050): at com.kittykazoo.gamecore.ScreenLoading.update(ScreenLoading.java:64) 
01-27 17:16:22.180: I/dalvikvm(9050): at com.kittykazoo.framework.implementation.AndroidFastRenderView.run(AndroidFastRenderView.java:48) 
01-27 17:16:22.180: I/dalvikvm(9050): at java.lang.Thread.run(Thread.java:856) 
01-27 17:16:22.280: I/dalvikvm-heap(9050): Clamp target GC heap from 49.643MB to 48.000MB 
01-27 17:16:22.280: D/dalvikvm(9050): GC_FOR_ALLOC freed 0K, 1% free 48730K/49159K, paused 107ms 
01-27 17:16:22.280: I/dalvikvm-heap(9050): Forcing collection of SoftReferences for 72-byte allocation 
01-27 17:16:22.400: I/dalvikvm-heap(9050): Clamp target GC heap from 49.643MB to 48.000MB 
01-27 17:16:22.400: D/dalvikvm(9050): GC_BEFORE_OOM freed 0K, 1% free 48730K/49159K, paused 118ms 
01-27 17:16:22.400: E/dalvikvm-heap(9050): Out of memory on a 72-byte allocation. 
01-27 17:16:22.400: I/dalvikvm(9050): "Thread-1489" prio=5 tid=13 RUNNABLE 
01-27 17:16:22.400: I/dalvikvm(9050): | group="main" sCount=0 dsCount=0 obj=0x417e7bd8 self=0x1a6a168 
01-27 17:16:22.400: I/dalvikvm(9050): | sysTid=9119 nice=0 sched=0/0 cgrp=default handle=27700176 
01-27 17:16:22.400: I/dalvikvm(9050): | schedstat=(7142111000 746215000 1665) utm=690 stm=24 core=0 
01-27 17:16:22.400: I/dalvikvm(9050): at java.lang.Throwable.nativeFillInStackTrace(Native Method) 
01-27 17:16:22.400: I/dalvikvm(9050): at java.lang.Throwable.fillInStackTrace(Throwable.java:160) 
01-27 17:16:22.400: I/dalvikvm(9050): at java.lang.Throwable.<init>(Throwable.java:83) 
01-27 17:16:22.400: I/dalvikvm(9050): at java.lang.Error.<init>(Error.java:37) 
01-27 17:16:22.400: I/dalvikvm(9050): at java.lang.VirtualMachineError.<init>(VirtualMachineError.java:35) 
01-27 17:16:22.400: I/dalvikvm(9050): at java.lang.OutOfMemoryError.<init>(OutOfMemoryError.java:33) 
01-27 17:16:22.400: I/dalvikvm(9050): at java.lang.String.<init>(String.java:-1) 
01-27 17:16:22.400: I/dalvikvm(9050): at java.io.BufferedReader.readLine(BufferedReader.java:363) 
01-27 17:16:22.400: I/dalvikvm(9050): at com.kittykazoo.game.Dictionary.loadWords(Dictionary.java:22) 
01-27 17:16:22.400: I/dalvikvm(9050): at com.kittykazoo.gamecore.ScreenLoading.loadAssets(ScreenLoading.java:232) 
01-27 17:16:22.400: I/dalvikvm(9050): at com.kittykazoo.gamecore.ScreenLoading.update(ScreenLoading.java:64) 
01-27 17:16:22.400: I/dalvikvm(9050): at com.kittykazoo.framework.implementation.AndroidFastRenderView.run(AndroidFastRenderView.java:48) 
01-27 17:16:22.400: I/dalvikvm(9050): at java.lang.Thread.run(Thread.java:856) 
01-27 17:16:22.410: W/dalvikvm(9050): Exception thrown (Ljava/lang/OutOfMemoryError;) while throwing internal exception (Ljava/lang/OutOfMemoryError;) 
01-27 17:16:22.510: I/dalvikvm-heap(9050): Clamp target GC heap from 49.643MB to 48.000MB 
01-27 17:16:22.510: D/dalvikvm(9050): GC_FOR_ALLOC freed <1K, 1% free 48730K/49159K, paused 106ms 
01-27 17:16:22.510: I/dalvikvm-heap(9050): Forcing collection of SoftReferences for 54-byte allocation 
01-27 17:16:22.630: I/dalvikvm-heap(9050): Clamp target GC heap from 49.643MB to 48.000MB 
01-27 17:16:22.630: D/dalvikvm(9050): GC_BEFORE_OOM freed 0K, 1% free 48730K/49159K, paused 122ms 
01-27 17:16:22.630: E/dalvikvm-heap(9050): Out of memory on a 54-byte allocation. 
01-27 17:16:22.630: I/dalvikvm(9050): "Thread-1489" prio=5 tid=13 RUNNABLE 
01-27 17:16:22.630: I/dalvikvm(9050): | group="main" sCount=0 dsCount=0 obj=0x417e7bd8 self=0x1a6a168 
01-27 17:16:22.630: I/dalvikvm(9050): | sysTid=9119 nice=0 sched=0/0 cgrp=default handle=27700176 
01-27 17:16:22.630: I/dalvikvm(9050): | schedstat=(7366692000 753065000 1725) utm=709 stm=27 core=0 
01-27 17:16:22.630: I/dalvikvm(9050): at java.io.BufferedReader.readLine(BufferedReader.java:~422) 
01-27 17:16:22.630: I/dalvikvm(9050): at com.kittykazoo.game.Dictionary.loadWords(Dictionary.java:22) 
01-27 17:16:22.630: I/dalvikvm(9050): at com.kittykazoo.gamecore.ScreenLoading.loadAssets(ScreenLoading.java:232) 
01-27 17:16:22.630: I/dalvikvm(9050): at com.kittykazoo.gamecore.ScreenLoading.update(ScreenLoading.java:64) 
01-27 17:16:22.630: I/dalvikvm(9050): at com.kittykazoo.framework.implementation.AndroidFastRenderView.run(AndroidFastRenderView.java:48) 
01-27 17:16:22.630: I/dalvikvm(9050): at java.lang.Thread.run(Thread.java:856) 
01-27 17:16:22.750: I/dalvikvm-heap(9050): Clamp target GC heap from 49.643MB to 48.000MB 
01-27 17:16:22.750: D/dalvikvm(9050): GC_FOR_ALLOC freed 0K, 1% free 48730K/49159K, paused 112ms 
01-27 17:16:22.750: I/dalvikvm-heap(9050): Forcing collection of SoftReferences for 64-byte allocation 
01-27 17:16:22.870: I/dalvikvm-heap(9050): Clamp target GC heap from 49.643MB to 48.000MB 
01-27 17:16:22.870: D/dalvikvm(9050): GC_BEFORE_OOM freed 0K, 1% free 48730K/49159K, paused 122ms 
01-27 17:16:22.870: E/dalvikvm-heap(9050): Out of memory on a 64-byte allocation. 
01-27 17:16:22.870: I/dalvikvm(9050): "Thread-1489" prio=5 tid=13 RUNNABLE 
01-27 17:16:22.870: I/dalvikvm(9050): | group="main" sCount=0 dsCount=0 obj=0x417e7bd8 self=0x1a6a168 
01-27 17:16:22.870: I/dalvikvm(9050): | sysTid=9119 nice=0 sched=0/0 cgrp=default handle=27700176 
01-27 17:16:22.870: I/dalvikvm(9050): | schedstat=(7590841000 762536000 1798) utm=731 stm=28 core=1 
01-27 17:16:22.870: I/dalvikvm(9050): at java.lang.Throwable.nativeFillInStackTrace(Native Method) 
01-27 17:16:22.870: I/dalvikvm(9050): at java.lang.Throwable.fillInStackTrace(Throwable.java:160) 
01-27 17:16:22.870: I/dalvikvm(9050): at java.lang.Throwable.<init>(Throwable.java:83) 
01-27 17:16:22.870: I/dalvikvm(9050): at java.lang.Error.<init>(Error.java:37) 
01-27 17:16:22.870: I/dalvikvm(9050): at java.lang.VirtualMachineError.<init>(VirtualMachineError.java:35) 
01-27 17:16:22.870: I/dalvikvm(9050): at java.lang.OutOfMemoryError.<init>(OutOfMemoryError.java:33) 
01-27 17:16:22.870: I/dalvikvm(9050): at java.io.BufferedReader.readLine(BufferedReader.java:-1) 
01-27 17:16:22.870: I/dalvikvm(9050): at com.kittykazoo.game.Dictionary.loadWords(Dictionary.java:22) 
01-27 17:16:22.870: I/dalvikvm(9050): at com.kittykazoo.gamecore.ScreenLoading.loadAssets(ScreenLoading.java:232) 
01-27 17:16:22.870: I/dalvikvm(9050): at com.kittykazoo.gamecore.ScreenLoading.update(ScreenLoading.java:64) 
01-27 17:16:22.870: I/dalvikvm(9050): at com.kittykazoo.framework.implementation.AndroidFastRenderView.run(AndroidFastRenderView.java:48) 
01-27 17:16:22.870: I/dalvikvm(9050): at java.lang.Thread.run(Thread.java:856) 
01-27 17:16:22.870: W/dalvikvm(9050): Exception thrown (Ljava/lang/OutOfMemoryError;) while throwing internal exception (Ljava/lang/OutOfMemoryError;) 
01-27 17:16:22.870: W/dalvikvm(9050): Could not resolve class ref'ed in exception catch list (class index 1237, exception Ljava/lang/OutOfMemoryError;) 
01-27 17:16:22.870: W/dalvikvm(9050): threadid=13: thread exiting with uncaught exception (group=0x40a391f8) 
01-27 17:16:23.000: I/dalvikvm-heap(9050): Clamp target GC heap from 49.620MB to 48.000MB 
01-27 17:16:23.000: D/dalvikvm(9050): GC_FOR_ALLOC freed 24K, 1% free 48706K/49159K, paused 128ms 
01-27 17:16:23.000: E/AndroidRuntime(9050): FATAL EXCEPTION: Thread-1489 
01-27 17:16:23.000: E/AndroidRuntime(9050): java.lang.OutOfMemoryError: [memory exhausted] 
01-27 17:16:23.000: E/AndroidRuntime(9050):  at dalvik.system.NativeStart.main(Native Method) 
01-27 17:18:00.910: I/Process(9050): Sending signal. PID: 9050 SIG: 9 
+1

답할 수 없다고 생각합니다. 프레임 워크의 다른 버전 (포인트 개정조차도), 화면 크기가 다름, dpi가 다른 것보다 많은 메모리를 차지할 수있는 많은 것들이 있습니다. 내 생각에 당신은 단지 추억을 만들어 내야 만 할 것 같습니다. –

+0

또한 20MB 만로드하면 리소스도 중요 할 수 있습니다. –

+0

대신 sqlite를 사용하십시오. 전체 시간 동안 메모리에 "단어"가 모두 필요하지는 않습니다. – Selvin

답변

0

AndroidManifest.xml 파일에서 android : largeHeap = "true"를 사용하여 문제를 해결했습니다.

AndroidDev 설명서에 따르면 대부분의 응용 프로그램에서는이를 요구해서는 안되지만 보통의 크기의 힙을 사용하여 각 응용 프로그램을 48MB RAM으로 제한하려는 경우에는 약간의 유죄를 인정하지 않습니다 나는 누군가가 12 개 이상의 작은 비트 맵과 배경 음악으로 무엇을 위해 largeHeap을 사용하지 않기로되어 있는지를 보지 못했다.