Merge

Thu, 10 Jan 2013 07:32:32 -0800

author
jmasa
date
Thu, 10 Jan 2013 07:32:32 -0800
changeset 4408
b2fef6b220e9
parent 4406
18c3c3fa291b
parent 4407
4c8bf5e55392
child 4415
f1c06dcee0b5

Merge

src/share/vm/runtime/arguments.cpp file | annotate | diff | comparison | revisions
     1.1 --- a/src/share/vm/runtime/arguments.cpp	Wed Jan 09 21:18:52 2013 -0500
     1.2 +++ b/src/share/vm/runtime/arguments.cpp	Thu Jan 10 07:32:32 2013 -0800
     1.3 @@ -1454,30 +1454,34 @@
     1.4  
     1.5    // If no heap maximum was requested explicitly, use some reasonable fraction
     1.6    // of the physical memory, up to a maximum of 1GB.
     1.7 -  if (UseParallelGC) {
     1.8 -    FLAG_SET_DEFAULT(ParallelGCThreads,
     1.9 -                     Abstract_VM_Version::parallel_worker_threads());
    1.10 -
    1.11 -    // If InitialSurvivorRatio or MinSurvivorRatio were not specified, but the
    1.12 -    // SurvivorRatio has been set, reset their default values to SurvivorRatio +
    1.13 -    // 2.  By doing this we make SurvivorRatio also work for Parallel Scavenger.
    1.14 -    // See CR 6362902 for details.
    1.15 -    if (!FLAG_IS_DEFAULT(SurvivorRatio)) {
    1.16 -      if (FLAG_IS_DEFAULT(InitialSurvivorRatio)) {
    1.17 -         FLAG_SET_DEFAULT(InitialSurvivorRatio, SurvivorRatio + 2);
    1.18 -      }
    1.19 -      if (FLAG_IS_DEFAULT(MinSurvivorRatio)) {
    1.20 -        FLAG_SET_DEFAULT(MinSurvivorRatio, SurvivorRatio + 2);
    1.21 -      }
    1.22 +  FLAG_SET_DEFAULT(ParallelGCThreads,
    1.23 +                   Abstract_VM_Version::parallel_worker_threads());
    1.24 +  if (ParallelGCThreads == 0) {
    1.25 +    jio_fprintf(defaultStream::error_stream(),
    1.26 +        "The Parallel GC can not be combined with -XX:ParallelGCThreads=0\n");
    1.27 +    vm_exit(1);
    1.28 +  }
    1.29 +
    1.30 +
    1.31 +  // If InitialSurvivorRatio or MinSurvivorRatio were not specified, but the
    1.32 +  // SurvivorRatio has been set, reset their default values to SurvivorRatio +
    1.33 +  // 2.  By doing this we make SurvivorRatio also work for Parallel Scavenger.
    1.34 +  // See CR 6362902 for details.
    1.35 +  if (!FLAG_IS_DEFAULT(SurvivorRatio)) {
    1.36 +    if (FLAG_IS_DEFAULT(InitialSurvivorRatio)) {
    1.37 +       FLAG_SET_DEFAULT(InitialSurvivorRatio, SurvivorRatio + 2);
    1.38      }
    1.39 -
    1.40 -    if (UseParallelOldGC) {
    1.41 -      // Par compact uses lower default values since they are treated as
    1.42 -      // minimums.  These are different defaults because of the different
    1.43 -      // interpretation and are not ergonomically set.
    1.44 -      if (FLAG_IS_DEFAULT(MarkSweepDeadRatio)) {
    1.45 -        FLAG_SET_DEFAULT(MarkSweepDeadRatio, 1);
    1.46 -      }
    1.47 +    if (FLAG_IS_DEFAULT(MinSurvivorRatio)) {
    1.48 +      FLAG_SET_DEFAULT(MinSurvivorRatio, SurvivorRatio + 2);
    1.49 +    }
    1.50 +  }
    1.51 +
    1.52 +  if (UseParallelOldGC) {
    1.53 +    // Par compact uses lower default values since they are treated as
    1.54 +    // minimums.  These are different defaults because of the different
    1.55 +    // interpretation and are not ergonomically set.
    1.56 +    if (FLAG_IS_DEFAULT(MarkSweepDeadRatio)) {
    1.57 +      FLAG_SET_DEFAULT(MarkSweepDeadRatio, 1);
    1.58      }
    1.59    }
    1.60  }

mercurial