https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96642

            Bug ID: 96642
           Summary: [11 Regression] ICE in in apply_ctor_to_region, at
                    analyzer/store.cc:418
           Product: gcc
           Version: 11.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: analyzer
          Assignee: dmalcolm at gcc dot gnu.org
          Reporter: asolokha at gmx dot com
  Target Milestone: ---

gcc-11.0.0-alpha20200816 snapshot (g:c99116aeeb9644ebddec653ee8b19de4d38b65bd)
ICEs when compiling the following testcase w/ -fanalyzer:

void
ut (void)
{
  struct {
    char *cc;
  } sr[] = {
    0, 0, 0, 0, 0, 0, 0, 0, 0, "", "", 0, "", 0, 0, "",
    0, 0, "", 0, 0, "", 0, 0, "", 0, 0, "", 0, 0, 0, 0, 0,
  };
}

% gcc-11.0.0 -fanalyzer -c q9xpzl6a.c
during IPA pass: analyzer
q9xpzl6a.c: In function 'ut':
q9xpzl6a.c:6:5: internal compiler error: in apply_ctor_to_region, at
analyzer/store.cc:418
    6 |   } sr[] = {
      |     ^~
0x723164 ana::binding_map::apply_ctor_to_region(ana::region const*, tree_node*,
ana::region_model_manager*)
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200816/work/gcc-11-20200816/gcc/analyzer/store.cc:418
0x113c937 ana::binding_map::apply_ctor_to_region(ana::region const*,
tree_node*, ana::region_model_manager*)
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200816/work/gcc-11-20200816/gcc/analyzer/store.cc:415
0x11089f6
ana::decl_region::maybe_get_constant_value(ana::region_model_manager*) const
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200816/work/gcc-11-20200816/gcc/analyzer/region.cc:896
0x110ce92 ana::region_model::get_store_value(ana::region const*) const
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200816/work/gcc-11-20200816/gcc/analyzer/region-model.cc:1197
0x110f478 ana::region_model::get_rvalue(ana::path_var,
ana::region_model_context*)
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200816/work/gcc-11-20200816/gcc/analyzer/region-model.cc:1173
0x110f478 ana::region_model::get_rvalue(tree_node*, ana::region_model_context*)
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200816/work/gcc-11-20200816/gcc/analyzer/region-model.cc:1186
0x1111ef4 ana::region_model::on_assignment(gassign const*,
ana::region_model_context*)
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200816/work/gcc-11-20200816/gcc/analyzer/region-model.cc:547
0x10f3022 ana::exploded_node::on_stmt(ana::exploded_graph&, ana::supernode
const*, gimple const*, ana::program_state*) const
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200816/work/gcc-11-20200816/gcc/analyzer/engine.cc:1029
0x10f426d ana::exploded_graph::process_node(ana::exploded_node*)
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200816/work/gcc-11-20200816/gcc/analyzer/engine.cc:2526
0x10f4d5a ana::exploded_graph::process_worklist()
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200816/work/gcc-11-20200816/gcc/analyzer/engine.cc:2341
0x10f6e8f ana::impl_run_checkers(ana::logger*)
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200816/work/gcc-11-20200816/gcc/analyzer/engine.cc:4107
0x10f7aac ana::run_checkers()
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200816/work/gcc-11-20200816/gcc/analyzer/engine.cc:4175
0x10ec468 execute
       
/var/tmp/portage/sys-devel/gcc-11.0.0_alpha20200816/work/gcc-11-20200816/gcc/analyzer/analyzer-pass.cc:84

Reply via email to