diff --git a/src/hotspot/share/compiler/compilationPolicy.cpp b/src/hotspot/share/compiler/compilationPolicy.cpp index bab437eaade14..99b7e1bb6fd01 100644 --- a/src/hotspot/share/compiler/compilationPolicy.cpp +++ b/src/hotspot/share/compiler/compilationPolicy.cpp @@ -385,7 +385,7 @@ class CallPredicate : AllStatic { double CompilationPolicy::threshold_scale(CompLevel level, int feedback_k) { int comp_count = compiler_count(level); - if (comp_count > 0) { + if (comp_count > 0 && feedback_k > 0) { double queue_size = CompileBroker::queue_size(level); double k = (double)queue_size / ((double)feedback_k * (double)comp_count) + 1; diff --git a/src/hotspot/share/compiler/compiler_globals.hpp b/src/hotspot/share/compiler/compiler_globals.hpp index 3c47b991120dd..605c0c58869df 100644 --- a/src/hotspot/share/compiler/compiler_globals.hpp +++ b/src/hotspot/share/compiler/compiler_globals.hpp @@ -234,12 +234,14 @@ \ product(intx, Tier3LoadFeedback, 5, \ "Tier 3 thresholds will increase twofold when C1 queue size " \ - "reaches this amount per compiler thread") \ + "reaches this amount per compiler thread" \ + "Passing 0 disables the threshold scaling") \ range(0, max_jint) \ \ product(intx, Tier4LoadFeedback, 3, \ "Tier 4 thresholds will increase twofold when C2 queue size " \ - "reaches this amount per compiler thread") \ + "reaches this amount per compiler thread" \ + "Passing 0 disables the threshold scaling") \ range(0, max_jint) \ \ product(intx, TieredCompileTaskTimeout, 50, \ @@ -263,11 +265,11 @@ \ product(intx, TieredRateUpdateMinTime, 1, \ "Minimum rate sampling interval (in milliseconds)") \ - range(0, max_intx) \ + range(1, max_intx) \ \ product(intx, TieredRateUpdateMaxTime, 25, \ "Maximum rate sampling interval (in milliseconds)") \ - range(0, max_intx) \ + range(1, max_intx) \ \ product(double, Tier0ProfileDelayFactor, 100.0, DIAGNOSTIC, \ "Delay profiling/compiling of methods that were " \