The inline tree Compile::_ilt is not initialized directly by the initializer list but only later in Compile::Compile() when calling:
_ilt = InlineTree::build_inline_tree_root();
Before this assignment, _ilt contains garbage (i.e. != NULL). When hitting an assert or crash before returning from build_inline_tree_root(), replay compilation is trying to dump the inline tree and fails to notice that the inline tree is still uninitialized. This results in a segmentation fault (tested by adding an artificial assert(false, "asdf")):
# To suppress the following error report, specify this argument
# after -XX: or in .hotspotrc: SuppressErrorAt=/compile.cpp:614
#
# A fatal error has been detected by the Java Runtime Environment:
#
# Internal Error (/home/christian/jdk/open/src/hotspot/share/opto/compile.cpp:614), pid=68690, tid=68698
# assert(false) failed: asdf
#
# JRE version: Java(TM) SE Runtime Environment (18.0) (slowdebug build 18-internal+0-2021-10-04-0649352.christian...)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (slowdebug 18-internal+0-2021-10-04-0649352.christian..., compiled mode, compressed oops, compressed class ptrs, serial gc, linux-amd64)
# Problematic frame:
# V [libjvm.so+0x7aca5c] Compile::Compile(ciEnv*, ciMethod*, int, bool, bool, bool, bool, bool, DirectiveSet*)+0x81c
#
# No core dump will be written. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# An error report file with more information is saved as:
# /home/christian/repro/ciReplay/hs_err_pid68690.log
[error occurred during error reporting (), id 0xb, SIGSEGV (0xb) at pc=0x00007ff6cef2a748]
#
# If you would like to submit a bug report, please visit:
# https://bugreport.java.com/bugreport/crash.jsp
#