src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
Index
Unified diffs
Context diffs
Sdiffs
Patch
New
Old
Previous File
Next File
hotspot Cdiff src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
Print this page
rev 7211 : [mq]: remove_ngen
rev 7212 : [mq]: remove_get_gen
*** 378,388 ****
// the padded average size of the promotion for each
// young generation collection.
double CMSStats::time_until_cms_gen_full() const {
size_t cms_free = _cms_gen->cmsSpace()->free();
GenCollectedHeap* gch = GenCollectedHeap::heap();
! size_t expected_promotion = MIN2(gch->get_gen(0)->capacity(),
(size_t) _cms_gen->gc_stats()->avg_promoted()->padded_average());
if (cms_free > expected_promotion) {
// Start a cms collection if there isn't enough space to promote
// for the next minor collection. Use the padded average as
// a safety factor.
--- 378,388 ----
// the padded average size of the promotion for each
// young generation collection.
double CMSStats::time_until_cms_gen_full() const {
size_t cms_free = _cms_gen->cmsSpace()->free();
GenCollectedHeap* gch = GenCollectedHeap::heap();
! size_t expected_promotion = MIN2(gch->young_gen()->capacity(),
(size_t) _cms_gen->gc_stats()->avg_promoted()->padded_average());
if (cms_free > expected_promotion) {
// Start a cms collection if there isn't enough space to promote
// for the next minor collection. Use the padded average as
// a safety factor.
*** 706,716 ****
"CMS Thread should refer to this gen");
assert(CGC_lock != NULL, "Where's the CGC_lock?");
// Support for parallelizing young gen rescan
GenCollectedHeap* gch = GenCollectedHeap::heap();
! _young_gen = gch->prev_gen(_cmsGen);
if (gch->supports_inline_contig_alloc()) {
_top_addr = gch->top_addr();
_end_addr = gch->end_addr();
assert(_young_gen != NULL, "no _young_gen");
_eden_chunk_index = 0;
--- 706,716 ----
"CMS Thread should refer to this gen");
assert(CGC_lock != NULL, "Where's the CGC_lock?");
// Support for parallelizing young gen rescan
GenCollectedHeap* gch = GenCollectedHeap::heap();
! _young_gen = gch->young_gen();
if (gch->supports_inline_contig_alloc()) {
_top_addr = gch->top_addr();
_end_addr = gch->end_addr();
assert(_young_gen != NULL, "no _young_gen");
_eden_chunk_index = 0;
*** 953,963 ****
desired_capacity/1000);
int prev_level = level() - 1;
if (prev_level >= 0) {
size_t prev_size = 0;
GenCollectedHeap* gch = GenCollectedHeap::heap();
! Generation* prev_gen = gch->get_gen(prev_level);
prev_size = prev_gen->capacity();
gclog_or_tty->print_cr(" Younger gen size "SIZE_FORMAT,
prev_size/1000);
}
gclog_or_tty->print_cr(" unsafe_max_alloc_nogc "SIZE_FORMAT,
--- 953,963 ----
desired_capacity/1000);
int prev_level = level() - 1;
if (prev_level >= 0) {
size_t prev_size = 0;
GenCollectedHeap* gch = GenCollectedHeap::heap();
! Generation* prev_gen = gch->young_gen();
prev_size = prev_gen->capacity();
gclog_or_tty->print_cr(" Younger gen size "SIZE_FORMAT,
prev_size/1000);
}
gclog_or_tty->print_cr(" unsafe_max_alloc_nogc "SIZE_FORMAT,
*** 1124,1134 ****
return (size_t)(delta * 100.0 / (space->capacity() / HeapWordSize));
}
void CMSCollector::icms_update_allocation_limits()
{
! Generation* young = GenCollectedHeap::heap()->get_gen(0);
EdenSpace* eden = young->as_DefNewGeneration()->eden();
const unsigned int duty_cycle = stats().icms_update_duty_cycle();
if (CMSTraceIncrementalPacing) {
stats().print();
--- 1124,1134 ----
return (size_t)(delta * 100.0 / (space->capacity() / HeapWordSize));
}
void CMSCollector::icms_update_allocation_limits()
{
! Generation* young = GenCollectedHeap::heap()->young_gen();
EdenSpace* eden = young->as_DefNewGeneration()->eden();
const unsigned int duty_cycle = stats().icms_update_duty_cycle();
if (CMSTraceIncrementalPacing) {
stats().print();
*** 1265,1279 ****
if (res == NULL) {
// expand and retry
size_t s = _cmsSpace->expansionSpaceRequired(obj_size); // HeapWords
expand(s*HeapWordSize, MinHeapDeltaBytes,
CMSExpansionCause::_satisfy_promotion);
! // Since there's currently no next generation, we don't try to promote
// into a more senior generation.
- assert(next_gen() == NULL, "assumption, based upon which no attempt "
- "is made to pass on a possibly failing "
- "promotion to next generation");
res = _cmsSpace->promote(obj, obj_size);
}
if (res != NULL) {
// See comment in allocate() about when objects should
// be allocated live.
--- 1265,1276 ----
if (res == NULL) {
// expand and retry
size_t s = _cmsSpace->expansionSpaceRequired(obj_size); // HeapWords
expand(s*HeapWordSize, MinHeapDeltaBytes,
CMSExpansionCause::_satisfy_promotion);
! // Since this is the old generation, we don't try to promote
// into a more senior generation.
res = _cmsSpace->promote(obj, obj_size);
}
if (res != NULL) {
// See comment in allocate() about when objects should
// be allocated live.
src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
Index
Unified diffs
Context diffs
Sdiffs
Patch
New
Old
Previous File
Next File