< prev index next >
hotspot/src/share/vm/gc_implementation/g1/g1CollectorPolicy.cpp
Print this page
rev 6911 : 8065305: Make it possible to extend the G1CollectorPolicy
Summary: Added a G1CollectorPolicyExt where it is possible to extend the class.
Reviewed-by: sjohanss, tschatzl
*** 1423,1432 ****
--- 1423,1444 ----
_short_lived_surv_rate_group->print_surv_rate_summary();
// add this call for any other surv rate groups
#endif // PRODUCT
}
+ bool G1CollectorPolicy::is_young_list_full() {
+ uint young_list_length = _g1->young_list()->length();
+ uint young_list_target_length = _young_list_target_length;
+ return young_list_length >= young_list_target_length;
+ }
+
+ bool G1CollectorPolicy::can_expand_young_list() {
+ uint young_list_length = _g1->young_list()->length();
+ uint young_list_max_length = _young_list_max_length;
+ return young_list_length < young_list_max_length;
+ }
+
uint G1CollectorPolicy::max_regions(int purpose) {
switch (purpose) {
case GCAllocForSurvived:
return _max_survivor_regions;
case GCAllocForTenured:
< prev index next >