本文整理汇总了C++中PSYoungGen类的典型用法代码示例。如果您正苦于以下问题:C++ PSYoungGen类的具体用法?C++ PSYoungGen怎么用?C++ PSYoungGen使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了PSYoungGen类的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: old_gen
PSHeapSummary ParallelScavengeHeap::create_ps_heap_summary() {
PSOldGen* old = old_gen();
HeapWord* old_committed_end = (HeapWord*)old->virtual_space()->committed_high_addr();
VirtualSpaceSummary old_summary(old->reserved().start(), old_committed_end, old->reserved().end());
SpaceSummary old_space(old->reserved().start(), old_committed_end, old->used_in_bytes());
PSYoungGen* young = young_gen();
VirtualSpaceSummary young_summary(young->reserved().start(),
(HeapWord*)young->virtual_space()->committed_high_addr(), young->reserved().end());
MutableSpace* eden = young_gen()->eden_space();
SpaceSummary eden_space(eden->bottom(), eden->end(), eden->used_in_bytes());
MutableSpace* from = young_gen()->from_space();
SpaceSummary from_space(from->bottom(), from->end(), from->used_in_bytes());
MutableSpace* to = young_gen()->to_space();
SpaceSummary to_space(to->bottom(), to->end(), to->used_in_bytes());
VirtualSpaceSummary heap_summary = create_heap_space_summary();
return PSHeapSummary(heap_summary, used(), old_summary, old_space, young_summary, eden_space, from_space, to_space);
}
示例2: assert
template <class T> void do_oop_work(T* p) {
oop obj = oopDesc::load_decode_heap_oop_not_null(p);
if (_young_gen->is_in_reserved(obj)) {
assert(_card_table->addr_is_marked_precise(p), "Found unmarked precise oop");
_card_table->set_card_newgen(p);
}
}
示例3:
template <class T> void do_oop_work(T* p) {
oop obj = oopDesc::load_decode_heap_oop(p);
if (_young_gen->is_in_reserved(obj) &&
!_card_table->addr_is_marked_imprecise(p)) {
// Don't overwrite the first missing card mark
if (_unmarked_addr == NULL) {
_unmarked_addr = (HeapWord*)p;
}
}
}
示例4: max_size
size_t max_size() const {
// Return current committed size of the from-space
return _gen->from_space()->capacity_in_bytes();
}
示例5: committed_in_bytes
size_t committed_in_bytes() {
return _gen->from_space()->capacity_in_bytes();
}
示例6: used_in_bytes
size_t used_in_bytes() {
return _gen->from_space()->used_in_bytes();
}