mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-26 22:34:27 +02:00
8075957: Reduce calls to the GC specific object visitors in oopDesc
Reviewed-by: brutisso, mgerdin, pliden
This commit is contained in:
parent
602b7d79e9
commit
ba1d121fe0
26 changed files with 82 additions and 76 deletions
|
@ -1025,9 +1025,6 @@ class PSParallelCompact : AllStatic {
|
|||
bool maximum_heap_compaction,
|
||||
ParallelOldTracer *gc_tracer);
|
||||
|
||||
template <class T>
|
||||
static inline void follow_root(ParCompactionManager* cm, T* p);
|
||||
|
||||
// Compute the dense prefix for the designated space. This is an experimental
|
||||
// implementation currently not used in production.
|
||||
static HeapWord* compute_dense_prefix_via_density(const SpaceId id,
|
||||
|
@ -1335,23 +1332,6 @@ inline bool PSParallelCompact::is_marked(oop obj) {
|
|||
return mark_bitmap()->is_marked(obj);
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline void PSParallelCompact::follow_root(ParCompactionManager* cm, T* p) {
|
||||
assert(!Universe::heap()->is_in_reserved(p),
|
||||
"roots shouldn't be things within the heap");
|
||||
|
||||
T heap_oop = oopDesc::load_heap_oop(p);
|
||||
if (!oopDesc::is_null(heap_oop)) {
|
||||
oop obj = oopDesc::decode_heap_oop_not_null(heap_oop);
|
||||
if (mark_bitmap()->is_unmarked(obj)) {
|
||||
if (mark_obj(obj)) {
|
||||
obj->follow_contents(cm);
|
||||
}
|
||||
}
|
||||
}
|
||||
cm->follow_marking_stacks();
|
||||
}
|
||||
|
||||
template <class T>
|
||||
inline void PSParallelCompact::mark_and_push(ParCompactionManager* cm, T* p) {
|
||||
T heap_oop = oopDesc::load_heap_oop(p);
|
||||
|
@ -1524,12 +1504,6 @@ class UpdateOnlyClosure: public ParMarkBitMapClosure {
|
|||
inline void do_addr(HeapWord* addr);
|
||||
};
|
||||
|
||||
inline void UpdateOnlyClosure::do_addr(HeapWord* addr)
|
||||
{
|
||||
_start_array->allocate_block(addr);
|
||||
oop(addr)->update_contents(compaction_manager());
|
||||
}
|
||||
|
||||
class FillClosure: public ParMarkBitMapClosure
|
||||
{
|
||||
public:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue