663 // case there can be live objects in to-space
664 // as a result of a partial evacuation of eden
665 // and from-space.
666 swap_spaces(); // For uniformity wrt ParNewGeneration.
667 from()->set_next_compaction_space(to());
668 heap->set_incremental_collection_failed();
669
670 // Inform the next generation that a promotion failure occurred.
671 _old_gen->promotion_failure_occurred();
672 gc_tracer.report_promotion_failed(_promotion_failed_info);
673
674 // Reset the PromotionFailureALot counters.
675 NOT_PRODUCT(heap->reset_promotion_should_fail();)
676 }
677 // We should have processed and cleared all the preserved marks.
678 _preserved_marks_set.reclaim();
679 // set new iteration safe limit for the survivor spaces
680 from()->set_concurrent_iteration_safe_limit(from()->top());
681 to()->set_concurrent_iteration_safe_limit(to()->top());
682
683 // We need to use a monotonically non-decreasing time in ms
684 // or we will see time-warp warnings and os::javaTimeMillis()
685 // does not guarantee monotonicity.
686 jlong now = os::javaTimeNanos() / NANOSECS_PER_MILLISEC;
687 update_time_of_last_gc(now);
688
689 heap->trace_heap_after_gc(&gc_tracer);
690
691 _gc_timer->register_gc_end();
692
693 gc_tracer.report_gc_end(_gc_timer->gc_end(), _gc_timer->time_partitions());
694 }
695
696 void DefNewGeneration::init_assuming_no_promotion_failure() {
697 _promotion_failed = false;
698 _promotion_failed_info.reset();
699 from()->set_next_compaction_space(NULL);
700 }
701
702 void DefNewGeneration::remove_forwarding_pointers() {
703 RemoveForwardedPointerClosure rspc;
704 eden()->object_iterate(&rspc);
705 from()->object_iterate(&rspc);
706 restore_preserved_marks();
707 }
708
|
663 // case there can be live objects in to-space
664 // as a result of a partial evacuation of eden
665 // and from-space.
666 swap_spaces(); // For uniformity wrt ParNewGeneration.
667 from()->set_next_compaction_space(to());
668 heap->set_incremental_collection_failed();
669
670 // Inform the next generation that a promotion failure occurred.
671 _old_gen->promotion_failure_occurred();
672 gc_tracer.report_promotion_failed(_promotion_failed_info);
673
674 // Reset the PromotionFailureALot counters.
675 NOT_PRODUCT(heap->reset_promotion_should_fail();)
676 }
677 // We should have processed and cleared all the preserved marks.
678 _preserved_marks_set.reclaim();
679 // set new iteration safe limit for the survivor spaces
680 from()->set_concurrent_iteration_safe_limit(from()->top());
681 to()->set_concurrent_iteration_safe_limit(to()->top());
682
683 heap->trace_heap_after_gc(&gc_tracer);
684
685 _gc_timer->register_gc_end();
686
687 gc_tracer.report_gc_end(_gc_timer->gc_end(), _gc_timer->time_partitions());
688 }
689
690 void DefNewGeneration::init_assuming_no_promotion_failure() {
691 _promotion_failed = false;
692 _promotion_failed_info.reset();
693 from()->set_next_compaction_space(NULL);
694 }
695
696 void DefNewGeneration::remove_forwarding_pointers() {
697 RemoveForwardedPointerClosure rspc;
698 eden()->object_iterate(&rspc);
699 from()->object_iterate(&rspc);
700 restore_preserved_marks();
701 }
702
|