6578152: fill_region_with_object has usability and safety issues

Reviewed-by: apetrusenko, ysr
This commit is contained in:
John Coomes 2008-12-11 12:05:08 -08:00
parent 26f6b1692a
commit 000b184507
25 changed files with 261 additions and 198 deletions

View file

@ -34,7 +34,6 @@ void CollectedHeap::post_allocation_setup_common(KlassHandle klass,
void CollectedHeap::post_allocation_setup_no_klass_install(KlassHandle klass,
HeapWord* objPtr,
size_t size) {
oop obj = (oop)objPtr;
assert(obj != NULL, "NULL object pointer");
@ -44,9 +43,6 @@ void CollectedHeap::post_allocation_setup_no_klass_install(KlassHandle klass,
// May be bootstrapping
obj->set_mark(markOopDesc::prototype());
}
// support low memory notifications (no-op if not enabled)
LowMemoryDetector::detect_low_memory_for_collected_pools();
}
void CollectedHeap::post_allocation_install_obj_klass(KlassHandle klass,
@ -65,6 +61,9 @@ void CollectedHeap::post_allocation_install_obj_klass(KlassHandle klass,
// Support for jvmti and dtrace
inline void post_allocation_notify(KlassHandle klass, oop obj) {
// support low memory notifications (no-op if not enabled)
LowMemoryDetector::detect_low_memory_for_collected_pools();
// support for JVMTI VMObjectAlloc event (no-op if not enabled)
JvmtiExport::vm_object_alloc_event_collector(obj);