< prev index next >

src/share/vm/interpreter/interpreterRuntime.cpp

Print this page

        

*** 1039,1057 **** InstanceKlass* ik = InstanceKlass::cast(cp_entry->f1_as_klass()); int index = cp_entry->field_index(); if ((ik->field_access_flags(index) & JVM_ACC_FIELD_ACCESS_WATCHED) == 0) return; bool is_static = (obj == NULL); HandleMark hm(thread); Handle h_obj; if (!is_static) { // non-static field accessors have an object, but we need a handle h_obj = Handle(thread, obj); } instanceKlassHandle h_cp_entry_f1(thread, (Klass*)cp_entry->f1_as_klass()); ! jfieldID fid = jfieldIDWorkaround::to_jfieldID(h_cp_entry_f1, cp_entry->f2_as_index(), is_static); JvmtiExport::post_field_access(thread, method(thread), bcp(thread), h_cp_entry_f1, h_obj, fid); IRT_END IRT_ENTRY(void, InterpreterRuntime::post_field_modification(JavaThread *thread, oopDesc* obj, ConstantPoolCacheEntry *cp_entry, jvalue *value)) --- 1039,1058 ---- InstanceKlass* ik = InstanceKlass::cast(cp_entry->f1_as_klass()); int index = cp_entry->field_index(); if ((ik->field_access_flags(index) & JVM_ACC_FIELD_ACCESS_WATCHED) == 0) return; bool is_static = (obj == NULL); + bool is_final = ((ik->field_access_flags(index) & JVM_ACC_FINAL) != 0); HandleMark hm(thread); Handle h_obj; if (!is_static) { // non-static field accessors have an object, but we need a handle h_obj = Handle(thread, obj); } instanceKlassHandle h_cp_entry_f1(thread, (Klass*)cp_entry->f1_as_klass()); ! jfieldID fid = jfieldIDWorkaround::to_jfieldID(h_cp_entry_f1, cp_entry->f2_as_index(), is_static, is_final); JvmtiExport::post_field_access(thread, method(thread), bcp(thread), h_cp_entry_f1, h_obj, fid); IRT_END IRT_ENTRY(void, InterpreterRuntime::post_field_modification(JavaThread *thread, oopDesc* obj, ConstantPoolCacheEntry *cp_entry, jvalue *value))
*** 1076,1089 **** case ltos: sig_type = 'J'; break; case dtos: sig_type = 'D'; break; default: ShouldNotReachHere(); return; } bool is_static = (obj == NULL); HandleMark hm(thread); instanceKlassHandle h_klass(thread, k); ! jfieldID fid = jfieldIDWorkaround::to_jfieldID(h_klass, cp_entry->f2_as_index(), is_static); jvalue fvalue; #ifdef _LP64 fvalue = *value; #else // Long/double values are stored unaligned and also noncontiguously with --- 1077,1091 ---- case ltos: sig_type = 'J'; break; case dtos: sig_type = 'D'; break; default: ShouldNotReachHere(); return; } bool is_static = (obj == NULL); + bool is_final = ((ik->field_access_flags(index) & JVM_ACC_FINAL) != 0); HandleMark hm(thread); instanceKlassHandle h_klass(thread, k); ! jfieldID fid = jfieldIDWorkaround::to_jfieldID(h_klass, cp_entry->f2_as_index(), is_static, is_final); jvalue fvalue; #ifdef _LP64 fvalue = *value; #else // Long/double values are stored unaligned and also noncontiguously with
< prev index next >