8362832: compiler/macronodes/TestTopInMacroElimination.java hits assert(false) failed: unexpected node

Reviewed-by: dlunden, epeter, kvn
This commit is contained in:
Benoît Maillard 2025-11-04 09:42:18 +00:00
parent 19cca0a2a8
commit a98b9e7cfa
3 changed files with 6 additions and 4 deletions

View File

@ -501,6 +501,11 @@ Node *PhaseMacroExpand::value_from_mem(Node *sfpt_mem, Node *sfpt_ctl, BasicType
}
} else if (mem->is_ArrayCopy()) {
done = true;
} else if (mem->is_top()) {
// The slice is on a dead path. Returning nullptr would lead to elimination
// bailout, but we want to prevent that. Just forwarding the top is also legal,
// and IGVN can just clean things up, and remove whatever receives top.
return mem;
} else {
DEBUG_ONLY( mem->dump(); )
assert(false, "unexpected node");

View File

@ -27,9 +27,6 @@
#
#############################################################################
compiler/macronodes/TestTopInMacroElimination.java 8362832 generic-all
gc/stringdedup/TestStringDeduplicationAgeThreshold.java 8362562 generic-all
gc/stringdedup/TestStringDeduplicationInterned.java 8362562 generic-all
gc/stringdedup/TestStringDeduplicationPrintOptions.java 8362562 generic-all

View File

@ -23,7 +23,7 @@
/*
* @test
* @bug 8325030
* @bug 8325030 8362832
* @summary Regression test for an assert triggered during allocation elimination because top is found during
* constructing new phis.
* @run main/othervm -XX:-ProfileExceptionHandlers compiler.macronodes.TestTopInMacroElimination