1109 } 1110 } 1111 1112 void Arguments::set_tiered_flags() { 1113 // With tiered, set default policy to AdvancedThresholdPolicy, which is 3. 1114 if (FLAG_IS_DEFAULT(CompilationPolicyChoice)) { 1115 FLAG_SET_DEFAULT(CompilationPolicyChoice, 3); 1116 } 1117 if (CompilationPolicyChoice < 2) { 1118 vm_exit_during_initialization( 1119 "Incompatible compilation policy selected", NULL); 1120 } 1121 // Increase the code cache size - tiered compiles a lot more. 1122 if (FLAG_IS_DEFAULT(ReservedCodeCacheSize)) { 1123 FLAG_SET_DEFAULT(ReservedCodeCacheSize, ReservedCodeCacheSize * 5); 1124 } 1125 if (!UseInterpreter) { // -Xcomp 1126 Tier3InvokeNotifyFreqLog = 0; 1127 Tier4InvocationThreshold = 0; 1128 } 1129 } 1130 1131 #if INCLUDE_ALL_GCS 1132 static void disable_adaptive_size_policy(const char* collector_name) { 1133 if (UseAdaptiveSizePolicy) { 1134 if (FLAG_IS_CMDLINE(UseAdaptiveSizePolicy)) { 1135 warning("disabling UseAdaptiveSizePolicy; it is incompatible with %s.", 1136 collector_name); 1137 } 1138 FLAG_SET_DEFAULT(UseAdaptiveSizePolicy, false); 1139 } 1140 } 1141 1142 void Arguments::set_parnew_gc_flags() { 1143 assert(!UseSerialGC && !UseParallelOldGC && !UseParallelGC && !UseG1GC, 1144 "control point invariant"); 1145 assert(UseParNewGC, "Error"); 1146 1147 // Turn off AdaptiveSizePolicy for parnew until it is complete. 1148 disable_adaptive_size_policy("UseParNewGC"); | 1109 } 1110 } 1111 1112 void Arguments::set_tiered_flags() { 1113 // With tiered, set default policy to AdvancedThresholdPolicy, which is 3. 1114 if (FLAG_IS_DEFAULT(CompilationPolicyChoice)) { 1115 FLAG_SET_DEFAULT(CompilationPolicyChoice, 3); 1116 } 1117 if (CompilationPolicyChoice < 2) { 1118 vm_exit_during_initialization( 1119 "Incompatible compilation policy selected", NULL); 1120 } 1121 // Increase the code cache size - tiered compiles a lot more. 1122 if (FLAG_IS_DEFAULT(ReservedCodeCacheSize)) { 1123 FLAG_SET_DEFAULT(ReservedCodeCacheSize, ReservedCodeCacheSize * 5); 1124 } 1125 if (!UseInterpreter) { // -Xcomp 1126 Tier3InvokeNotifyFreqLog = 0; 1127 Tier4InvocationThreshold = 0; 1128 } 1129 if (FLAG_IS_DEFAULT(NmethodSweepFraction)) { 1130 FLAG_SET_DEFAULT(NmethodSweepFraction, 1 + ReservedCodeCacheSize / (16 * M)); 1131 } 1132 } 1133 1134 #if INCLUDE_ALL_GCS 1135 static void disable_adaptive_size_policy(const char* collector_name) { 1136 if (UseAdaptiveSizePolicy) { 1137 if (FLAG_IS_CMDLINE(UseAdaptiveSizePolicy)) { 1138 warning("disabling UseAdaptiveSizePolicy; it is incompatible with %s.", 1139 collector_name); 1140 } 1141 FLAG_SET_DEFAULT(UseAdaptiveSizePolicy, false); 1142 } 1143 } 1144 1145 void Arguments::set_parnew_gc_flags() { 1146 assert(!UseSerialGC && !UseParallelOldGC && !UseParallelGC && !UseG1GC, 1147 "control point invariant"); 1148 assert(UseParNewGC, "Error"); 1149 1150 // Turn off AdaptiveSizePolicy for parnew until it is complete. 1151 disable_adaptive_size_policy("UseParNewGC"); |