hotspot/src/share/vm/runtime/arguments.cpp
changeset 19732 88f375dd7d65
parent 19679 23a7ef6ca0f9
parent 19730 4c38872d277e
child 19968 64f9d23af647
child 20012 d654728c6fc9
child 19979 ebe1dbb6e1aa
equal deleted inserted replaced
19725:68b03cf81206 19732:88f375dd7d65
  1603     result = MIN2(result, max_allocatable / MaxVirtMemFraction);
  1603     result = MIN2(result, max_allocatable / MaxVirtMemFraction);
  1604   }
  1604   }
  1605   return result;
  1605   return result;
  1606 }
  1606 }
  1607 
  1607 
  1608 void Arguments::set_heap_base_min_address() {
       
  1609   if (FLAG_IS_DEFAULT(HeapBaseMinAddress) && UseG1GC && HeapBaseMinAddress < 1*G) {
       
  1610     // By default HeapBaseMinAddress is 2G on all platforms except Solaris x86.
       
  1611     // G1 currently needs a lot of C-heap, so on Solaris we have to give G1
       
  1612     // some extra space for the C-heap compared to other collectors.
       
  1613     // Use FLAG_SET_DEFAULT here rather than FLAG_SET_ERGO to make sure that
       
  1614     // code that checks for default values work correctly.
       
  1615     FLAG_SET_DEFAULT(HeapBaseMinAddress, 1*G);
       
  1616   }
       
  1617 }
       
  1618 
       
  1619 void Arguments::set_heap_size() {
  1608 void Arguments::set_heap_size() {
  1620   if (!FLAG_IS_DEFAULT(DefaultMaxRAMFraction)) {
  1609   if (!FLAG_IS_DEFAULT(DefaultMaxRAMFraction)) {
  1621     // Deprecated flag
  1610     // Deprecated flag
  1622     FLAG_SET_CMDLINE(uintx, MaxRAMFraction, DefaultMaxRAMFraction);
  1611     FLAG_SET_CMDLINE(uintx, MaxRAMFraction, DefaultMaxRAMFraction);
  1623   }
  1612   }
  3535       vm_exit_during_initialization(
  3524       vm_exit_during_initialization(
  3536         "Incompatible compilation policy selected", NULL);
  3525         "Incompatible compilation policy selected", NULL);
  3537     }
  3526     }
  3538   }
  3527   }
  3539 
  3528 
  3540   set_heap_base_min_address();
       
  3541 
       
  3542   // Set heap size based on available physical memory
  3529   // Set heap size based on available physical memory
  3543   set_heap_size();
  3530   set_heap_size();
  3544 
  3531 
  3545 #if INCLUDE_ALL_GCS
  3532 #if INCLUDE_ALL_GCS
  3546   // Set per-collector flags
  3533   // Set per-collector flags