944 /** |
944 /** |
945 * This function ought to be a void function, but cannot be because |
945 * This function ought to be a void function, but cannot be because |
946 * it gets turned into a tail-call on sparc, which runs into dtrace bug |
946 * it gets turned into a tail-call on sparc, which runs into dtrace bug |
947 * 6254741. Once that is fixed we can remove the dummy return value. |
947 * 6254741. Once that is fixed we can remove the dummy return value. |
948 */ |
948 */ |
949 int SharedRuntime::dtrace_object_alloc(oopDesc* o) { |
949 int SharedRuntime::dtrace_object_alloc(oopDesc* o, int size) { |
950 return dtrace_object_alloc_base(Thread::current(), o); |
950 return dtrace_object_alloc_base(Thread::current(), o, size); |
951 } |
951 } |
952 |
952 |
953 int SharedRuntime::dtrace_object_alloc_base(Thread* thread, oopDesc* o) { |
953 int SharedRuntime::dtrace_object_alloc_base(Thread* thread, oopDesc* o, int size) { |
954 assert(DTraceAllocProbes, "wrong call"); |
954 assert(DTraceAllocProbes, "wrong call"); |
955 Klass* klass = o->klass(); |
955 Klass* klass = o->klass(); |
956 int size = o->size(); |
|
957 Symbol* name = klass->name(); |
956 Symbol* name = klass->name(); |
958 HOTSPOT_OBJECT_ALLOC( |
957 HOTSPOT_OBJECT_ALLOC( |
959 get_java_tid(thread), |
958 get_java_tid(thread), |
960 (char *) name->bytes(), name->utf8_length(), size * HeapWordSize); |
959 (char *) name->bytes(), name->utf8_length(), size * HeapWordSize); |
961 return 0; |
960 return 0; |