https://gcc.gnu.org/bugzilla/show_bug.cgi?id=124139
Bug ID: 124139
Summary: [16 Regression] ICE: in call_info, at
analyzer/call-info.cc:149 with -fanalyzer
--param=analyzer-max-svalue-depth=0 and C++ throw
Product: gcc
Version: 16.0
Status: UNCONFIRMED
Keywords: ice-on-valid-code
Severity: normal
Priority: P3
Component: analyzer
Assignee: dmalcolm at gcc dot gnu.org
Reporter: zsojka at seznam dot cz
Target Milestone: ---
Host: x86_64-pc-linux-gnu
Target: x86_64-pc-linux-gnu
Created attachment 63697
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=63697&action=edit
reduced testcase
Compiler output:
$ x86_64-pc-linux-gnu-g++ -fanalyzer --param=analyzer-max-svalue-depth=0
testcase.C
during IPA pass: analyzer
testcase.C: In function 'void foo()':
testcase.C:1:14: internal compiler error: in call_info, at
analyzer/call-info.cc:149
1 | void foo() { throw; }
| ^~~~~
0x301d27d internal_error(char const*, ...)
/repo/gcc-trunk/gcc/diagnostic-global-context.cc:787
0xf22917 fancy_abort(char const*, int, char const*)
/repo/gcc-trunk/gcc/diagnostics/context.cc:1812
0xee80f5 ana::call_info::call_info(ana::call_details const&)
/repo/gcc-trunk/gcc/analyzer/call-info.cc:149
0xee80f5 ana::call_info::call_info(ana::call_details const&)
/repo/gcc-trunk/gcc/analyzer/call-info.cc:145
0x1e4feb0 ana::throw_custom_edge::throw_custom_edge(ana::call_details const&,
tree_node*, bool)
/repo/gcc-trunk/gcc/analyzer/engine.cc:1545
0x1e4feb0 std::__detail::_MakeUniq<ana::throw_custom_edge>::__single_object
std::make_unique<ana::throw_custom_edge, ana::call_details&, tree_node*&,
bool&>(ana::call_details&, tree_node*&, bool&)
/usr/lib/gcc/x86_64-pc-linux-gnu/15/include/g++-v15/bits/unique_ptr.h:1084
0x1e4feb0 ana::exploded_node::on_throw(ana::exploded_graph&, gcall const&,
ana::program_point const&, ana::program_state*, bool,
ana::region_model_context*)
/repo/gcc-trunk/gcc/analyzer/engine.cc:1836
0x1e6d6d8 ana::cxa_throw_op::execute(ana::operation_context&) const
/repo/gcc-trunk/gcc/analyzer/ops.cc:1205
0x1e522eb ana::exploded_graph::process_node(ana::exploded_node*)
/repo/gcc-trunk/gcc/analyzer/engine.cc:3780
0x1e5297a ana::exploded_graph::process_worklist()
/repo/gcc-trunk/gcc/analyzer/engine.cc:3409
0x1e553fb ana::impl_run_checkers(ana::logger*)
/repo/gcc-trunk/gcc/analyzer/engine.cc:5269
0x1e56226 ana::run_checkers()
/repo/gcc-trunk/gcc/analyzer/engine.cc:5360
0x1e46b98 execute
/repo/gcc-trunk/gcc/analyzer/analyzer-pass.cc:81
/repo/gcc-trunk/binary-trunk-20260216182635-r16-7532-g716ec14c573c7e-checking-yes-rtl-df-extra-nobootstrap-amd64/bin/../libexec/gcc/x86_64-pc-linux-gnu/16.0.1/cc1plus
-quiet -iprefix
/repo/gcc-trunk/binary-trunk-20260216182635-r16-7532-g716ec14c573c7e-checking-yes-rtl-df-extra-nobootstrap-amd64/bin/../lib/gcc/x86_64-pc-linux-gnu/16.0.1/
-D_GNU_SOURCE testcase.C -quiet -dumpdir a- -dumpbase testcase.C -dumpbase-ext
.C -mtune=generic -march=x86-64 -fanalyzer --param=analyzer-max-svalue-depth=0
-o /tmp/ccvT8THB.s
Please submit a full bug report, with preprocessed source (by using
-freport-bug).
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
$ x86_64-pc-linux-gnu-g++ -v
Using built-in specs.
COLLECT_GCC=/repo/gcc-trunk/binary-latest-amd64/bin/x86_64-pc-linux-gnu-g++
COLLECT_LTO_WRAPPER=/repo/gcc-trunk/binary-trunk-20260216182635-r16-7532-g716ec14c573c7e-checking-yes-rtl-df-extra-nobootstrap-amd64/bin/../libexec/gcc/x86_64-pc-linux-gnu/16.0.1/lto-wrapper
Target: x86_64-pc-linux-gnu
Configured with: /repo/gcc-trunk//configure --enable-languages=c,c++
--enable-valgrind-annotations --disable-nls --enable-checking=yes,rtl,df,extra
--disable-bootstrap --build=x86_64-pc-linux-gnu --host=x86_64-pc-linux-gnu
--target=x86_64-pc-linux-gnu --with-ld=/usr/bin/x86_64-pc-linux-gnu-ld
--with-as=/usr/bin/x86_64-pc-linux-gnu-as --enable-libsanitizer
--disable-libstdcxx-pch
--prefix=/repo/gcc-trunk//binary-trunk-20260216182635-r16-7532-g716ec14c573c7e-checking-yes-rtl-df-extra-nobootstrap-amd64
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 16.0.1 20260216 (experimental) (GCC)