void ObjArrayKlass::oop_oop_iterate_bounded(oop obj, OopClosureType* closure, MemRegion mr) { assert(obj->is_array(), "obj must be array"); objArrayOop a = objArrayOop(obj); if (Devirtualizer<nv>::do_metadata(closure)) { Devirtualizer<nv>::do_klass(closure, a->klass()); } oop_oop_iterate_elements_bounded<nv>(a, closure, mr); }
void ObjArrayKlass::oop_oop_iterate_range(oop obj, OopClosureType* closure, int start, int end) { assert(obj->is_array(), "obj must be array"); objArrayOop a = objArrayOop(obj); if (UseCompressedOops) { oop_oop_iterate_range_specialized<nv, narrowOop>(a, closure, start, end); } else { oop_oop_iterate_range_specialized<nv, oop>(a, closure, start, end); } }
int ObjArrayKlass::oop_oop_iterate(oop obj, OopClosureType* closure) { assert (obj->is_array(), "obj must be array"); objArrayOop a = objArrayOop(obj); // Get size before changing pointers. // Don't call size() or oop_size() since that is a virtual call. int size = a->object_size(); if (Devirtualizer<nv>::do_metadata(closure)) { Devirtualizer<nv>::do_klass(closure, obj->klass()); } oop_oop_iterate_elements<nv>(a, closure); return size; }
int ObjArrayKlass::oop_oop_iterate_range(oop obj, OopClosureType* closure, int start, int end) { assert(obj->is_array(), "obj must be array"); objArrayOop a = objArrayOop(obj); // Get size before changing pointers. // Don't call size() or oop_size() since that is a virtual call int size = a->object_size(); if (UseCompressedOops) { oop_oop_iterate_range_specialized<nv, narrowOop>(a, closure, start, end); } else { oop_oop_iterate_range_specialized<nv, oop>(a, closure, start, end); } return size; }
void arrayKlass::oop_verify_on(oop obj, outputStream* st) { guarantee(obj->is_array(), "must be array"); arrayOop a = arrayOop(obj); guarantee(a->length() >= 0, "array with negative length?"); }
void arrayKlass::oop_print_on(oop obj, outputStream* st) { assert(obj->is_array(), "must be array"); Klass::oop_print_on(obj, st); st->print_cr(" - length: %d", arrayOop(obj)->length()); }