< prev index next >

src/share/vm/gc/shenandoah/shenandoahHeapRegion.cpp

Print this page

        

@@ -274,10 +274,14 @@
     return last;
   }
 }
 
 void ShenandoahHeapRegion::setup_heap_region_size(size_t initial_heap_size, size_t max_heap_size) {
+  // Absolute minimums we should not ever break:
+  static const size_t MIN_REGION_SIZE = 256*K;
+  static const size_t MIN_NUM_REGIONS = 10;
+
   uintx region_size;
   if (FLAG_IS_DEFAULT(ShenandoahHeapRegionSize)) {
     if (ShenandoahMinRegionSize > initial_heap_size / MIN_NUM_REGIONS) {
       err_msg message("Initial heap size (" SIZE_FORMAT "K) is too low to afford the minimum number "
                       "of regions (" SIZE_FORMAT ") of minimum region size (" SIZE_FORMAT "K).",
< prev index next >