# HG changeset patch # User tonyp # Date 1298649483 18000 # Node ID 8bbefb9743aee88303804950081e8c9c9664c294 # Parent a97fd181b813a5cd4c2b42a97ed1b942c35345a7# Parent 02f78cfa46560b3bee9bbf1305d8c668535b9a8e Merge diff -r a97fd181b813 -r 8bbefb9743ae src/share/vm/memory/oopFactory.cpp --- a/src/share/vm/memory/oopFactory.cpp Wed Feb 23 11:18:16 2011 -0800 +++ b/src/share/vm/memory/oopFactory.cpp Fri Feb 25 10:58:03 2011 -0500 @@ -92,21 +92,12 @@ } } -objArrayOop oopFactory::new_system_objArray(int length, bool in_perm_gen, TRAPS) { +objArrayOop oopFactory::new_system_objArray(int length, TRAPS) { int size = objArrayOopDesc::object_size(length); KlassHandle klass (THREAD, Universe::systemObjArrayKlassObj()); - oop o; - if (in_perm_gen) { - o = Universe::heap()->permanent_array_allocate(klass, size, length, CHECK_NULL); - } else { - o = Universe::heap()->array_allocate(klass, size, length, CHECK_NULL); - } + objArrayOop o = (objArrayOop) + Universe::heap()->permanent_array_allocate(klass, size, length, CHECK_NULL); // initialization not needed, allocated cleared - return (objArrayOop) o; -} - -objArrayOop oopFactory::new_system_objArray(int length, TRAPS) { - objArrayOop o = oopFactory::new_system_objArray(length, true, CHECK_NULL); return o; } diff -r a97fd181b813 -r 8bbefb9743ae src/share/vm/memory/oopFactory.hpp --- a/src/share/vm/memory/oopFactory.hpp Wed Feb 23 11:18:16 2011 -0800 +++ b/src/share/vm/memory/oopFactory.hpp Fri Feb 25 10:58:03 2011 -0500 @@ -102,7 +102,6 @@ // System object arrays static objArrayOop new_system_objArray(int length, TRAPS); - static objArrayOop new_system_objArray(int length, bool in_perm_gen, TRAPS); // Regular object arrays static objArrayOop new_objArray(klassOop klass, int length, TRAPS); diff -r a97fd181b813 -r 8bbefb9743ae src/share/vm/services/management.cpp --- a/src/share/vm/services/management.cpp Wed Feb 23 11:18:16 2011 -0800 +++ b/src/share/vm/services/management.cpp Fri Feb 25 10:58:03 2011 -0500 @@ -1311,7 +1311,7 @@ if (locked_monitors) { // Constructs Object[] and int[] to contain the object monitor and the stack depth // where the thread locked it - objArrayOop array = oopFactory::new_system_objArray(num_locked_monitors, false, CHECK_NULL); + objArrayOop array = oopFactory::new_objArray(SystemDictionary::Object_klass(), num_locked_monitors, CHECK_NULL); objArrayHandle mh(THREAD, array); monitors_array = mh; @@ -1353,7 +1353,7 @@ GrowableArray* locks = (tcl != NULL ? tcl->owned_locks() : NULL); int num_locked_synchronizers = (locks != NULL ? locks->length() : 0); - objArrayOop array = oopFactory::new_system_objArray(num_locked_synchronizers, false, CHECK_NULL); + objArrayOop array = oopFactory::new_objArray(SystemDictionary::Object_klass(), num_locked_synchronizers, CHECK_NULL); objArrayHandle sh(THREAD, array); synchronizers_array = sh;