hotspot/src/share/vm/runtime/arguments.cpp
changeset 15611 c288dd5b9130
parent 15484 7395ace8a11a
parent 15610 528d799702c7
child 15622 7f9f0d0312ac
equal deleted inserted replaced
15603:5a5a998d4328 15611:c288dd5b9130
  1255   // If we decided above (or user explicitly requested)
  1255   // If we decided above (or user explicitly requested)
  1256   // `promote all' (via MaxTenuringThreshold := 0),
  1256   // `promote all' (via MaxTenuringThreshold := 0),
  1257   // prefer minuscule survivor spaces so as not to waste
  1257   // prefer minuscule survivor spaces so as not to waste
  1258   // space for (non-existent) survivors
  1258   // space for (non-existent) survivors
  1259   if (FLAG_IS_DEFAULT(SurvivorRatio) && MaxTenuringThreshold == 0) {
  1259   if (FLAG_IS_DEFAULT(SurvivorRatio) && MaxTenuringThreshold == 0) {
  1260     FLAG_SET_ERGO(intx, SurvivorRatio, MAX2((intx)1024, SurvivorRatio));
  1260     FLAG_SET_ERGO(uintx, SurvivorRatio, MAX2((uintx)1024, SurvivorRatio));
  1261   }
  1261   }
  1262   // If OldPLABSize is set and CMSParPromoteBlocksToClaim is not,
  1262   // If OldPLABSize is set and CMSParPromoteBlocksToClaim is not,
  1263   // set CMSParPromoteBlocksToClaim equal to OldPLABSize.
  1263   // set CMSParPromoteBlocksToClaim equal to OldPLABSize.
  1264   // This is done in order to make ParNew+CMS configuration to work
  1264   // This is done in order to make ParNew+CMS configuration to work
  1265   // with YoungPLABSize and OldPLABSize options.
  1265   // with YoungPLABSize and OldPLABSize options.
  1895     status = false;
  1895     status = false;
  1896   }
  1896   }
  1897   // Keeping the heap 100% free is hard ;-) so limit it to 99%.
  1897   // Keeping the heap 100% free is hard ;-) so limit it to 99%.
  1898   MinHeapFreeRatio = MIN2(MinHeapFreeRatio, (uintx) 99);
  1898   MinHeapFreeRatio = MIN2(MinHeapFreeRatio, (uintx) 99);
  1899 
  1899 
       
  1900   // Min/MaxMetaspaceFreeRatio
       
  1901   status = status && verify_percentage(MinMetaspaceFreeRatio, "MinMetaspaceFreeRatio");
       
  1902   status = status && verify_percentage(MaxMetaspaceFreeRatio, "MaxMetaspaceFreeRatio");
       
  1903 
       
  1904   if (MinMetaspaceFreeRatio > MaxMetaspaceFreeRatio) {
       
  1905     jio_fprintf(defaultStream::error_stream(),
       
  1906                 "MinMetaspaceFreeRatio (%s" UINTX_FORMAT ") must be less than or "
       
  1907                 "equal to MaxMetaspaceFreeRatio (%s" UINTX_FORMAT ")\n",
       
  1908                 FLAG_IS_DEFAULT(MinMetaspaceFreeRatio) ? "Default: " : "",
       
  1909                 MinMetaspaceFreeRatio,
       
  1910                 FLAG_IS_DEFAULT(MaxMetaspaceFreeRatio) ? "Default: " : "",
       
  1911                 MaxMetaspaceFreeRatio);
       
  1912     status = false;
       
  1913   }
       
  1914 
       
  1915   // Trying to keep 100% free is not practical
       
  1916   MinMetaspaceFreeRatio = MIN2(MinMetaspaceFreeRatio, (uintx) 99);
       
  1917 
  1900   if (FullGCALot && FLAG_IS_DEFAULT(MarkSweepAlwaysCompactCount)) {
  1918   if (FullGCALot && FLAG_IS_DEFAULT(MarkSweepAlwaysCompactCount)) {
  1901     MarkSweepAlwaysCompactCount = 1;  // Move objects every gc.
  1919     MarkSweepAlwaysCompactCount = 1;  // Move objects every gc.
  1902   }
  1920   }
  1903 
  1921 
  1904   if (UseParallelOldGC && ParallelOldGCSplitALot) {
  1922   if (UseParallelOldGC && ParallelOldGCSplitALot) {
  1905     // Settings to encourage splitting.
  1923     // Settings to encourage splitting.
  1906     if (!FLAG_IS_CMDLINE(NewRatio)) {
  1924     if (!FLAG_IS_CMDLINE(NewRatio)) {
  1907       FLAG_SET_CMDLINE(intx, NewRatio, 2);
  1925       FLAG_SET_CMDLINE(uintx, NewRatio, 2);
  1908     }
  1926     }
  1909     if (!FLAG_IS_CMDLINE(ScavengeBeforeFullGC)) {
  1927     if (!FLAG_IS_CMDLINE(ScavengeBeforeFullGC)) {
  1910       FLAG_SET_CMDLINE(bool, ScavengeBeforeFullGC, false);
  1928       FLAG_SET_CMDLINE(bool, ScavengeBeforeFullGC, false);
  1911     }
  1929     }
  1912   }
  1930   }