OSDN Git Service

Be more explicit in our -Xms == -Xmx message, and stop pretending we'll fix it.
authorElliott Hughes <enh@google.com>
Sun, 26 Sep 2010 22:12:21 +0000 (15:12 -0700)
committerElliott Hughes <enh@google.com>
Sun, 26 Sep 2010 22:12:21 +0000 (15:12 -0700)
This is only going to be fixed by removing the notion of external allocations.
I'll add a note to that bug that we should remove this check entirely.

Bug: 2714377
Change-Id: If84bd98676fcc1e2d4f9f234d547553d256f5785

vm/Init.c

index 74fbce9..cd69496 100644 (file)
--- a/vm/Init.c
+++ b/vm/Init.c
@@ -1030,11 +1030,14 @@ static int dvmProcessOptions(int argc, const char* const argv[],
         }
     }
 
-    /* We should be able to cope with these being equal, but until
-     * http://b/2714377 is fixed, we can't.
+    /* External allocations count against the space we "reserve" by setting
+     * the heap max size greater than the heap start size. Without a gap,
+     * no external allocations will succeed. You won't get very far like that,
+     * so let's not even try.
      */
     if (gDvm.heapSizeStart >= gDvm.heapSizeMax) {
-        dvmFprintf(stderr, "Heap start size must be < heap max size\n");
+        dvmFprintf(stderr, "External allocations require a gap between the "
+            "heap start size and max size\n");
         return -1;
     }