diff src/share/vm/gc_implementation/g1/heapRegion.cpp @ 11978:dae8324fc7d1

8021879: G1: G1HeapRegionSize flag value not updated correctly Reviewed-by: tschatzl, jmasa
author brutisso
date Thu, 01 Aug 2013 09:35:04 +0200
parents e0c9a1d29eb4
children 3cce976666d9 5888334c9c24
line wrap: on
line diff
--- a/src/share/vm/gc_implementation/g1/heapRegion.cpp	Thu Aug 01 07:03:07 2013 +0200
+++ b/src/share/vm/gc_implementation/g1/heapRegion.cpp	Thu Aug 01 09:35:04 2013 +0200
@@ -314,6 +314,11 @@
     region_size = MAX_REGION_SIZE;
   }
 
+  if (region_size != G1HeapRegionSize) {
+    // Update the flag to make sure that PrintFlagsFinal logs the correct value
+    FLAG_SET_ERGO(uintx, G1HeapRegionSize, region_size);
+  }
+
   // And recalculate the log.
   region_size_log = log2_long((jlong) region_size);