8185062: Set AssumeMP to true and deprecate the flag

Reviewed-by: shade, dcubed, kvn
This commit is contained in:
David Holmes 2017-10-02 18:56:30 -04:00
parent b787f1b55b
commit fd93a04684
4 changed files with 5 additions and 13 deletions
src/hotspot/share/runtime
test/hotspot/jtreg/runtime/CommandLine

@ -377,6 +377,7 @@ static SpecialFlag const special_jvm_flags[] = {
// --- Non-alias flags - sorted by obsolete_in then expired_in:
{ "MaxGCMinorPauseMillis", JDK_Version::jdk(8), JDK_Version::undefined(), JDK_Version::undefined() },
{ "UseConcMarkSweepGC", JDK_Version::jdk(9), JDK_Version::undefined(), JDK_Version::undefined() },
{ "AssumeMP", JDK_Version::jdk(10),JDK_Version::undefined(), JDK_Version::undefined() },
{ "MonitorInUseLists", JDK_Version::jdk(10),JDK_Version::undefined(), JDK_Version::undefined() },
{ "MaxRAMFraction", JDK_Version::jdk(10), JDK_Version::undefined(), JDK_Version::undefined() },
{ "MinRAMFraction", JDK_Version::jdk(10), JDK_Version::undefined(), JDK_Version::undefined() },
@ -4476,16 +4477,6 @@ jint Arguments::apply_ergo() {
set_shared_spaces_flags();
#if defined(SPARC)
// BIS instructions require 'membar' instruction regardless of the number
// of CPUs because in virtualized/container environments which might use only 1
// CPU, BIS instructions may produce incorrect results.
if (FLAG_IS_DEFAULT(AssumeMP)) {
FLAG_SET_DEFAULT(AssumeMP, true);
}
#endif
// Check the GC selections again.
if (!check_gc_consistency()) {
return JNI_EINVAL;

@ -592,8 +592,8 @@ public:
range(8, 256) \
constraint(ObjectAlignmentInBytesConstraintFunc,AtParse) \
\
product(bool, AssumeMP, false, \
"Instruct the VM to assume multiple processors are available") \
product(bool, AssumeMP, true, \
"(Deprecated) Instruct the VM to assume multiple processors are available")\
\
/* UseMembar is theoretically a temp flag used for memory barrier */ \
/* removal testing. It was supposed to be removed before FCS but has */ \

@ -213,7 +213,7 @@ class os: AllStatic {
// the bootstrap routine for the stub generator needs to check
// the processor count directly and leave the bootstrap routine
// in place until called after initialization has ocurred.
return (_processor_count != 1) || AssumeMP;
return AssumeMP || (_processor_count != 1);
}
static julong available_memory();
static julong physical_memory();

@ -46,6 +46,7 @@ public class VMDeprecatedOptions {
{"MaxRAMFraction", "8"},
{"MinRAMFraction", "2"},
{"InitialRAMFraction", "64"},
{"AssumeMP", "false"},
// deprecated alias flags (see also aliased_jvm_flags):
{"DefaultMaxRAMFraction", "4"},