--- old/src/share/vm/classfile/classLoader.cpp 2017-07-05 18:47:38.983965570 +0200 +++ new/src/share/vm/classfile/classLoader.cpp 2017-07-05 18:47:38.887965574 +0200 @@ -1873,6 +1873,11 @@ return false; } + // Don't compile methods in __Value if value types are disabled + if (!EnableMVT && !EnableValhalla && m->method_holder()->name() == vmSymbols::java_lang____Value()) { + return false; + } + return CompilationPolicy::can_be_compiled(m, comp_level); } --- old/src/share/vm/runtime/arguments.cpp 2017-07-05 18:47:39.323965554 +0200 +++ new/src/share/vm/runtime/arguments.cpp 2017-07-05 18:47:39.223965559 +0200 @@ -2537,14 +2537,6 @@ "Conflicting combination in option list: EnableMVT and EnableValhalla cannot be both enabled at the same time"); } - if (!EnableMVT && CompileTheWorld) { - if (!FLAG_IS_DEFAULT(EnableMVT)) { - warning("EnableMVT enabled due to CompileTheWorld."); - } - // We need to enable MVT because CompileTheWorld may process java.lang.__Value - FLAG_SET_CMDLINE(bool, EnableMVT, true); - } - return status; }