void GCTracer::report_object_count_after_gc(BoolObjectClosure *is_alive_cl) { if (should_send_object_count_after_gc_event()) { ResourceMark rm; KlassInfoTable cit(HeapInspection::start_of_perm_gen()); if (!cit.allocation_failed()) { ObjectCountEventSenderClosure event_sender(this); HeapInspection::instance_inspection(&cit, &event_sender, false, is_alive_cl); } } }
void GCTracer::report_object_count_after_gc(BoolObjectClosure* is_alive_cl) { assert_set_gc_id(); assert(is_alive_cl != NULL, "Must supply function to check liveness"); if (ObjectCountEventSender::should_send_event()) { ResourceMark rm; KlassInfoTable cit(false); if (!cit.allocation_failed()) { HeapInspection hi(false, false, false, NULL); hi.populate_table(&cit, is_alive_cl); jlong timestamp = os::elapsed_counter(); ObjectCountEventSenderClosure event_sender(_shared_gc_info.id(), cit.size_of_instances_in_words(), timestamp); cit.iterate(&event_sender); } } }