OpenJDK / jdk / jdk
changeset 47572:552a97e8edad
8185062: Set AssumeMP to true and deprecate the flag
Reviewed-by: shade, dcubed, kvn
author | dholmes |
---|---|
date | Mon, 02 Oct 2017 18:56:30 -0400 |
parents | c19054f06c14 |
children | 7e6ef8418220 15294343ba19 |
files | src/hotspot/share/runtime/arguments.cpp src/hotspot/share/runtime/globals.hpp src/hotspot/share/runtime/os.hpp test/hotspot/jtreg/runtime/CommandLine/VMDeprecatedOptions.java |
diffstat | 4 files changed, 5 insertions(+), 13 deletions(-) [+] |
line wrap: on
line diff
--- a/src/hotspot/share/runtime/arguments.cpp Mon Oct 02 17:20:14 2017 +0300 +++ b/src/hotspot/share/runtime/arguments.cpp Mon Oct 02 18:56:30 2017 -0400 @@ -377,6 +377,7 @@ // --- 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 @@ 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;
--- a/src/hotspot/share/runtime/globals.hpp Mon Oct 02 17:20:14 2017 +0300 +++ b/src/hotspot/share/runtime/globals.hpp Mon Oct 02 18:56:30 2017 -0400 @@ -592,8 +592,8 @@ 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 */ \
--- a/src/hotspot/share/runtime/os.hpp Mon Oct 02 17:20:14 2017 +0300 +++ b/src/hotspot/share/runtime/os.hpp Mon Oct 02 18:56:30 2017 -0400 @@ -213,7 +213,7 @@ // 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();
--- a/test/hotspot/jtreg/runtime/CommandLine/VMDeprecatedOptions.java Mon Oct 02 17:20:14 2017 +0300 +++ b/test/hotspot/jtreg/runtime/CommandLine/VMDeprecatedOptions.java Mon Oct 02 18:56:30 2017 -0400 @@ -46,6 +46,7 @@ {"MaxRAMFraction", "8"}, {"MinRAMFraction", "2"}, {"InitialRAMFraction", "64"}, + {"AssumeMP", "false"}, // deprecated alias flags (see also aliased_jvm_flags): {"DefaultMaxRAMFraction", "4"},