< prev index next >
src/share/vm/gc_implementation/concurrentMarkSweep/concurrentMarkSweepGeneration.cpp
Print this page
rev 8070 : imported patch gencollected_heap_cleanup
*** 297,308 ****
}
}
AdaptiveSizePolicy* CMSCollector::size_policy() {
GenCollectedHeap* gch = GenCollectedHeap::heap();
- assert(gch->kind() == CollectedHeap::GenCollectedHeap,
- "Wrong type of heap");
return gch->gen_policy()->size_policy();
}
void ConcurrentMarkSweepGeneration::initialize_performance_counters() {
--- 297,306 ----
*** 979,989 ****
// allocate, copy and if necessary update promoinfo --
// delegate to underlying space.
assert_lock_strong(freelistLock());
#ifndef PRODUCT
! if (Universe::heap()->promotion_should_fail()) {
return NULL;
}
#endif // #ifndef PRODUCT
oop res = _cmsSpace->promote(obj, obj_size);
--- 977,987 ----
// allocate, copy and if necessary update promoinfo --
// delegate to underlying space.
assert_lock_strong(freelistLock());
#ifndef PRODUCT
! if (GenCollectedHeap::heap()->promotion_should_fail()) {
return NULL;
}
#endif // #ifndef PRODUCT
oop res = _cmsSpace->promote(obj, obj_size);
*** 1056,1066 ****
oop
ConcurrentMarkSweepGeneration::par_promote(int thread_num,
oop old, markOop m,
size_t word_sz) {
#ifndef PRODUCT
! if (Universe::heap()->promotion_should_fail()) {
return NULL;
}
#endif // #ifndef PRODUCT
CMSParGCThreadState* ps = _par_gc_thread_states[thread_num];
--- 1054,1064 ----
oop
ConcurrentMarkSweepGeneration::par_promote(int thread_num,
oop old, markOop m,
size_t word_sz) {
#ifndef PRODUCT
! if (GenCollectedHeap::heap()->promotion_should_fail()) {
return NULL;
}
#endif // #ifndef PRODUCT
CMSParGCThreadState* ps = _par_gc_thread_states[thread_num];
*** 2466,2476 ****
// errors by printing corresponding objects.
VerifyMarkedClosure vcl(markBitMap());
verification_mark_bm()->iterate(&vcl);
if (vcl.failed()) {
gclog_or_tty->print("Verification failed");
! Universe::heap()->print_on(gclog_or_tty);
fatal("CMS: failed marking verification after remark");
}
}
class VerifyKlassOopsKlassClosure : public KlassClosure {
--- 2464,2474 ----
// errors by printing corresponding objects.
VerifyMarkedClosure vcl(markBitMap());
verification_mark_bm()->iterate(&vcl);
if (vcl.failed()) {
gclog_or_tty->print("Verification failed");
! gch->print_on(gclog_or_tty);
fatal("CMS: failed marking verification after remark");
}
}
class VerifyKlassOopsKlassClosure : public KlassClosure {
< prev index next >