mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 15:24:43 +02:00
8228758: assert(_no_handle_mark_nesting == 0) failed: allocating handle inside NoHandleMark
Reviewed-by: coleenp, dcubed, dholmes
This commit is contained in:
parent
de87e8e860
commit
ffa889731a
3 changed files with 37 additions and 68 deletions
|
@ -393,16 +393,6 @@ class RuntimeHistogramElement : public HistogramElement {
|
|||
/* begin of body */
|
||||
|
||||
|
||||
// QUICK_ENTRY routines behave like ENTRY but without a handle mark
|
||||
|
||||
#define VM_QUICK_ENTRY_BASE(result_type, header, thread) \
|
||||
TRACE_CALL(result_type, header) \
|
||||
debug_only(NoHandleMark __hm;) \
|
||||
Thread* THREAD = thread; \
|
||||
os::verify_stack_alignment(); \
|
||||
/* begin of body */
|
||||
|
||||
|
||||
#define JRT_ENTRY(result_type, header) \
|
||||
result_type header { \
|
||||
ThreadInVMfromJava __tiv(thread); \
|
||||
|
@ -474,18 +464,6 @@ extern "C" { \
|
|||
VM_ENTRY_BASE(result_type, header, thread)
|
||||
|
||||
|
||||
// Ensure that the VMNativeEntryWrapper constructor, which can cause
|
||||
// a GC, is called outside the NoHandleMark (set via VM_QUICK_ENTRY_BASE).
|
||||
#define JNI_QUICK_ENTRY(result_type, header) \
|
||||
extern "C" { \
|
||||
result_type JNICALL header { \
|
||||
JavaThread* thread=JavaThread::thread_from_jni_environment(env); \
|
||||
assert( !VerifyJNIEnvThread || (thread == Thread::current()), "JNIEnv is only valid in same thread"); \
|
||||
ThreadInVMfromNative __tiv(thread); \
|
||||
debug_only(VMNativeEntryWrapper __vew;) \
|
||||
VM_QUICK_ENTRY_BASE(result_type, header, thread)
|
||||
|
||||
|
||||
#define JNI_LEAF(result_type, header) \
|
||||
extern "C" { \
|
||||
result_type JNICALL header { \
|
||||
|
@ -519,15 +497,6 @@ extern "C" { \
|
|||
VM_ENTRY_BASE(result_type, header, thread)
|
||||
|
||||
|
||||
#define JVM_QUICK_ENTRY(result_type, header) \
|
||||
extern "C" { \
|
||||
result_type JNICALL header { \
|
||||
JavaThread* thread=JavaThread::thread_from_jni_environment(env); \
|
||||
ThreadInVMfromNative __tiv(thread); \
|
||||
debug_only(VMNativeEntryWrapper __vew;) \
|
||||
VM_QUICK_ENTRY_BASE(result_type, header, thread)
|
||||
|
||||
|
||||
#define JVM_LEAF(result_type, header) \
|
||||
extern "C" { \
|
||||
result_type JNICALL header { \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue