--- a/hotspot/src/share/vm/runtime/arguments.cpp Mon Nov 11 11:53:33 2013 -0800
+++ b/hotspot/src/share/vm/runtime/arguments.cpp Tue Nov 12 09:32:50 2013 +0100
@@ -1132,9 +1132,6 @@
Tier3InvokeNotifyFreqLog = 0;
Tier4InvocationThreshold = 0;
}
- if (FLAG_IS_DEFAULT(NmethodSweepFraction)) {
- FLAG_SET_DEFAULT(NmethodSweepFraction, 1 + ReservedCodeCacheSize / (16 * M));
- }
}
#if INCLUDE_ALL_GCS
@@ -3643,6 +3640,11 @@
"Incompatible compilation policy selected", NULL);
}
}
+ // Set NmethodSweepFraction after the size of the code cache is adapted (in case of tiered)
+ if (FLAG_IS_DEFAULT(NmethodSweepFraction)) {
+ FLAG_SET_DEFAULT(NmethodSweepFraction, 1 + ReservedCodeCacheSize / (16 * M));
+ }
+
// Set heap size based on available physical memory
set_heap_size();