mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-18 10:04:42 +02:00
8271055: Crash during deoptimization with "assert(bb->is_reachable()) failed: getting result from unreachable basicblock" with -XX:+VerifyStack
Co-authored-by: Yi Yang <yyang@openjdk.org> Co-authored-by: Yi Yang <qingfeng.yy@alibaba-inc.com> Reviewed-by: vlivanov, thartmann
This commit is contained in:
parent
b6935dfb86
commit
e44dc638b8
3 changed files with 121 additions and 1 deletions
|
@ -704,6 +704,21 @@ void Deoptimization::unwind_callee_save_values(frame* f, vframeArray* vframe_arr
|
|||
assert(f->is_interpreted_frame(), "must be interpreted");
|
||||
}
|
||||
|
||||
#ifndef PRODUCT
|
||||
static bool falls_through(Bytecodes::Code bc) {
|
||||
switch (bc) {
|
||||
// List may be incomplete. Here we really only care about bytecodes where compiled code
|
||||
// can deoptimize.
|
||||
case Bytecodes::_goto:
|
||||
case Bytecodes::_goto_w:
|
||||
case Bytecodes::_athrow:
|
||||
return false;
|
||||
default:
|
||||
return true;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
// Return BasicType of value being returned
|
||||
JRT_LEAF(BasicType, Deoptimization::unpack_frames(JavaThread* thread, int exec_mode))
|
||||
|
||||
|
@ -801,7 +816,7 @@ JRT_LEAF(BasicType, Deoptimization::unpack_frames(JavaThread* thread, int exec_m
|
|||
// calls. It seems to be hard to tell whether the compiler
|
||||
// has emitted debug information matching the "state before"
|
||||
// a given bytecode or the state after, so we try both
|
||||
if (!Bytecodes::is_invoke(cur_code) && cur_code != Bytecodes::_athrow) {
|
||||
if (!Bytecodes::is_invoke(cur_code) && falls_through(cur_code)) {
|
||||
// Get expression stack size for the next bytecode
|
||||
InterpreterOopMap next_mask;
|
||||
OopMapCache::compute_one_oop_map(mh, str.bci(), &next_mask);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue