Skip to content

Commit dc00ae4

Browse files
committed
8299658: C1 compilation crashes in LinearScan::resolve_exception_edge
Backport-of: cf2d33ca2ee08c61596ab10b7602500a6931fa31
1 parent a44f8b0 commit dc00ae4

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/hotspot/share/c1/c1_LinearScan.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1953,6 +1953,14 @@ void LinearScan::resolve_exception_edge(XHandler* handler, int throwing_op_id, i
19531953
// interval at the throwing instruction must be searched using the operands
19541954
// of the phi function
19551955
Value from_value = phi->operand_at(handler->phi_operand());
1956+
if (from_value == nullptr) {
1957+
// We have reached here in a kotlin application running with JVMTI
1958+
// capability "can_access_local_variables".
1959+
// The illegal state is not yet propagated to this phi. Do it here.
1960+
phi->make_illegal();
1961+
// We can skip the illegal phi edge.
1962+
return;
1963+
}
19561964

19571965
// with phi functions it can happen that the same from_value is used in
19581966
// multiple mappings, so notify move-resolver that this is allowed

0 commit comments

Comments
 (0)