< prev index next >

src/hotspot/share/opto/runtime.cpp

Print this page
rev 49244 : [mq]: event-only

@@ -198,10 +198,11 @@
   JRT_BLOCK;
 #ifndef PRODUCT
   SharedRuntime::_new_instance_ctr++;         // new instance requires GC
 #endif
   assert(check_compiled_frame(thread), "incorrect caller");
+  JvmtiSampledObjectAllocEventCollector collector;
 
   // These checks are cheap to make and support reflective allocation.
   int lh = klass->layout_helper();
   if (Klass::layout_helper_needs_slow_path(lh) || !InstanceKlass::cast(klass)->is_initialized()) {
     Handle holder(THREAD, klass->klass_holder()); // keep the klass alive

@@ -236,10 +237,11 @@
   JRT_BLOCK;
 #ifndef PRODUCT
   SharedRuntime::_new_array_ctr++;            // new array requires GC
 #endif
   assert(check_compiled_frame(thread), "incorrect caller");
+  JvmtiSampledObjectAllocEventCollector collector;
 
   // Scavenge and allocate an instance.
   oop result;
 
   if (array_type->is_typeArray_klass()) {

@@ -317,10 +319,11 @@
 
 // Note: multianewarray for one dimension is handled inline by GraphKit::new_array.
 
 // multianewarray for 2 dimensions
 JRT_ENTRY(void, OptoRuntime::multianewarray2_C(Klass* elem_type, int len1, int len2, JavaThread *thread))
+  JvmtiSampledObjectAllocEventCollector collector;
 #ifndef PRODUCT
   SharedRuntime::_multi2_ctr++;                // multianewarray for 1 dimension
 #endif
   assert(check_compiled_frame(thread), "incorrect caller");
   assert(elem_type->is_klass(), "not a class");

@@ -333,10 +336,11 @@
   thread->set_vm_result(obj);
 JRT_END
 
 // multianewarray for 3 dimensions
 JRT_ENTRY(void, OptoRuntime::multianewarray3_C(Klass* elem_type, int len1, int len2, int len3, JavaThread *thread))
+  JvmtiSampledObjectAllocEventCollector collector;
 #ifndef PRODUCT
   SharedRuntime::_multi3_ctr++;                // multianewarray for 1 dimension
 #endif
   assert(check_compiled_frame(thread), "incorrect caller");
   assert(elem_type->is_klass(), "not a class");

@@ -350,10 +354,11 @@
   thread->set_vm_result(obj);
 JRT_END
 
 // multianewarray for 4 dimensions
 JRT_ENTRY(void, OptoRuntime::multianewarray4_C(Klass* elem_type, int len1, int len2, int len3, int len4, JavaThread *thread))
+  JvmtiSampledObjectAllocEventCollector collector;
 #ifndef PRODUCT
   SharedRuntime::_multi4_ctr++;                // multianewarray for 1 dimension
 #endif
   assert(check_compiled_frame(thread), "incorrect caller");
   assert(elem_type->is_klass(), "not a class");

@@ -368,10 +373,11 @@
   thread->set_vm_result(obj);
 JRT_END
 
 // multianewarray for 5 dimensions
 JRT_ENTRY(void, OptoRuntime::multianewarray5_C(Klass* elem_type, int len1, int len2, int len3, int len4, int len5, JavaThread *thread))
+  JvmtiSampledObjectAllocEventCollector collector;
 #ifndef PRODUCT
   SharedRuntime::_multi5_ctr++;                // multianewarray for 1 dimension
 #endif
   assert(check_compiled_frame(thread), "incorrect caller");
   assert(elem_type->is_klass(), "not a class");
< prev index next >