8302736: Major performance regression in Math.log on aarch64
Reviewed-by: thartmann, dlong, aph
This commit is contained in:
parent
05c095cf39
commit
466ec300fc
@ -1562,10 +1562,6 @@ address OptoRuntime::handle_exception_C(JavaThread* current) {
|
|||||||
// *THIS IS NOT RECOMMENDED PROGRAMMING STYLE*
|
// *THIS IS NOT RECOMMENDED PROGRAMMING STYLE*
|
||||||
//
|
//
|
||||||
address OptoRuntime::rethrow_C(oopDesc* exception, JavaThread* thread, address ret_pc) {
|
address OptoRuntime::rethrow_C(oopDesc* exception, JavaThread* thread, address ret_pc) {
|
||||||
|
|
||||||
// Enable WXWrite: the function called directly by compiled code.
|
|
||||||
MACOS_AARCH64_ONLY(ThreadWXEnable wx(WXWrite, thread));
|
|
||||||
|
|
||||||
// ret_pc will have been loaded from the stack, so for AArch64 will be signed.
|
// ret_pc will have been loaded from the stack, so for AArch64 will be signed.
|
||||||
// This needs authenticating, but to do that here requires the fp of the previous frame.
|
// This needs authenticating, but to do that here requires the fp of the previous frame.
|
||||||
// A better way of doing it would be authenticate in the caller by adding a
|
// A better way of doing it would be authenticate in the caller by adding a
|
||||||
|
@ -248,6 +248,8 @@ static JRT_LEAF(intptr_t*, thaw(JavaThread* thread, int kind))
|
|||||||
// JRT_ENTRY instead?
|
// JRT_ENTRY instead?
|
||||||
ResetNoHandleMark rnhm;
|
ResetNoHandleMark rnhm;
|
||||||
|
|
||||||
|
// we might modify the code cache via BarrierSetNMethod::nmethod_entry_barrier
|
||||||
|
MACOS_AARCH64_ONLY(ThreadWXEnable __wx(WXWrite, thread));
|
||||||
return ConfigT::thaw(thread, (Continuation::thaw_kind)kind);
|
return ConfigT::thaw(thread, (Continuation::thaw_kind)kind);
|
||||||
JRT_END
|
JRT_END
|
||||||
|
|
||||||
|
@ -260,8 +260,6 @@ class VMNativeEntryWrapper {
|
|||||||
|
|
||||||
#define VM_LEAF_BASE(result_type, header) \
|
#define VM_LEAF_BASE(result_type, header) \
|
||||||
debug_only(NoHandleMark __hm;) \
|
debug_only(NoHandleMark __hm;) \
|
||||||
MACOS_AARCH64_ONLY(ThreadWXEnable __wx(WXWrite, \
|
|
||||||
JavaThread::current())); \
|
|
||||||
os::verify_stack_alignment(); \
|
os::verify_stack_alignment(); \
|
||||||
/* begin of body */
|
/* begin of body */
|
||||||
|
|
||||||
|
@ -479,6 +479,9 @@ address SharedRuntime::raw_exception_handler_for_return_address(JavaThread* curr
|
|||||||
return StubRoutines::cont_returnBarrierExc();
|
return StubRoutines::cont_returnBarrierExc();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// write lock needed because we might update the pc desc cache via PcDescCache::add_pc_desc
|
||||||
|
MACOS_AARCH64_ONLY(ThreadWXEnable wx(WXWrite, current));
|
||||||
|
|
||||||
// The fastest case first
|
// The fastest case first
|
||||||
CodeBlob* blob = CodeCache::find_blob(return_address);
|
CodeBlob* blob = CodeCache::find_blob(return_address);
|
||||||
CompiledMethod* nm = (blob != nullptr) ? blob->as_compiled_method_or_null() : nullptr;
|
CompiledMethod* nm = (blob != nullptr) ? blob->as_compiled_method_or_null() : nullptr;
|
||||||
@ -2058,6 +2061,9 @@ JRT_LEAF(void, SharedRuntime::fixup_callers_callsite(Method* method, address cal
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// write lock needed because we might update the pc desc cache via PcDescCache::add_pc_desc
|
||||||
|
MACOS_AARCH64_ONLY(ThreadWXEnable __wx(WXWrite, JavaThread::current()));
|
||||||
|
|
||||||
CodeBlob* cb = CodeCache::find_blob(caller_pc);
|
CodeBlob* cb = CodeCache::find_blob(caller_pc);
|
||||||
if (cb == nullptr || !cb->is_compiled() || callee->is_unloading()) {
|
if (cb == nullptr || !cb->is_compiled() || callee->is_unloading()) {
|
||||||
return;
|
return;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user