Mercurial > hg > graal-compiler
comparison src/share/vm/runtime/sharedRuntime.cpp @ 10276:f0bc60565ba8
7196277: JSR 292: Two jck/runtime tests crash on java.lang.invoke.MethodHandle.invokeExact
Reviewed-by: jrose, kvn
author | twisti |
---|---|
date | Mon, 06 May 2013 13:53:13 -0700 |
parents | a5c95fcf7cb7 |
children | 28e5aed7f3a6 0f03ff49c720 |
comparison
equal
deleted
inserted
replaced
10275:d73c88e524ff | 10276:f0bc60565ba8 |
---|---|
881 ShouldNotReachHere(); | 881 ShouldNotReachHere(); |
882 return NULL; | 882 return NULL; |
883 } | 883 } |
884 | 884 |
885 | 885 |
886 JNI_ENTRY(void, throw_unsatisfied_link_error(JNIEnv* env, ...)) | 886 /** |
887 * Throws an java/lang/UnsatisfiedLinkError. The address of this method is | |
888 * installed in the native function entry of all native Java methods before | |
889 * they get linked to their actual native methods. | |
890 * | |
891 * \note | |
892 * This method actually never gets called! The reason is because | |
893 * the interpreter's native entries call NativeLookup::lookup() which | |
894 * throws the exception when the lookup fails. The exception is then | |
895 * caught and forwarded on the return from NativeLookup::lookup() call | |
896 * before the call to the native function. This might change in the future. | |
897 */ | |
898 JNI_ENTRY(void*, throw_unsatisfied_link_error(JNIEnv* env, ...)) | |
887 { | 899 { |
888 THROW(vmSymbols::java_lang_UnsatisfiedLinkError()); | 900 // We return a bad value here to make sure that the exception is |
889 } | 901 // forwarded before we look at the return value. |
890 JNI_END | 902 THROW_(vmSymbols::java_lang_UnsatisfiedLinkError(), (void*)badJNIHandle); |
891 | |
892 JNI_ENTRY(void, throw_unsupported_operation_exception(JNIEnv* env, ...)) | |
893 { | |
894 THROW(vmSymbols::java_lang_UnsupportedOperationException()); | |
895 } | 903 } |
896 JNI_END | 904 JNI_END |
897 | 905 |
898 address SharedRuntime::native_method_throw_unsatisfied_link_error_entry() { | 906 address SharedRuntime::native_method_throw_unsatisfied_link_error_entry() { |
899 return CAST_FROM_FN_PTR(address, &throw_unsatisfied_link_error); | 907 return CAST_FROM_FN_PTR(address, &throw_unsatisfied_link_error); |
900 } | |
901 | |
902 address SharedRuntime::native_method_throw_unsupported_operation_exception_entry() { | |
903 return CAST_FROM_FN_PTR(address, &throw_unsupported_operation_exception); | |
904 } | 908 } |
905 | 909 |
906 | 910 |
907 #ifndef PRODUCT | 911 #ifndef PRODUCT |
908 JRT_ENTRY(intptr_t, SharedRuntime::trace_bytecode(JavaThread* thread, intptr_t preserve_this_value, intptr_t tos, intptr_t tos2)) | 912 JRT_ENTRY(intptr_t, SharedRuntime::trace_bytecode(JavaThread* thread, intptr_t preserve_this_value, intptr_t tos, intptr_t tos2)) |