https://gcc.gnu.org/bugzilla/show_bug.cgi?id=126903
Bug ID: 126903
Summary: ICE in throw_of_unexpected_type with C++14
Product: gcc
Version: 17.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: analyzer
Assignee: dmalcolm at gcc dot gnu.org
Reporter: s.kimura.h41104 at gmail dot com
Target Milestone: ---
Compiler Explorer: https://godbolt.org/z/bfvWY9nh6
Reproducer:
```
int foo();
void bar() throw() { foo(); }
```
Backtrace:
during IPA pass: analyzer
<source>: In function 'void bar()':
<source>:3:6: internal compiler error: in throw_of_unexpected_type, at
analyzer/kf-lang-cp.cc:274
3 | void bar() throw() { foo(); }
| ^~~
0x2bc0f98 diagnostics::context::diagnostic_impl(rich_location*,
diagnostics::metadata const*, diagnostics::option_id, char const*,
__va_list_tag (*) [1], diagnostics::kind)
???:0
0x2bb5bdb internal_error(char const*, ...)
???:0
0xb45456 fancy_abort(char const*, int, char const*)
???:0
0x1a54f20 ana::kf_cxa_call_unexpected::impl_call_pre(ana::call_details const&)
const
???:0
0x1a7c376 ana::region_model::on_call_pre(gcall const&,
ana::region_model_context*)
???:0
0x1a7f48f ana::region_model::on_stmt_pre(gimple const*, bool*,
ana::region_model_context*)
???:0
0x1a59f7d ana::gimple_stmt_op::execute_on_state(ana::operation_context&,
ana::program_state) const
???:0
0x1a5abf2 ana::call_and_return_op::execute(ana::operation_context&) const
???:0
0x1a392d7 ana::exploded_graph::process_node(ana::exploded_node*)
???:0
0x1a39802 ana::exploded_graph::process_worklist()
???:0
0x1a3bebf ana::impl_run_checkers(ana::logger*)
???:0
0x1a3cb46 ana::run_checkers()
???:0
This ICE goes back to gcc-16:
https://godbolt.org/z/f9eTM9f7s