From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id E2D153858406; Tue, 4 Jan 2022 10:21:16 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org E2D153858406 From: "rguenth at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/103690] [12 Regression] ICE: in build2, at tree.c:4985 with -g -O2 -fno-tree-dce -fno-tree-dse -fno-tree-fre --param=max-jump-thread-duplication-stmts=94 since r12-2591-g2e96b5f14e402569 Date: Tue, 04 Jan 2022 10:21:16 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: tree-optimization X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: ice-on-valid-code X-Bugzilla-Severity: normal X-Bugzilla-Who: rguenth at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P1 X-Bugzilla-Assigned-To: rguenth at gcc dot gnu.org X-Bugzilla-Target-Milestone: 12.0 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: priority bug_status assigned_to Message-ID: In-Reply-To: References: 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: Tue, 04 Jan 2022 10:21:17 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D103690 Richard Biener changed: What |Removed |Added ---------------------------------------------------------------------------- Priority|P3 |P1 Status|NEW |ASSIGNED Assignee|unassigned at gcc dot gnu.org |rguenth at gcc dot = gnu.org --- Comment #6 from Richard Biener --- Value numbering stmt =3D __trans_tmp_1_14 =3D _24 + 4; Setting value number of __trans_tmp_1_14 to __trans_tmp_1_22 (changed) what we do is avoiding useless work during elimination, not visiting if (0) guarded code - those regions will have not up-to-date SSA form. Block 14: BB5 found not executable the issue is that PRE does /* Because we don't follow exactly the standard PRE algorithm, and decide= not to insert PHI nodes sometimes, and because value numbering of casts is= n't perfect, we sometimes end up inserting dead code. This simple DCE-li= ke pass removes any insertions we made that weren't actually used. */ simple_dce_from_worklist (inserted_exprs); which eventually runs into those uses for expressions we inserted into those unreachable blocks. The issue is long latent I think.=