Skip to content
Permalink
Browse files
8262074: Consolidate the default value of MetaspaceSize
Reviewed-by: iklam, coleenp
  • Loading branch information
tstuefe committed Feb 26, 2021
1 parent 05c11bc commit c9e91897aed9a8f07f4228c85b6c6b305272d730
Show file tree
Hide file tree
Showing 13 changed files with 1 addition and 28 deletions.
@@ -52,7 +52,6 @@ define_pd_global(bool, ProfileInterpreter, false);
define_pd_global(intx, CodeCacheExpansionSize, 32*K );
define_pd_global(uintx, CodeCacheMinBlockLength, 1);
define_pd_global(uintx, CodeCacheMinimumUseSpace, 400*K);
define_pd_global(uintx, MetaspaceSize, 12*M );
define_pd_global(bool, NeverActAsServerClassMachine, true );
define_pd_global(uint64_t,MaxRAM, 1ULL*G);
define_pd_global(bool, CICompileOSR, true );
@@ -77,9 +77,6 @@ define_pd_global(intx, NonNMethodCodeHeapSize, 5*M );
define_pd_global(uintx, CodeCacheMinBlockLength, 6);
define_pd_global(uintx, CodeCacheMinimumUseSpace, 400*K);

// Heap related flags
define_pd_global(uintx,MetaspaceSize, ScaleForWordSize(16*M));

// Ergonomics related flags
define_pd_global(bool, NeverActAsServerClassMachine, false);

@@ -53,7 +53,6 @@ define_pd_global(bool, ProfileInterpreter, false);
define_pd_global(size_t, CodeCacheExpansionSize, 32*K );
define_pd_global(uintx, CodeCacheMinBlockLength, 1);
define_pd_global(size_t, CodeCacheMinimumUseSpace, 400*K);
define_pd_global(size_t, MetaspaceSize, 12*M );
define_pd_global(bool, NeverActAsServerClassMachine, true);
define_pd_global(uint64_t, MaxRAM, 1ULL*G);
define_pd_global(bool, CICompileOSR, true );
@@ -100,9 +100,6 @@ define_pd_global(size_t, CodeCacheMinimumUseSpace, 400*K);

define_pd_global(bool, TrapBasedRangeChecks, false); // Not needed

// Heap related flags
define_pd_global(size_t, MetaspaceSize, ScaleForWordSize(16*M));

// Ergonomics related flags
define_pd_global(bool, NeverActAsServerClassMachine, false);

@@ -51,7 +51,6 @@ define_pd_global(uintx, NonNMethodCodeHeapSize, 5*M );
define_pd_global(uintx, CodeCacheExpansionSize, 32*K);
define_pd_global(uintx, CodeCacheMinBlockLength, 1);
define_pd_global(uintx, CodeCacheMinimumUseSpace, 400*K);
define_pd_global(size_t, MetaspaceSize, 12*M);
define_pd_global(bool, NeverActAsServerClassMachine, true);
define_pd_global(size_t, NewSizeThreadIncrease, 16*K);
define_pd_global(uint64_t, MaxRAM, 1ULL*G);
@@ -93,9 +93,6 @@ define_pd_global(uintx, CodeCacheMinimumUseSpace, 400*K);

define_pd_global(bool, TrapBasedRangeChecks, true);

// Heap related flags
define_pd_global(size_t, MetaspaceSize, ScaleForWordSize(16*M));

// Ergonomics related flags
define_pd_global(bool, NeverActAsServerClassMachine, false);

@@ -51,7 +51,6 @@ define_pd_global(uintx, NonNMethodCodeHeapSize, 5*M);
define_pd_global(uintx, CodeCacheExpansionSize, 32*K);
define_pd_global(uintx, CodeCacheMinBlockLength, 1);
define_pd_global(uintx, CodeCacheMinimumUseSpace, 400*K);
define_pd_global(size_t, MetaspaceSize, 12*M);
define_pd_global(bool, NeverActAsServerClassMachine, true);
define_pd_global(size_t, NewSizeThreadIncrease, 16*K);
define_pd_global(uint64_t, MaxRAM, 1ULL*G);
@@ -82,9 +82,6 @@ define_pd_global(uintx, CodeCacheMinimumUseSpace, 400*K);

define_pd_global(bool, TrapBasedRangeChecks, false); // Not needed on z/Architecture.

// Heap related flags
define_pd_global(size_t, MetaspaceSize, ScaleForWordSize(16*M));

// Ergonomics related flags
define_pd_global(bool, NeverActAsServerClassMachine, false);

@@ -51,7 +51,6 @@ define_pd_global(bool, ProfileInterpreter, false);
define_pd_global(uintx, CodeCacheExpansionSize, 32*K );
define_pd_global(uintx, CodeCacheMinBlockLength, 1 );
define_pd_global(uintx, CodeCacheMinimumUseSpace, 400*K);
define_pd_global(size_t, MetaspaceSize, 12*M );
define_pd_global(bool, NeverActAsServerClassMachine, true );
define_pd_global(uint64_t, MaxRAM, 1ULL*G);
define_pd_global(bool, CICompileOSR, true );
@@ -91,9 +91,6 @@ define_pd_global(uintx, CodeCacheMinimumUseSpace, 400*K);

define_pd_global(bool, TrapBasedRangeChecks, false); // Not needed on x86.

// Heap related flags
define_pd_global(size_t, MetaspaceSize, ScaleForWordSize(16*M));

// Ergonomics related flags
define_pd_global(bool, NeverActAsServerClassMachine, false);

@@ -191,9 +191,6 @@ void set_client_emulation_mode_flags() {
if (FLAG_IS_DEFAULT(CodeCacheExpansionSize)) {
FLAG_SET_ERGO(CodeCacheExpansionSize, 32*K);
}
if (FLAG_IS_DEFAULT(MetaspaceSize)) {
FLAG_SET_ERGO(MetaspaceSize, MIN2(12*M, MaxMetaspaceSize));
}
if (FLAG_IS_DEFAULT(MaxRAM)) {
// Do not use FLAG_SET_ERGO to update MaxRAM, as this will impact
// heap setting done based on available phys_mem (see Arguments::set_heap_size).
@@ -444,9 +441,6 @@ void CompilerConfig::set_jvmci_specific_flags() {
if (FLAG_IS_DEFAULT(InitialCodeCacheSize)) {
FLAG_SET_DEFAULT(InitialCodeCacheSize, MAX2(16*M, InitialCodeCacheSize));
}
if (FLAG_IS_DEFAULT(MetaspaceSize)) {
FLAG_SET_DEFAULT(MetaspaceSize, MIN2(MAX2(12*M, MetaspaceSize), MaxMetaspaceSize));
}
if (FLAG_IS_DEFAULT(NewSizeThreadIncrease)) {
FLAG_SET_DEFAULT(NewSizeThreadIncrease, MAX2(4*K, NewSizeThreadIncrease));
}
@@ -70,7 +70,6 @@ define_pd_global(uintx, NonNMethodCodeHeapSize, 32*M);
define_pd_global(uintx, CodeCacheExpansionSize, 32*K);
define_pd_global(uintx, CodeCacheMinBlockLength, 1);
define_pd_global(uintx, CodeCacheMinimumUseSpace, 200*K);
define_pd_global(size_t, MetaspaceSize, ScaleForWordSize(4*M));
define_pd_global(bool, NeverActAsServerClassMachine, true);
define_pd_global(uint64_t,MaxRAM, 1ULL*G);
#define CI_COMPILER_COUNT 0
@@ -1470,7 +1470,7 @@ const intx ObjectAlignmentInBytes = 8;
"Force inlining of throwing methods smaller than this") \
range(0, max_jint) \
\
product_pd(size_t, MetaspaceSize, \
product(size_t, MetaspaceSize, NOT_LP64(16 * M) LP64_ONLY(21 * M), \
"Initial threshold (in bytes) at which a garbage collection " \
"is done to reduce Metaspace usage") \
constraint(MetaspaceSizeConstraintFunc,AfterErgo) \

0 comments on commit c9e9189

Please sign in to comment.