more TheRealMDoerr suggestions
This commit is contained in:
parent
88c1d72eda
commit
40b922977b
@ -1,30 +0,0 @@
|
|||||||
/*
|
|
||||||
* Copyright (c) 2003, 2025, Oracle and/or its affiliates. All rights reserved.
|
|
||||||
* Copyright 2008 Red Hat, Inc.
|
|
||||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
||||||
*
|
|
||||||
* This code is free software; you can redistribute it and/or modify it
|
|
||||||
* under the terms of the GNU General Public License version 2 only, as
|
|
||||||
* published by the Free Software Foundation.
|
|
||||||
*
|
|
||||||
* This code is distributed in the hope that it will be useful, but WITHOUT
|
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
|
||||||
* version 2 for more details (a copy is included in the LICENSE file that
|
|
||||||
* accompanied this code).
|
|
||||||
*
|
|
||||||
* You should have received a copy of the GNU General Public License version
|
|
||||||
* 2 along with this work; if not, write to the Free Software Foundation,
|
|
||||||
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
|
||||||
*
|
|
||||||
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
|
||||||
* or visit www.oracle.com if you need additional information or have any
|
|
||||||
* questions.
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include "asm/assembler.inline.hpp"
|
|
||||||
#include "entry_zero.hpp"
|
|
||||||
#include "interpreter/zero/zeroInterpreter.hpp"
|
|
||||||
#include "nativeInst_zero.hpp"
|
|
||||||
#include "runtime/sharedRuntime.hpp"
|
|
@ -359,11 +359,6 @@ bool PosixSignals::pd_hotspot_signal_handler(int sig, siginfo_t* info,
|
|||||||
stub = SharedRuntime::continuation_for_implicit_exception(
|
stub = SharedRuntime::continuation_for_implicit_exception(
|
||||||
thread, pc, SharedRuntime::IMPLICIT_NULL);
|
thread, pc, SharedRuntime::IMPLICIT_NULL);
|
||||||
}
|
}
|
||||||
} else if (sig == SIGILL &&
|
|
||||||
*(int*)pc ==
|
|
||||||
NativeInstruction::not_entrant_illegal_instruction) {
|
|
||||||
// Not entrant
|
|
||||||
stub = SharedRuntime::get_handle_wrong_method_stub();
|
|
||||||
}
|
}
|
||||||
} else if ((thread->thread_state() == _thread_in_vm ||
|
} else if ((thread->thread_state() == _thread_in_vm ||
|
||||||
thread->thread_state() == _thread_in_native) &&
|
thread->thread_state() == _thread_in_native) &&
|
||||||
|
@ -246,8 +246,11 @@ void BarrierSetNMethod::make_not_entrant(nmethod* nm) {
|
|||||||
// Enter critical section. Does not block for safepoint.
|
// Enter critical section. Does not block for safepoint.
|
||||||
ConditionalMutexLocker ml(NMethodEntryBarrier_lock, !NMethodEntryBarrier_lock->owned_by_self(), Mutex::_no_safepoint_check_flag);
|
ConditionalMutexLocker ml(NMethodEntryBarrier_lock, !NMethodEntryBarrier_lock->owned_by_self(), Mutex::_no_safepoint_check_flag);
|
||||||
int value = guard_value(nm) | not_entrant;
|
int value = guard_value(nm) | not_entrant;
|
||||||
|
if (guard_value(nm) != value) {
|
||||||
|
// Patch the code only if needed.
|
||||||
set_guard_value(nm, value);
|
set_guard_value(nm, value);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
bool BarrierSetNMethod::is_not_entrant(nmethod* nm) {
|
bool BarrierSetNMethod::is_not_entrant(nmethod* nm) {
|
||||||
return (guard_value(nm) & not_entrant) != 0;
|
return (guard_value(nm) & not_entrant) != 0;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user