< prev index next >

src/share/vm/runtime/sharedRuntime.cpp

Print this page
rev 11777 : [mq]: gcinterface.patch


 564            "polling page vectors safepoint stub not created yet");
 565     stub = SharedRuntime::polling_page_vectors_safepoint_handler_blob()->entry_point();
 566   } else {
 567     assert(SharedRuntime::polling_page_safepoint_handler_blob() != NULL,
 568            "polling page safepoint stub not created yet");
 569     stub = SharedRuntime::polling_page_safepoint_handler_blob()->entry_point();
 570   }
 571   log_debug(safepoint)("... found polling page %s exception at pc = "
 572                        INTPTR_FORMAT ", stub =" INTPTR_FORMAT,
 573                        at_poll_return ? "return" : "loop",
 574                        (intptr_t)pc, (intptr_t)stub);
 575   return stub;
 576 }
 577 
 578 
 579 oop SharedRuntime::retrieve_receiver( Symbol* sig, frame caller ) {
 580   assert(caller.is_interpreted_frame(), "");
 581   int args_size = ArgumentSizeComputer(sig).size() + 1;
 582   assert(args_size <= caller.interpreter_frame_expression_stack_size(), "receiver must be on interpreter stack");
 583   oop result = cast_to_oop(*caller.interpreter_frame_tos_at(args_size - 1));
 584   assert(Universe::heap()->is_in(result) && result->is_oop(), "receiver must be an oop");
 585   return result;
 586 }
 587 
 588 
 589 void SharedRuntime::throw_and_post_jvmti_exception(JavaThread *thread, Handle h_exception) {
 590   if (JvmtiExport::can_post_on_exceptions()) {
 591     vframeStream vfst(thread, true);
 592     methodHandle method = methodHandle(thread, vfst.method());
 593     address bcp = method()->bcp_from(vfst.bci());
 594     JvmtiExport::post_exception_throw(thread, method(), bcp, h_exception());
 595   }
 596   Exceptions::_throw(thread, __FILE__, __LINE__, h_exception);
 597 }
 598 
 599 void SharedRuntime::throw_and_post_jvmti_exception(JavaThread *thread, Symbol* name, const char *message) {
 600   Handle h_exception = Exceptions::new_exception(thread, name, message);
 601   throw_and_post_jvmti_exception(thread, h_exception);
 602 }
 603 
 604 // The interpreter code to call this tracing function is only




 564            "polling page vectors safepoint stub not created yet");
 565     stub = SharedRuntime::polling_page_vectors_safepoint_handler_blob()->entry_point();
 566   } else {
 567     assert(SharedRuntime::polling_page_safepoint_handler_blob() != NULL,
 568            "polling page safepoint stub not created yet");
 569     stub = SharedRuntime::polling_page_safepoint_handler_blob()->entry_point();
 570   }
 571   log_debug(safepoint)("... found polling page %s exception at pc = "
 572                        INTPTR_FORMAT ", stub =" INTPTR_FORMAT,
 573                        at_poll_return ? "return" : "loop",
 574                        (intptr_t)pc, (intptr_t)stub);
 575   return stub;
 576 }
 577 
 578 
 579 oop SharedRuntime::retrieve_receiver( Symbol* sig, frame caller ) {
 580   assert(caller.is_interpreted_frame(), "");
 581   int args_size = ArgumentSizeComputer(sig).size() + 1;
 582   assert(args_size <= caller.interpreter_frame_expression_stack_size(), "receiver must be on interpreter stack");
 583   oop result = cast_to_oop(*caller.interpreter_frame_tos_at(args_size - 1));
 584   assert(GC::gc()->heap()->is_in(result) && result->is_oop(), "receiver must be an oop");
 585   return result;
 586 }
 587 
 588 
 589 void SharedRuntime::throw_and_post_jvmti_exception(JavaThread *thread, Handle h_exception) {
 590   if (JvmtiExport::can_post_on_exceptions()) {
 591     vframeStream vfst(thread, true);
 592     methodHandle method = methodHandle(thread, vfst.method());
 593     address bcp = method()->bcp_from(vfst.bci());
 594     JvmtiExport::post_exception_throw(thread, method(), bcp, h_exception());
 595   }
 596   Exceptions::_throw(thread, __FILE__, __LINE__, h_exception);
 597 }
 598 
 599 void SharedRuntime::throw_and_post_jvmti_exception(JavaThread *thread, Symbol* name, const char *message) {
 600   Handle h_exception = Exceptions::new_exception(thread, name, message);
 601   throw_and_post_jvmti_exception(thread, h_exception);
 602 }
 603 
 604 // The interpreter code to call this tracing function is only


< prev index next >