8027643: Merge GenCollectorPolicy and TwoGenerationCollectorPolicy

Merged the two calsses GenCollectorPolicy and TwoGenerationCollectorPolicy

Reviewed-by: sjohanss, jcoomes
This commit is contained in:
Jesper Wilhelmsson 2014-04-29 22:57:19 +02:00
parent 9968a23667
commit 0346ae4c9d
9 changed files with 37 additions and 84 deletions

View file

@ -1560,7 +1560,7 @@ bool CMSCollector::shouldConcurrentCollect() {
// this is not likely to be productive in practice because it's probably too
// late anyway.
GenCollectedHeap* gch = GenCollectedHeap::heap();
assert(gch->collector_policy()->is_two_generation_policy(),
assert(gch->collector_policy()->is_generation_policy(),
"You may want to check the correctness of the following");
if (gch->incremental_collection_will_fail(true /* consult_young */)) {
if (Verbose && PrintGCDetails) {
@ -1964,7 +1964,7 @@ void CMSCollector::decide_foreground_collection_type(
// has exceeded the threshold set by CMSFullGCsBeforeCompaction,
// or if an incremental collection has failed
GenCollectedHeap* gch = GenCollectedHeap::heap();
assert(gch->collector_policy()->is_two_generation_policy(),
assert(gch->collector_policy()->is_generation_policy(),
"You may want to check the correctness of the following");
// Inform cms gen if this was due to partial collection failing.
// The CMS gen may use this fact to determine its expansion policy.