< prev index next >

src/hotspot/cpu/riscv/templateTable_riscv.cpp

Print this page

3878                                                    // word from old location
3879      __ sd(c_rarg2, Address(c_rarg3, 0));          // and store it at new location
3880      __ add(c_rarg3, c_rarg3, wordSize);           // advance to next word
3881      __ bind(entry);
3882      __ bne(c_rarg3, c_rarg1, loop);    // check if bottom reached.if not at bottom
3883                                         // then copy next word
3884    }
3885 
3886    // call run-time routine
3887    // c_rarg1: points to monitor entry
3888    __ bind(allocated);
3889 
3890    // Increment bcp to point to the next bytecode, so exception
3891    // handling for async. exceptions work correctly.
3892    // The object has already been popped from the stack, so the
3893    // expression stack looks correct.
3894    __ addi(xbcp, xbcp, 1);
3895 
3896    // store object
3897    __ sd(x10, Address(c_rarg1, BasicObjectLock::obj_offset()));

3898    __ lock_object(c_rarg1);
3899 
3900    // check to make sure this monitor doesn't cause stack overflow after locking
3901    __ save_bcp();  // in case of exception
3902    __ generate_stack_overflow_check(0);
3903 
3904    // The bcp has already been incremented. Just need to dispatch to
3905    // next instruction.
3906    __ dispatch_next(vtos);
3907 }
3908 
3909 void TemplateTable::monitorexit() {
3910   transition(atos, vtos);
3911 
3912   // check for null object
3913   __ null_check(x10);
3914 
3915   const Address monitor_block_top(
3916         fp, frame::interpreter_frame_monitor_block_top_offset * wordSize);
3917   const Address monitor_block_bot(

3878                                                    // word from old location
3879      __ sd(c_rarg2, Address(c_rarg3, 0));          // and store it at new location
3880      __ add(c_rarg3, c_rarg3, wordSize);           // advance to next word
3881      __ bind(entry);
3882      __ bne(c_rarg3, c_rarg1, loop);    // check if bottom reached.if not at bottom
3883                                         // then copy next word
3884    }
3885 
3886    // call run-time routine
3887    // c_rarg1: points to monitor entry
3888    __ bind(allocated);
3889 
3890    // Increment bcp to point to the next bytecode, so exception
3891    // handling for async. exceptions work correctly.
3892    // The object has already been popped from the stack, so the
3893    // expression stack looks correct.
3894    __ addi(xbcp, xbcp, 1);
3895 
3896    // store object
3897    __ sd(x10, Address(c_rarg1, BasicObjectLock::obj_offset()));
3898 
3899    __ lock_object(c_rarg1);
3900 
3901    // check to make sure this monitor doesn't cause stack overflow after locking
3902    __ save_bcp();  // in case of exception
3903    __ generate_stack_overflow_check(0);
3904 
3905    // The bcp has already been incremented. Just need to dispatch to
3906    // next instruction.
3907    __ dispatch_next(vtos);
3908 }
3909 
3910 void TemplateTable::monitorexit() {
3911   transition(atos, vtos);
3912 
3913   // check for null object
3914   __ null_check(x10);
3915 
3916   const Address monitor_block_top(
3917         fp, frame::interpreter_frame_monitor_block_top_offset * wordSize);
3918   const Address monitor_block_bot(
< prev index next >