--- old/src/share/vm/runtime/simpleThresholdPolicy.cpp 2013-10-21 11:47:07.855829164 +0200 +++ new/src/share/vm/runtime/simpleThresholdPolicy.cpp 2013-10-21 11:47:07.791829165 +0200 @@ -134,15 +134,19 @@ } void SimpleThresholdPolicy::initialize() { - if (FLAG_IS_DEFAULT(CICompilerCount)) { - FLAG_SET_DEFAULT(CICompilerCount, 3); + // No need to set number of compiler threads if the VM is started with -Xint + assert ((c1_count() == 0) && (c2_count() == 0), "Must be initialized to 0"); + if (Arguments::mode() != Arguments::_int) { + if (FLAG_IS_DEFAULT(CICompilerCount)) { + FLAG_SET_DEFAULT(CICompilerCount, 3); + } + int count = CICompilerCount; + if (CICompilerCountPerCPU) { + count = MAX2(log2_intptr(os::active_processor_count()), 1) * 3 / 2; + } + set_c1_count(MAX2(count / 3, 1)); + set_c2_count(MAX2(count - count / 3, 1)); } - int count = CICompilerCount; - if (CICompilerCountPerCPU) { - count = MAX2(log2_intptr(os::active_processor_count()), 1) * 3 / 2; - } - set_c1_count(MAX2(count / 3, 1)); - set_c2_count(MAX2(count - count / 3, 1)); } void SimpleThresholdPolicy::set_carry_if_necessary(InvocationCounter *counter) {