8211446: Replace oop_pc_follow_contents with oop_iterate and closure
75 assert(_offset_of_static_fields == 0, "once");
76 _offset_of_static_fields = InstanceMirrorKlass::cast(SystemDictionary::Class_klass())->size_helper() << LogHeapWordSize
77 }
78
79 static int offset_of_static_fields() {
80 return _offset_of_static_fields;
81 }
82
83 int compute_static_oop_field_count(oop obj);
84
85 // Given a Klass return the size of the instance
86 int instance_size(Klass* k);
87
88 // allocation
89 instanceOop allocate_instance(Klass* k, TRAPS);
90
91 // GC specific object visitors
92 //
93 #if INCLUDE_PARALLELGC
94 // Parallel Compact
95 void oop_pc_follow_contents(oop obj, ParCompactionManager* cm);
96 void oop_pc_update_pointers(oop obj, ParCompactionManager* cm);
97 #endif
98
99 static void serialize_offsets(class SerializeClosure* f) NOT_CDS_RETURN;
100
101 // Oop fields (and metadata) iterators
102 //
103 // The InstanceMirrorKlass iterators also visit the hidden Klass pointer.
104
105 // Iterate over the static fields.
106 template <typename T, class OopClosureType>
107 inline void oop_oop_iterate_statics(oop obj, OopClosureType* closure);
108
109 // Forward iteration
110 // Iterate over the oop fields and metadata.
111 template <typename T, class OopClosureType>
112 inline void oop_oop_iterate(oop obj, OopClosureType* closure);
113
114 // Reverse iteration
|
75 assert(_offset_of_static_fields == 0, "once"); 76 _offset_of_static_fields = InstanceMirrorKlass::cast(SystemDictionary::Class_klass())->size_helper() << LogHeapWordSize 77 } 78 79 static int offset_of_static_fields() { 80 return _offset_of_static_fields; 81 } 82 83 int compute_static_oop_field_count(oop obj); 84 85 // Given a Klass return the size of the instance 86 int instance_size(Klass* k); 87 88 // allocation 89 instanceOop allocate_instance(Klass* k, TRAPS); 90 91 // GC specific object visitors 92 // 93 #if INCLUDE_PARALLELGC 94 // Parallel Compact 95 void oop_pc_update_pointers(oop obj, ParCompactionManager* cm); 96 #endif 97 98 static void serialize_offsets(class SerializeClosure* f) NOT_CDS_RETURN; 99 100 // Oop fields (and metadata) iterators 101 // 102 // The InstanceMirrorKlass iterators also visit the hidden Klass pointer. 103 104 // Iterate over the static fields. 105 template <typename T, class OopClosureType> 106 inline void oop_oop_iterate_statics(oop obj, OopClosureType* closure); 107 108 // Forward iteration 109 // Iterate over the oop fields and metadata. 110 template <typename T, class OopClosureType> 111 inline void oop_oop_iterate(oop obj, OopClosureType* closure); 112 113 // Reverse iteration |