8182755: [JVMCI] Deoptimization in synchronized methods can lead to a crash or exception when using EnableJVMCI but not UseJVMCICompiler
Reviewed-by: kvn, thartmann
This commit is contained in:
parent
b0c9129d6c
commit
a908316a65
@ -472,7 +472,7 @@ address TemplateInterpreterGenerator::generate_deopt_entry_for(TosState state,
|
||||
#if INCLUDE_JVMCI
|
||||
// Check if we need to take lock at entry of synchronized method. This can
|
||||
// only occur on method entry so emit it only for vtos with step 0.
|
||||
if (UseJVMCICompiler && state == vtos && step == 0) {
|
||||
if (EnableJVMCI && state == vtos && step == 0) {
|
||||
Label L;
|
||||
__ ldr(rscratch1, Address(rthread, Thread::pending_exception_offset()));
|
||||
__ cbz(rscratch1, L);
|
||||
@ -483,7 +483,7 @@ address TemplateInterpreterGenerator::generate_deopt_entry_for(TosState state,
|
||||
__ bind(L);
|
||||
} else {
|
||||
#ifdef ASSERT
|
||||
if (UseJVMCICompiler) {
|
||||
if (EnableJVMCI) {
|
||||
Label L;
|
||||
__ ldr(rscratch1, Address(rthread, Thread::pending_exception_offset()));
|
||||
__ cbz(rscratch1, L);
|
||||
|
@ -319,7 +319,7 @@ address TemplateInterpreterGenerator::generate_deopt_entry_for(TosState state, i
|
||||
#if INCLUDE_JVMCI
|
||||
// Check if we need to take lock at entry of synchronized method. This can
|
||||
// only occur on method entry so emit it only for vtos with step 0.
|
||||
if (UseJVMCICompiler && state == vtos && step == 0) {
|
||||
if (EnableJVMCI && state == vtos && step == 0) {
|
||||
Label L;
|
||||
Address pending_monitor_enter_addr(G2_thread, JavaThread::pending_monitorenter_offset());
|
||||
__ ldbool(pending_monitor_enter_addr, Gtemp); // Load if pending monitor enter
|
||||
@ -331,7 +331,7 @@ address TemplateInterpreterGenerator::generate_deopt_entry_for(TosState state, i
|
||||
__ bind(L);
|
||||
} else {
|
||||
#ifdef ASSERT
|
||||
if (UseJVMCICompiler) {
|
||||
if (EnableJVMCI) {
|
||||
Label L;
|
||||
Address pending_monitor_enter_addr(G2_thread, JavaThread::pending_monitorenter_offset());
|
||||
__ ldbool(pending_monitor_enter_addr, Gtemp); // Load if pending monitor enter
|
||||
|
@ -257,7 +257,7 @@ address TemplateInterpreterGenerator::generate_deopt_entry_for(TosState state, i
|
||||
#if INCLUDE_JVMCI
|
||||
// Check if we need to take lock at entry of synchronized method. This can
|
||||
// only occur on method entry so emit it only for vtos with step 0.
|
||||
if ((UseJVMCICompiler || UseAOT) && state == vtos && step == 0) {
|
||||
if ((EnableJVMCI || UseAOT) && state == vtos && step == 0) {
|
||||
Label L;
|
||||
__ cmpb(Address(thread, JavaThread::pending_monitorenter_offset()), 0);
|
||||
__ jcc(Assembler::zero, L);
|
||||
@ -270,7 +270,7 @@ address TemplateInterpreterGenerator::generate_deopt_entry_for(TosState state, i
|
||||
__ bind(L);
|
||||
} else {
|
||||
#ifdef ASSERT
|
||||
if (UseJVMCICompiler) {
|
||||
if (EnableJVMCI) {
|
||||
Label L;
|
||||
__ cmpb(Address(r15_thread, JavaThread::pending_monitorenter_offset()), 0);
|
||||
__ jccb(Assembler::zero, L);
|
||||
|
Loading…
Reference in New Issue
Block a user