https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105765
Bug ID: 105765 Summary: [13 Regression] ICE: Segmentation fault (in ana::region_model::deref_rvalue) Product: gcc Version: 13.0 Status: UNCONFIRMED Keywords: ice-on-valid-code Severity: normal Priority: P3 Component: analyzer Assignee: dmalcolm at gcc dot gnu.org Reporter: asolokha at gmx dot com Target Milestone: --- gcc 13.0.0 20220522 snapshot (g:a60228404f2ac11b5eb66270037ff3fa6bf948e5) ICEs when compiling the following testcase, reduced from clang/testsuite/CodeGen/ms_abi_aarch64.c from the clang 14.0.3 test suite, w/ -fanalyzer: void f4 (int a, ...) { __builtin_ms_va_list ap, ap2; __builtin_ms_va_start (ap, a); __builtin_ms_va_copy (ap2, ap); __builtin_ms_va_end (ap); } % gcc-13.0.0 -fanalyzer -c jhszfd06.c during IPA pass: analyzer jhszfd06.c: In function 'f4': jhszfd06.c:7:3: internal compiler error: Segmentation fault 7 | __builtin_ms_va_copy (ap2, ap); | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 0xedc30f crash_signal /var/tmp/portage/sys-devel/gcc-13.0.0_p20220522/work/gcc-13-20220522/gcc/toplev.cc:322 0x12af921 ana::region_model::deref_rvalue(ana::svalue const*, tree_node*, ana::region_model_context*) const /var/tmp/portage/sys-devel/gcc-13.0.0_p20220522/work/gcc-13-20220522/gcc/analyzer/region-model.cc:2472 0x1311110 get_BT_VALIST_ARG /var/tmp/portage/sys-devel/gcc-13.0.0_p20220522/work/gcc-13-20220522/gcc/analyzer/varargs.cc:183 0x1311449 ana::region_model::impl_call_va_copy(ana::call_details const&) /var/tmp/portage/sys-devel/gcc-13.0.0_p20220522/work/gcc-13-20220522/gcc/analyzer/varargs.cc:670 0x12b2268 ana::region_model::on_call_pre(gcall const*, ana::region_model_context*, bool*) /var/tmp/portage/sys-devel/gcc-13.0.0_p20220522/work/gcc-13-20220522/gcc/analyzer/region-model.cc:1439 0x12c0bc2 ana::region_model::on_stmt_pre(gimple const*, bool*, bool*, ana::region_model_context*) /var/tmp/portage/sys-devel/gcc-13.0.0_p20220522/work/gcc-13-20220522/gcc/analyzer/region-model.cc:1213 0x128bff9 ana::exploded_node::on_stmt(ana::exploded_graph&, ana::supernode const*, gimple const*, ana::program_state*, ana::uncertainty_t*, ana::path_context*) /var/tmp/portage/sys-devel/gcc-13.0.0_p20220522/work/gcc-13-20220522/gcc/analyzer/engine.cc:1383 0x128f3cc ana::exploded_graph::process_node(ana::exploded_node*) /var/tmp/portage/sys-devel/gcc-13.0.0_p20220522/work/gcc-13-20220522/gcc/analyzer/engine.cc:3776 0x12903da ana::exploded_graph::process_worklist() /var/tmp/portage/sys-devel/gcc-13.0.0_p20220522/work/gcc-13-20220522/gcc/analyzer/engine.cc:3219 0x1292ac5 ana::impl_run_checkers(ana::logger*) /var/tmp/portage/sys-devel/gcc-13.0.0_p20220522/work/gcc-13-20220522/gcc/analyzer/engine.cc:5811 0x12939ce ana::run_checkers() /var/tmp/portage/sys-devel/gcc-13.0.0_p20220522/work/gcc-13-20220522/gcc/analyzer/engine.cc:5885 0x1282358 execute /var/tmp/portage/sys-devel/gcc-13.0.0_p20220522/work/gcc-13-20220522/gcc/analyzer/analyzer-pass.cc:87