< prev index next >
src/hotspot/share/opto/runtime.cpp
Print this page
*** 256,266 ****
// Although the oopFactory likes to work with the elem_type,
// the compiler prefers the array_type, since it must already have
// that latter value in hand for the fast path.
Handle holder(THREAD, array_type->klass_holder()); // keep the array klass alive
Klass* elem_type = ObjArrayKlass::cast(array_type)->element_klass();
! result = oopFactory::new_array(elem_type, len, THREAD);
}
// Pass oops back through thread local storage. Our apparent type to Java
// is that we return an oop, but we can block on exit from this routine and
// a GC can trash the oop in C's return register. The generated stub will
--- 256,266 ----
// Although the oopFactory likes to work with the elem_type,
// the compiler prefers the array_type, since it must already have
// that latter value in hand for the fast path.
Handle holder(THREAD, array_type->klass_holder()); // keep the array klass alive
Klass* elem_type = ObjArrayKlass::cast(array_type)->element_klass();
! result = ObjArrayKlass::cast(array_type)->allocate(len, THREAD);
}
// Pass oops back through thread local storage. Our apparent type to Java
// is that we return an oop, but we can block on exit from this routine and
// a GC can trash the oop in C's return register. The generated stub will
< prev index next >