From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 17896385700A; Thu, 27 May 2021 01:28:13 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 17896385700A From: "cnsun at uwaterloo dot ca" To: gcc-bugs@gcc.gnu.org Subject: [Bug c/100786] New: ICE: in fold_convert_loc, at fold-const.c:2429 Date: Thu, 27 May 2021 01:28:12 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c X-Bugzilla-Version: tree-ssa X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: cnsun at uwaterloo dot ca X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned 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 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 27 May 2021 01:28:13 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D100786 Bug ID: 100786 Summary: ICE: in fold_convert_loc, at fold-const.c:2429 Product: gcc Version: tree-ssa Status: UNCONFIRMED Severity: normal Priority: P3 Component: c Assignee: unassigned at gcc dot gnu.org Reporter: cnsun at uwaterloo dot ca Target Milestone: --- $ gcc-trunk -v Using built-in specs. COLLECT_GCC=3Dgcc-trunk COLLECT_LTO_WRAPPER=3D/scratch/software/gcc-trunk/libexec/gcc/x86_64-pc-lin= ux-gnu/12.0.0/lto-wrapper Target: x86_64-pc-linux-gnu Configured with: /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/configure --enable-languages=3Dc,c++,lto --enable-checking-yes --enable-multiarch --prefix=3D/scratch/software/gcc-trunk --disable-bootstrap Thread model: posix Supported LTO compression algorithms: zlib gcc version 12.0.0 20210526 (experimental) [master revision :21638bbbf:1fd76b24306ed4df4cf9e797d900699ed59ce7f7] (GCC) $ cat mutant.c const double a =3D 0; extern b __attribute__((alias("a"))); inc() { b++; } $ gcc-trunk mutant.c mutant.c:2:8: warning: type defaults to =E2=80=98int=E2=80=99 in declaratio= n of =E2=80=98b=E2=80=99 [-Wimplicit-int] 2 | extern b __attribute__((alias("a"))); | ^ mutant.c:3:1: warning: return type defaults to =E2=80=98int=E2=80=99 [-Wimp= licit-int] 3 | inc() { b++; } | ^~~ mutant.c: In function =E2=80=98inc=E2=80=99: mutant.c:3:10: internal compiler error: in fold_convert_loc, at fold-const.c:2429 3 | inc() { b++; } | ~^~ 0x6bfba3 fold_convert_loc(unsigned int, tree_node*, tree_node*) /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/fold-const.c:2429 0xc085b7 fold_stmt_1 /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimple-fold.c:6251 0xc3cbf2 gimplify_modify_expr /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimplify.c:6000 0xc2c1f8 gimplify_expr(tree_node**, gimple**, gimple**, bool (*)(tree_node*= ), int) /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimplify.c:13965 0xc2fb2a gimplify_stmt(tree_node**, gimple**) /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimplify.c:6883 0xc31ce6 gimplify_and_add(tree_node*, gimple**) /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimplify.c:492 0xc31ce6 internal_get_tmp_var /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimplify.c:645 0xc2b777 gimplify_expr(tree_node**, gimple**, gimple**, bool (*)(tree_node*= ), int) /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimplify.c:14954 0xc2bf91 gimplify_expr(tree_node**, gimple**, gimple**, bool (*)(tree_node*= ), int) /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimplify.c:14720 0xc3ca07 gimplify_modify_expr /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimplify.c:5824 0xc2c1f8 gimplify_expr(tree_node**, gimple**, gimple**, bool (*)(tree_node*= ), int) /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimplify.c:13965 0xc2fb2a gimplify_stmt(tree_node**, gimple**) /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimplify.c:6883 0xc3035e gimplify_bind_expr /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimplify.c:1424 0xc2c593 gimplify_expr(tree_node**, gimple**, gimple**, bool (*)(tree_node*= ), int) /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimplify.c:14166 0xc2fb2a gimplify_stmt(tree_node**, gimple**) /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimplify.c:6883 0xc31123 gimplify_body(tree_node*, bool) /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimplify.c:15210 0xc31571 gimplify_function_tree(tree_node*) /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/gimplify.c:15364 0xa842c7 cgraph_node::analyze() /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/cgraphunit.c:670 0xa871f1 analyze_functions /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/cgraphunit.c:1234 0xa87cc1 symbol_table::finalize_compilation_unit() /tmp/tmp.tVhv2eaPzV-gcc-builder/gcc/gcc/cgraphunit.c:2508 Please submit a full bug report, with preprocessed source if appropriate. Please include the complete backtrace with any bug report. See for instructions.=