equal
deleted
inserted
replaced
41 #include "compiler/disassembler.hpp" |
41 #include "compiler/disassembler.hpp" |
42 #include "gc/shared/barrierSet.hpp" |
42 #include "gc/shared/barrierSet.hpp" |
43 #include "gc/shared/collectedHeap.hpp" |
43 #include "gc/shared/collectedHeap.hpp" |
44 #include "interpreter/bytecode.hpp" |
44 #include "interpreter/bytecode.hpp" |
45 #include "interpreter/interpreter.hpp" |
45 #include "interpreter/interpreter.hpp" |
|
46 #include "logging/log.hpp" |
46 #include "memory/allocation.inline.hpp" |
47 #include "memory/allocation.inline.hpp" |
47 #include "memory/oopFactory.hpp" |
48 #include "memory/oopFactory.hpp" |
48 #include "memory/resourceArea.hpp" |
49 #include "memory/resourceArea.hpp" |
49 #include "oops/objArrayKlass.hpp" |
50 #include "oops/objArrayKlass.hpp" |
50 #include "oops/oop.inline.hpp" |
51 #include "oops/oop.inline.hpp" |
546 // New exception handling mechanism can support inlined methods |
547 // New exception handling mechanism can support inlined methods |
547 // with exception handlers since the mappings are from PC to PC |
548 // with exception handlers since the mappings are from PC to PC |
548 |
549 |
549 // debugging support |
550 // debugging support |
550 // tracing |
551 // tracing |
551 if (TraceExceptions) { |
552 if (log_is_enabled(Info, exceptions)) { |
552 ttyLocker ttyl; |
|
553 ResourceMark rm; |
553 ResourceMark rm; |
554 tty->print_cr("Exception <%s> (" INTPTR_FORMAT ") thrown in compiled method <%s> at PC " INTPTR_FORMAT " for thread " INTPTR_FORMAT "", |
554 log_info(exceptions)("Exception <%s> (" INTPTR_FORMAT |
555 exception->print_value_string(), p2i((address)exception()), nm->method()->print_value_string(), p2i(pc), p2i(thread)); |
555 ") thrown in compiled method <%s> at PC " INTPTR_FORMAT |
|
556 " for thread " INTPTR_FORMAT, |
|
557 exception->print_value_string(), |
|
558 p2i((address)exception()), |
|
559 nm->method()->print_value_string(), p2i(pc), p2i(thread)); |
556 } |
560 } |
557 // for AbortVMOnException flag |
561 // for AbortVMOnException flag |
558 Exceptions::debug_check_abort(exception); |
562 Exceptions::debug_check_abort(exception); |
559 |
563 |
560 // Clear out the exception oop and pc since looking up an |
564 // Clear out the exception oop and pc since looking up an |
581 |
585 |
582 thread->set_vm_result(exception()); |
586 thread->set_vm_result(exception()); |
583 // Set flag if return address is a method handle call site. |
587 // Set flag if return address is a method handle call site. |
584 thread->set_is_method_handle_return(nm->is_method_handle_return(pc)); |
588 thread->set_is_method_handle_return(nm->is_method_handle_return(pc)); |
585 |
589 |
586 if (TraceExceptions) { |
590 if (log_is_enabled(Info, exceptions)) { |
587 ttyLocker ttyl; |
|
588 ResourceMark rm; |
591 ResourceMark rm; |
589 tty->print_cr("Thread " PTR_FORMAT " continuing at PC " PTR_FORMAT " for exception thrown at PC " PTR_FORMAT, |
592 log_info(exceptions)("Thread " PTR_FORMAT " continuing at PC " PTR_FORMAT |
590 p2i(thread), p2i(continuation), p2i(pc)); |
593 " for exception thrown at PC " PTR_FORMAT, |
|
594 p2i(thread), p2i(continuation), p2i(pc)); |
591 } |
595 } |
592 |
596 |
593 return continuation; |
597 return continuation; |
594 JRT_END |
598 JRT_END |
595 |
599 |