From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 06C263864830; Fri, 19 Apr 2024 01:55:29 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 06C263864830 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1713491730; bh=343YEIQQiTLjprM29aQKTqBOPTS31bbJ/GOAbL+fEZ4=; h=From:To:Subject:Date:From; b=RQmiNAqoFqOp3KvnqYpwNWi1Q+/fDMPJwZwmcmXa2rX3vrzHeEIojc3bu8eJRwb3X geCAD49dSM8I8mrFhjJfVPynx3e49m8O+rIXYcUWAmuCaWmSK5eXaj6+3h6JYVtB2M MePIelGZLS2qDsQ3TNtGMOzTsFIRyreR1QDIfp/0= From: "iamanonymous.cs at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug analyzer/114778] New: ICE: internal compiler error: in get_region_for_local, at analyzer/region.cc:1366 Date: Fri, 19 Apr 2024 01:55:29 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: analyzer X-Bugzilla-Version: 14.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: iamanonymous.cs at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: dmalcolm at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D114778 Bug ID: 114778 Summary: ICE: internal compiler error: in get_region_for_local, at analyzer/region.cc:1366 Product: gcc Version: 14.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: analyzer Assignee: dmalcolm at gcc dot gnu.org Reporter: iamanonymous.cs at gmail dot com Target Milestone: --- Compiler Explorer: https://godbolt.org/z/r3E89h944 ***************************************************************************= **** OS and Platform: $ uname -a: Linux ubuntu 4.15.0-213-generic #224-Ubuntu SMP Mon Jun 19 13:30:12 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux ***************************************************************************= **** gcc version: $ gcc -v Using built-in specs. COLLECT_GCC=3D/root/gcc_set/202404101100/bin/gcc COLLECT_LTO_WRAPPER=3D/root/gcc_set/202404101100/libexec/gcc/x86_64-pc-linu= x-gnu/14.0.1/lto-wrapper Target: x86_64-pc-linux-gnu Configured with: ../gcc/configure --prefix=3D/root/gcc_set/202404101100 --with-gmp=3D/root/build_essential --with-mpfr=3D/root/build_essential --with-mpc=3D/root/build_essential --enable-languages=3Dc,c++ --disable-mul= tilib --with-sanitizer=3Daddress,undefined,thread,leak Thread model: posix Supported LTO compression algorithms: zlib gcc version 14.0.1 20240410 (experimental) (GCC)=20 git version: 0774240b4df9a9bc48ce33a9625788e402498f5a ***************************************************************************= **** Program: $ cat mutant.c int b; int a(char *c) { return c[9]; } void d() { struct e { char g[b] } f(struct e arg) { a(arg.g); } if (f !=3D 'd') ; } ***************************************************************************= **** Command Lines: $ gcc -fanalyzer -c mutant.c mutant.c: In function =E2=80=98d=E2=80=99: mutant.c:6:3: warning: no semicolon at end of struct or union 6 | } f(struct e arg) { | ^ mutant.c:9:9: warning: comparison between pointer and integer 9 | if (f !=3D 'd') | ^~ during IPA pass: analyzer mutant.c: In function =E2=80=98a=E2=80=99: mutant.c:2:26: internal compiler error: in get_region_for_local, at analyzer/region.cc:1366 2 | int a(char *c) { return c[9]; } | ~^~~ 0x88c303 ana::frame_region::get_region_for_local(ana::region_model_manager*, tree_node*, ana::region_model_context const*) const ../../gcc/gcc/analyzer/region.cc:1366 0x14815a2 ana::region_model::get_lvalue(ana::path_var, ana::region_model_context*) const ../../gcc/gcc/analyzer/region-model.cc:2466 0x148541a ana::region_model::get_rvalue_1(ana::path_var, ana::region_model_context*) const ../../gcc/gcc/analyzer/region-model.cc:2532 0x1481ccc ana::region_model::get_rvalue(ana::path_var, ana::region_model_context*) const ../../gcc/gcc/analyzer/region-model.cc:2610 0x2173639 ana::region_model::check_region_bounds(ana::region const*, ana::access_direction, ana::svalue const*, ana::region_model_context*) const ../../gcc/gcc/analyzer/bounds-checking.cc:1396 0x147f3c9 ana::region_model::check_region_access(ana::region const*, ana::access_direction, ana::svalue const*, ana::region_model_context*) const ../../gcc/gcc/analyzer/region-model.cc:3095 0x147f3c9 ana::region_model::check_region_access(ana::region const*, ana::access_direction, ana::svalue const*, ana::region_model_context*) const ../../gcc/gcc/analyzer/region-model.cc:3084 0x147f3c9 ana::region_model::check_region_for_read(ana::region const*, ana::region_model_context*) const ../../gcc/gcc/analyzer/region-model.cc:3129 0x147f3c9 ana::region_model::check_region_for_read(ana::region const*, ana::region_model_context*) const ../../gcc/gcc/analyzer/region-model.cc:3126 0x147f3c9 ana::region_model::get_store_value(ana::region const*, ana::region_model_context*) const ../../gcc/gcc/analyzer/region-model.cc:2690 0x1481ccc ana::region_model::get_rvalue(ana::path_var, ana::region_model_context*) const ../../gcc/gcc/analyzer/region-model.cc:2610 0x148664c ana::region_model::on_assignment(gassign const*, ana::region_model_context*) ../../gcc/gcc/analyzer/region-model.cc:1244 0x144daf0 ana::exploded_node::on_stmt(ana::exploded_graph&, ana::supernode const*, gimple const*, ana::program_state*, ana::uncertainty_t*, bool*, ana::path_context*) ../../gcc/gcc/analyzer/engine.cc:1515 0x1450915 ana::exploded_graph::process_node(ana::exploded_node*) ../../gcc/gcc/analyzer/engine.cc:4125 0x145166a ana::exploded_graph::process_worklist() ../../gcc/gcc/analyzer/engine.cc:3516 0x1453c4b ana::impl_run_checkers(ana::logger*) ../../gcc/gcc/analyzer/engine.cc:6210 0x1454bb6 ana::run_checkers() ../../gcc/gcc/analyzer/engine.cc:6308 0x1443a98 execute ../../gcc/gcc/analyzer/analyzer-pass.cc:87 Please submit a full bug report, with preprocessed source (by using -freport-bug). Please include the complete backtrace with any bug report. See for instructions.=