469 caller_adjustment = last_frame_adjust(caller_actual_parameters, callee_locals); 470 } 471 472 // If the sender is deoptimized the we must retrieve the address of the handler 473 // since the frame will "magically" show the original pc before the deopt 474 // and we'd undo the deopt. 475 476 frame_pcs[0] = deopt_sender.raw_pc(); 477 478 #ifndef SHARK 479 assert(CodeCache::find_blob_unsafe(frame_pcs[0]) != NULL, "bad pc"); 480 #endif // SHARK 481 482 UnrollBlock* info = new UnrollBlock(array->frame_size() * BytesPerWord, 483 caller_adjustment * BytesPerWord, 484 caller_actual_parameters, 485 number_of_frames, 486 frame_sizes, 487 frame_pcs, 488 return_type); 489 // On some platforms, we need a way to pass fp to the unpacking code 490 // so the skeletal frames come out correct. 491 info->set_initial_fp((intptr_t) array->sender().fp()); 492 493 if (array->frames() > 1) { 494 if (VerifyStack && TraceDeoptimization) { 495 tty->print_cr("Deoptimizing method containing inlining"); 496 } 497 } 498 499 array->set_unroll_block(info); 500 return info; 501 } 502 503 // Called to cleanup deoptimization data structures in normal case 504 // after unpacking to stack and when stack overflow error occurs 505 void Deoptimization::cleanup_deopt_info(JavaThread *thread, 506 vframeArray *array) { 507 508 // Get array if coming from exception 509 if (array == NULL) { 510 array = thread->vframe_array_head(); 511 } | 469 caller_adjustment = last_frame_adjust(caller_actual_parameters, callee_locals); 470 } 471 472 // If the sender is deoptimized the we must retrieve the address of the handler 473 // since the frame will "magically" show the original pc before the deopt 474 // and we'd undo the deopt. 475 476 frame_pcs[0] = deopt_sender.raw_pc(); 477 478 #ifndef SHARK 479 assert(CodeCache::find_blob_unsafe(frame_pcs[0]) != NULL, "bad pc"); 480 #endif // SHARK 481 482 UnrollBlock* info = new UnrollBlock(array->frame_size() * BytesPerWord, 483 caller_adjustment * BytesPerWord, 484 caller_actual_parameters, 485 number_of_frames, 486 frame_sizes, 487 frame_pcs, 488 return_type); 489 // On some platforms, we need a way to pass some platform dependent 490 // information to the unpacking code so the skeletal frames come out 491 // correct (initial fp value, unextended sp, ...) 492 info->set_initial_fp((intptr_t) array->sender().initial_deoptimization_info()); 493 494 if (array->frames() > 1) { 495 if (VerifyStack && TraceDeoptimization) { 496 tty->print_cr("Deoptimizing method containing inlining"); 497 } 498 } 499 500 array->set_unroll_block(info); 501 return info; 502 } 503 504 // Called to cleanup deoptimization data structures in normal case 505 // after unpacking to stack and when stack overflow error occurs 506 void Deoptimization::cleanup_deopt_info(JavaThread *thread, 507 vframeArray *array) { 508 509 // Get array if coming from exception 510 if (array == NULL) { 511 array = thread->vframe_array_head(); 512 } |