464 __ get_method(rmethod);
465 __ get_dispatch();
466
467 // Calculate stack limit
468 __ ldr(rscratch1, Address(rmethod, Method::const_offset()));
469 __ ldrh(rscratch1, Address(rscratch1, ConstMethod::max_stack_offset()));
470 __ add(rscratch1, rscratch1, frame::interpreter_frame_monitor_size() + 2);
471 __ ldr(rscratch2,
472 Address(rfp, frame::interpreter_frame_initial_sp_offset * wordSize));
473 __ sub(rscratch1, rscratch2, rscratch1, ext::uxtx, 3);
474 __ andr(sp, rscratch1, -16);
475
476 // Restore expression stack pointer
477 __ ldr(esp, Address(rfp, frame::interpreter_frame_last_sp_offset * wordSize));
478 // NULL last_sp until next java call
479 __ str(zr, Address(rfp, frame::interpreter_frame_last_sp_offset * wordSize));
480
481 #if INCLUDE_JVMCI
482 // Check if we need to take lock at entry of synchronized method. This can
483 // only occur on method entry so emit it only for vtos with step 0.
484 if (EnableJVMCI && state == vtos && step == 0) {
485 Label L;
486 __ ldr(rscratch1, Address(rthread, Thread::pending_exception_offset()));
487 __ cbz(rscratch1, L);
488 // Clear flag.
489 __ strb(zr, Address(rthread, JavaThread::pending_monitorenter_offset()));
490 // Take lock.
491 lock_method();
492 __ bind(L);
493 } else {
494 #ifdef ASSERT
495 if (EnableJVMCI) {
496 Label L;
497 __ ldr(rscratch1, Address(rthread, Thread::pending_exception_offset()));
498 __ cbz(rscratch1, L);
499 __ stop("unexpected pending monitor in deopt entry");
500 __ bind(L);
501 }
502 #endif
503 }
504 #endif
|
464 __ get_method(rmethod);
465 __ get_dispatch();
466
467 // Calculate stack limit
468 __ ldr(rscratch1, Address(rmethod, Method::const_offset()));
469 __ ldrh(rscratch1, Address(rscratch1, ConstMethod::max_stack_offset()));
470 __ add(rscratch1, rscratch1, frame::interpreter_frame_monitor_size() + 2);
471 __ ldr(rscratch2,
472 Address(rfp, frame::interpreter_frame_initial_sp_offset * wordSize));
473 __ sub(rscratch1, rscratch2, rscratch1, ext::uxtx, 3);
474 __ andr(sp, rscratch1, -16);
475
476 // Restore expression stack pointer
477 __ ldr(esp, Address(rfp, frame::interpreter_frame_last_sp_offset * wordSize));
478 // NULL last_sp until next java call
479 __ str(zr, Address(rfp, frame::interpreter_frame_last_sp_offset * wordSize));
480
481 #if INCLUDE_JVMCI
482 // Check if we need to take lock at entry of synchronized method. This can
483 // only occur on method entry so emit it only for vtos with step 0.
484 if ((EnableJVMCI || UseAOT) && state == vtos && step == 0) {
485 Label L;
486 __ ldr(rscratch1, Address(rthread, Thread::pending_exception_offset()));
487 __ cbz(rscratch1, L);
488 // Clear flag.
489 __ strb(zr, Address(rthread, JavaThread::pending_monitorenter_offset()));
490 // Take lock.
491 lock_method();
492 __ bind(L);
493 } else {
494 #ifdef ASSERT
495 if (EnableJVMCI) {
496 Label L;
497 __ ldr(rscratch1, Address(rthread, Thread::pending_exception_offset()));
498 __ cbz(rscratch1, L);
499 __ stop("unexpected pending monitor in deopt entry");
500 __ bind(L);
501 }
502 #endif
503 }
504 #endif
|