< prev index next >

src/hotspot/share/gc/z/zCollectedHeap.cpp

Print this page

        

@@ -21,10 +21,11 @@
  * questions.
  */
 
 #include "precompiled.hpp"
 #include "gc/shared/gcHeapSummary.hpp"
+#include "gc/shared/memAllocator.hpp"
 #include "gc/shared/suspendibleThreadSet.hpp"
 #include "gc/z/zCollectedHeap.hpp"
 #include "gc/z/zGlobals.hpp"
 #include "gc/z/zHeap.inline.hpp"
 #include "gc/z/zNMethod.hpp"

@@ -114,10 +115,15 @@
 
 uint32_t ZCollectedHeap::hash_oop(oop obj) const {
   return _heap.hash_oop(obj);
 }
 
+oop ZCollectedHeap::array_allocate(Klass* klass, int size, int length, bool do_zero, TRAPS) {
+  ObjArrayAllocator allocator(klass, size, length, false /* do_zero */, THREAD);
+  return allocator.allocate();
+}
+
 HeapWord* ZCollectedHeap::allocate_new_tlab(size_t min_size, size_t requested_size, size_t* actual_size) {
   const size_t size_in_bytes = ZUtils::words_to_bytes(align_object_size(requested_size));
   const uintptr_t addr = _heap.alloc_tlab(size_in_bytes);
 
   if (addr != 0) {
< prev index next >