--- a/src/hotspot/share/gc/parallel/psParallelCompact.cpp Fri Oct 12 12:13:06 2018 +0200
+++ b/src/hotspot/share/gc/parallel/psParallelCompact.cpp Fri Oct 12 12:14:01 2018 +0200
@@ -2203,7 +2203,7 @@
// Need new claim bits when tracing through and adjusting pointers.
ClassLoaderDataGraph::clear_claimed_marks();
- PSParallelCompact::AdjustPointerClosure oop_closure(cm);
+ PCAdjustPointerClosure oop_closure(cm);
// General strong roots.
Universe::oops_do(&oop_closure);
@@ -3096,76 +3096,6 @@
update_state(words);
}
-void InstanceKlass::oop_pc_update_pointers(oop obj, ParCompactionManager* cm) {
- PSParallelCompact::AdjustPointerClosure closure(cm);
- if (UseCompressedOops) {
- oop_oop_iterate_oop_maps<narrowOop>(obj, &closure);
- } else {
- oop_oop_iterate_oop_maps<oop>(obj, &closure);
- }
-}
-
-void InstanceMirrorKlass::oop_pc_update_pointers(oop obj, ParCompactionManager* cm) {
- InstanceKlass::oop_pc_update_pointers(obj, cm);
-
- PSParallelCompact::AdjustPointerClosure closure(cm);
- if (UseCompressedOops) {
- oop_oop_iterate_statics<narrowOop>(obj, &closure);
- } else {
- oop_oop_iterate_statics<oop>(obj, &closure);
- }
-}
-
-void InstanceClassLoaderKlass::oop_pc_update_pointers(oop obj, ParCompactionManager* cm) {
- InstanceKlass::oop_pc_update_pointers(obj, cm);
-}
-
-#ifdef ASSERT
-template <class T> static void trace_reference_gc(const char *s, oop obj,
- T* referent_addr,
- T* discovered_addr) {
- log_develop_trace(gc, ref)("%s obj " PTR_FORMAT, s, p2i(obj));
- log_develop_trace(gc, ref)(" referent_addr/* " PTR_FORMAT " / " PTR_FORMAT,
- p2i(referent_addr), referent_addr ? p2i((oop)RawAccess<>::oop_load(referent_addr)) : NULL);
- log_develop_trace(gc, ref)(" discovered_addr/* " PTR_FORMAT " / " PTR_FORMAT,
- p2i(discovered_addr), discovered_addr ? p2i((oop)RawAccess<>::oop_load(discovered_addr)) : NULL);
-}
-#endif
-
-template <class T>
-static void oop_pc_update_pointers_specialized(oop obj, ParCompactionManager* cm) {
- T* referent_addr = (T*)java_lang_ref_Reference::referent_addr_raw(obj);
- PSParallelCompact::adjust_pointer(referent_addr, cm);
- T* discovered_addr = (T*)java_lang_ref_Reference::discovered_addr_raw(obj);
- PSParallelCompact::adjust_pointer(discovered_addr, cm);
- debug_only(trace_reference_gc("InstanceRefKlass::oop_update_ptrs", obj,
- referent_addr, discovered_addr);)
-}
-
-void InstanceRefKlass::oop_pc_update_pointers(oop obj, ParCompactionManager* cm) {
- InstanceKlass::oop_pc_update_pointers(obj, cm);
-
- if (UseCompressedOops) {
- oop_pc_update_pointers_specialized<narrowOop>(obj, cm);
- } else {
- oop_pc_update_pointers_specialized<oop>(obj, cm);
- }
-}
-
-void ObjArrayKlass::oop_pc_update_pointers(oop obj, ParCompactionManager* cm) {
- assert(obj->is_objArray(), "obj must be obj array");
- PSParallelCompact::AdjustPointerClosure closure(cm);
- if (UseCompressedOops) {
- oop_oop_iterate_elements<narrowOop>(objArrayOop(obj), &closure);
- } else {
- oop_oop_iterate_elements<oop>(objArrayOop(obj), &closure);
- }
-}
-
-void TypeArrayKlass::oop_pc_update_pointers(oop obj, ParCompactionManager* cm) {
- assert(obj->is_typeArray(),"must be a type array");
-}
-
ParMarkBitMapClosure::IterationStatus
MoveAndUpdateClosure::do_addr(HeapWord* addr, size_t words) {
assert(destination() != NULL, "sanity");