src/share/vm/c1/c1_Optimizer.cpp

Print this page
rev 2898 : 7123108: C1: assert(if_state != NULL) failed: states do not match up
Summary: In CEE, ensure if and common successor state are at the same inline level
Reviewed-by:

*** 123,136 **** --- 123,143 ---- // check if at least one word was pushed on sux_state // inlining depths must match ValueStack* if_state = if_->state(); ValueStack* sux_state = sux->state(); + if (if_state->scope()->level() > sux_state->scope()->level()) { while (sux_state->scope() != if_state->scope()) { if_state = if_state->caller_state(); assert(if_state != NULL, "states do not match up"); } + } else if (if_state->scope()->level() < sux_state->scope()->level()) { + while (sux_state->scope() != if_state->scope()) { + sux_state = sux_state->caller_state(); + assert(sux_state != NULL, "states do not match up"); + } + } if (sux_state->stack_size() <= if_state->stack_size()) return; // check if phi function is present at end of successor stack and that // only this phi was pushed on the stack