src/share/vm/prims/jni.cpp
Index
Unified diffs
Context diffs
Sdiffs
Patch
New
Old
Previous File
Next File
*** old/src/share/vm/prims/jni.cpp Mon Aug 19 07:39:10 2013
--- new/src/share/vm/prims/jni.cpp Mon Aug 19 07:39:10 2013
*** 1334,1343 ****
--- 1334,1344 ----
// non-interface call -- for that little speed boost, don't handlize
debug_only(No_Safepoint_Verifier nosafepoint;)
if (call_type == JNI_VIRTUAL) {
// jni_GetMethodID makes sure class is linked and initialized
// so m should have a valid vtable index.
+ assert(!m->has_itable_index(), "");
int vtbl_index = m->vtable_index();
if (vtbl_index != Method::nonvirtual_vtable_index) {
Klass* k = h_recv->klass();
// k might be an arrayKlassOop but all vtables start at
// the same place. The cast is to avoid virtual call and assertion.
*** 1353,1368 ****
--- 1354,1364 ----
}
} else {
// interface call
KlassHandle h_holder(THREAD, holder);
- int itbl_index = m->cached_itable_index();
if (itbl_index == -1) {
itbl_index = klassItable::compute_itable_index(m);
m->set_cached_itable_index(itbl_index);
// the above may have grabbed a lock, 'm' and anything non-handlized can't be used again
}
Klass* k = h_recv->klass();
selected_method = InstanceKlass::cast(k)->method_at_itable(h_holder(), itbl_index, CHECK);
}
}
src/share/vm/prims/jni.cpp
Index
Unified diffs
Context diffs
Sdiffs
Patch
New
Old
Previous File
Next File