comparison src/share/vm/runtime/sharedRuntime.cpp @ 2605:98fa88528319

Deopt on implicit null pointer exception.
author Thomas Wuerthinger <thomas@wuerthinger.net>
date Fri, 06 May 2011 16:20:56 +0200
parents e88293edf07c
children 008adfd6d850
comparison
equal deleted inserted replaced
2604:c9b17ac5c06b 2605:98fa88528319
697 SharedRuntime::ImplicitExceptionKind exception_kind) 697 SharedRuntime::ImplicitExceptionKind exception_kind)
698 { 698 {
699 address target_pc = NULL; 699 address target_pc = NULL;
700 700
701 if (TraceSignals) { 701 if (TraceSignals) {
702 tty->print_cr("Searching for continuation for implicit exception at %d", pc); 702 tty->print_cr("Searching for continuation for implicit exception at %d!", pc);
703 } 703 }
704 704
705 if (Interpreter::contains(pc)) { 705 if (Interpreter::contains(pc)) {
706 #ifdef CC_INTERP 706 #ifdef CC_INTERP
707 // C++ interpreter doesn't throw implicit exceptions 707 // C++ interpreter doesn't throw implicit exceptions
778 #endif 778 #endif
779 if (UseC1X) { 779 if (UseC1X) {
780 if (TraceSignals) { 780 if (TraceSignals) {
781 tty->print_cr(err_msg("calling implicit call stub relative pc=%d method name = %s", pc - nm->entry_point(), nm->method()->name()->as_C_string())); 781 tty->print_cr(err_msg("calling implicit call stub relative pc=%d method name = %s", pc - nm->entry_point(), nm->method()->name()->as_C_string()));
782 } 782 }
783 target_pc = Runtime1::entry_for(Runtime1::c1x_global_implicit_null_id); 783 thread->_ScratchA = (intptr_t)pc;
784 target_pc = (SharedRuntime::deopt_blob()->jmp_uncommon_trap());//Runtime1::entry_for(Runtime1::c1x_global_implicit_null_id);
784 } else { 785 } else {
785 target_pc = nm->continuation_for_implicit_exception(pc); 786 target_pc = nm->continuation_for_implicit_exception(pc);
786 } 787 }
787 // If there's an unexpected fault, target_pc might be NULL, 788 // If there's an unexpected fault, target_pc might be NULL,
788 // in which case we want to fall through into the normal 789 // in which case we want to fall through into the normal