hotspot/src/cpu/arm/vm/sharedRuntime_arm.cpp
changeset 46620 750c6edff33b
parent 44406 a46a6c4d1dd9
child 46625 edefffab74e2
equal deleted inserted replaced
46619:a3919f5e8d2b 46620:750c6edff33b
   745 
   745 
   746   assert_different_registers(tmp, R0, R1, R2, R3, R4, R5, R6, R7, Rsender_sp, Rmethod);
   746   assert_different_registers(tmp, R0, R1, R2, R3, R4, R5, R6, R7, Rsender_sp, Rmethod);
   747   assert_different_registers(tmp, R0, R1, R2, R3, R4, R5, R6, R7, Rsender_sp, Rparams);
   747   assert_different_registers(tmp, R0, R1, R2, R3, R4, R5, R6, R7, Rsender_sp, Rparams);
   748 
   748 
   749   if (comp_args_on_stack) {
   749   if (comp_args_on_stack) {
   750     __ sub_slow(SP, SP, round_to(comp_args_on_stack * VMRegImpl::stack_slot_size, StackAlignmentInBytes));
   750     __ sub_slow(SP, SP, align_up(comp_args_on_stack * VMRegImpl::stack_slot_size, StackAlignmentInBytes));
   751   }
   751   }
   752 
   752 
   753   for (int i = 0; i < total_args_passed; i++) {
   753   for (int i = 0; i < total_args_passed; i++) {
   754     if (sig_bt[i] == T_VOID) {
   754     if (sig_bt[i] == T_VOID) {
   755       assert(i > 0 && (sig_bt[i-1] == T_LONG || sig_bt[i-1] == T_DOUBLE), "missing half");
   755       assert(i > 0 && (sig_bt[i-1] == T_LONG || sig_bt[i-1] == T_DOUBLE), "missing half");
   868 
   868 
   869   __ mov(Rsender_sp, SP); // not yet saved
   869   __ mov(Rsender_sp, SP); // not yet saved
   870 
   870 
   871 #ifdef AARCH64
   871 #ifdef AARCH64
   872 
   872 
   873   int extraspace = round_to(total_args_passed * Interpreter::stackElementSize, StackAlignmentInBytes);
   873   int extraspace = align_up(total_args_passed * Interpreter::stackElementSize, StackAlignmentInBytes);
   874   if (extraspace) {
   874   if (extraspace) {
   875     __ sub(SP, SP, extraspace);
   875     __ sub(SP, SP, extraspace);
   876   }
   876   }
   877 
   877 
   878   for (int i = 0; i < total_args_passed; i++) {
   878   for (int i = 0; i < total_args_passed; i++) {
  1179 
  1179 
  1180   // Space to save return address and FP
  1180   // Space to save return address and FP
  1181   stack_slots += 2 * VMRegImpl::slots_per_word;
  1181   stack_slots += 2 * VMRegImpl::slots_per_word;
  1182 
  1182 
  1183   // Calculate the final stack size taking account of alignment
  1183   // Calculate the final stack size taking account of alignment
  1184   stack_slots = round_to(stack_slots, StackAlignmentInBytes / VMRegImpl::stack_slot_size);
  1184   stack_slots = align_up(stack_slots, StackAlignmentInBytes / VMRegImpl::stack_slot_size);
  1185   int stack_size = stack_slots * VMRegImpl::stack_slot_size;
  1185   int stack_size = stack_slots * VMRegImpl::stack_slot_size;
  1186   int lock_slot_fp_offset = stack_size - 2 * wordSize -
  1186   int lock_slot_fp_offset = stack_size - 2 * wordSize -
  1187     lock_slot_offset * VMRegImpl::stack_slot_size;
  1187     lock_slot_offset * VMRegImpl::stack_slot_size;
  1188 
  1188 
  1189   // Unverified entry point
  1189   // Unverified entry point
  1849 // this function returns the adjust size (in number of words) to a c2i adapter
  1849 // this function returns the adjust size (in number of words) to a c2i adapter
  1850 // activation for use during deoptimization
  1850 // activation for use during deoptimization
  1851 int Deoptimization::last_frame_adjust(int callee_parameters, int callee_locals) {
  1851 int Deoptimization::last_frame_adjust(int callee_parameters, int callee_locals) {
  1852   int extra_locals_size = (callee_locals - callee_parameters) * Interpreter::stackElementWords;
  1852   int extra_locals_size = (callee_locals - callee_parameters) * Interpreter::stackElementWords;
  1853 #ifdef AARCH64
  1853 #ifdef AARCH64
  1854   extra_locals_size = round_to(extra_locals_size, StackAlignmentInBytes/BytesPerWord);
  1854   extra_locals_size = align_up(extra_locals_size, StackAlignmentInBytes/BytesPerWord);
  1855 #endif // AARCH64
  1855 #endif // AARCH64
  1856   return extra_locals_size;
  1856   return extra_locals_size;
  1857 }
  1857 }
  1858 
  1858 
  1859 
  1859