< prev index next >

src/hotspot/share/prims/methodHandles.cpp

Print this page

        

*** 1096,1106 **** int marked = 0; CallSiteDepChange changes(call_site, target); { NoSafepointVerifier nsv; ! MutexLocker mu2(CodeCache_lock, Mutex::_no_safepoint_check_flag); oop context = java_lang_invoke_CallSite::context_no_keepalive(call_site()); DependencyContext deps = java_lang_invoke_MethodHandleNatives_CallSiteContext::vmdependencies(context); marked = deps.mark_dependent_nmethods(changes); } --- 1096,1106 ---- int marked = 0; CallSiteDepChange changes(call_site, target); { NoSafepointVerifier nsv; ! MutexLockerEx mu2(CodeCache_lock, Mutex::_no_safepoint_check_flag); oop context = java_lang_invoke_CallSite::context_no_keepalive(call_site()); DependencyContext deps = java_lang_invoke_MethodHandleNatives_CallSiteContext::vmdependencies(context); marked = deps.mark_dependent_nmethods(changes); }
*** 1149,1158 **** --- 1149,1162 ---- template(java_lang_invoke_MemberName,MN_CALLER_SENSITIVE) \ template(java_lang_invoke_MemberName,MN_SEARCH_SUPERCLASSES) \ template(java_lang_invoke_MemberName,MN_SEARCH_INTERFACES) \ template(java_lang_invoke_MemberName,MN_REFERENCE_KIND_SHIFT) \ template(java_lang_invoke_MemberName,MN_REFERENCE_KIND_MASK) \ + template(java_lang_invoke_MemberName,MN_NESTMATE_CLASS) \ + template(java_lang_invoke_MemberName,MN_NONFINDABLE_CLASS) \ + template(java_lang_invoke_MemberName,MN_WEAK_CLASS) \ + template(java_lang_invoke_MemberName,MN_ACCESS_VM_ANNOTATIONS) \ /*end*/ #define IGNORE_REQ(req_expr) /* req_expr */ #define ONE_PLUS(scope,value) 1+ static const int con_value_count = EACH_NAMED_CON(ONE_PLUS, IGNORE_REQ) 0;
*** 1495,1505 **** MutexLocker mu1(Compile_lock, thread); int marked = 0; { NoSafepointVerifier nsv; ! MutexLocker mu2(CodeCache_lock, Mutex::_no_safepoint_check_flag); DependencyContext deps = java_lang_invoke_MethodHandleNatives_CallSiteContext::vmdependencies(context()); marked = deps.remove_all_dependents(); } if (marked > 0) { // At least one nmethod has been marked for deoptimization --- 1499,1509 ---- MutexLocker mu1(Compile_lock, thread); int marked = 0; { NoSafepointVerifier nsv; ! MutexLockerEx mu2(CodeCache_lock, Mutex::_no_safepoint_check_flag); DependencyContext deps = java_lang_invoke_MethodHandleNatives_CallSiteContext::vmdependencies(context()); marked = deps.remove_all_dependents(); } if (marked > 0) { // At least one nmethod has been marked for deoptimization
*** 1508,1517 **** --- 1512,1532 ---- } } } JVM_END + /* + * Return the class data from the injected classData field of the given lookup class + */ + JVM_ENTRY(jobject, MHN_classData(JNIEnv *env, jobject igcls, jclass lookup)) + if (lookup == NULL) { + THROW_MSG_0(vmSymbols::java_lang_IllegalArgumentException(), "Lookup class is null"); + } + oop mirror = JNIHandles::resolve_non_null(lookup); + return (jobject) JNIHandles::make_local(env, java_lang_Class::class_data(mirror)); + JVM_END + /** * Throws a java/lang/UnsupportedOperationException unconditionally. * This is required by the specification of MethodHandle.invoke if * invoked directly. */
*** 1566,1576 **** {CC "setCallSiteTargetVolatile", CC "(" CS "" MH ")V", FN_PTR(MHN_setCallSiteTargetVolatile)}, {CC "copyOutBootstrapArguments", CC "(" CLS "[III[" OBJ "IZ" OBJ ")V", FN_PTR(MHN_copyOutBootstrapArguments)}, {CC "clearCallSiteContext", CC "(" CTX ")V", FN_PTR(MHN_clearCallSiteContext)}, {CC "staticFieldOffset", CC "(" MEM ")J", FN_PTR(MHN_staticFieldOffset)}, {CC "staticFieldBase", CC "(" MEM ")" OBJ, FN_PTR(MHN_staticFieldBase)}, ! {CC "getMemberVMInfo", CC "(" MEM ")" OBJ, FN_PTR(MHN_getMemberVMInfo)} }; static JNINativeMethod MH_methods[] = { // UnsupportedOperationException throwers {CC "invoke", CC "([" OBJ ")" OBJ, FN_PTR(MH_invoke_UOE)}, --- 1581,1592 ---- {CC "setCallSiteTargetVolatile", CC "(" CS "" MH ")V", FN_PTR(MHN_setCallSiteTargetVolatile)}, {CC "copyOutBootstrapArguments", CC "(" CLS "[III[" OBJ "IZ" OBJ ")V", FN_PTR(MHN_copyOutBootstrapArguments)}, {CC "clearCallSiteContext", CC "(" CTX ")V", FN_PTR(MHN_clearCallSiteContext)}, {CC "staticFieldOffset", CC "(" MEM ")J", FN_PTR(MHN_staticFieldOffset)}, {CC "staticFieldBase", CC "(" MEM ")" OBJ, FN_PTR(MHN_staticFieldBase)}, ! {CC "getMemberVMInfo", CC "(" MEM ")" OBJ, FN_PTR(MHN_getMemberVMInfo)}, ! {CC "classData", CC "(" CLS ")" OBJ, FN_PTR(MHN_classData)} }; static JNINativeMethod MH_methods[] = { // UnsupportedOperationException throwers {CC "invoke", CC "([" OBJ ")" OBJ, FN_PTR(MH_invoke_UOE)},
< prev index next >