From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id D1FB83854813; Wed, 23 Dec 2020 21:48:02 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org D1FB83854813 From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/98353] [8/9/10 Regression] ICE in propagate_necessity, at tree-ssa-dce.c:1053 since r6-4886-gcda0a029f45d20f4 Date: Wed, 23 Dec 2020 21:48:02 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Version: 11.0 X-Bugzilla-Keywords: ice-on-valid-code X-Bugzilla-Severity: normal X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: jakub at gcc dot gnu.org X-Bugzilla-Target-Milestone: 8.5 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: 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: Wed, 23 Dec 2020 21:48:02 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D98353 --- Comment #6 from CVS Commits --- The master branch has been updated by Jakub Jelinek : https://gcc.gnu.org/g:550880a31688f1031a21efe7923c86db423cbbf1 commit r11-6321-g550880a31688f1031a21efe7923c86db423cbbf1 Author: Jakub Jelinek Date: Wed Dec 23 22:45:56 2020 +0100 c++: Fix up floating point complex handling in build_zero_init_1 [PR983= 53] While the gimplifier patch I've just committed fixed an ICE, in some ca= ses like on the committed testcase cp folding doesn't happen after build_zero_init_1 because it is called already during gimplification. For the scalar types, if we want to use convert, the problem with compl= ex floats is that it returns a COMPLEX_EXPR with FLOAT_EXPR arguments which have INTEGER_CST 0 as argument. As fold isn't recursive, it doesn't do anyt= hing in that case, we need to first fold those FLOAT_EXPRs to REAL_CST 0.0 a= nd only afterwards the COMPLEX_EXPR can be folded into COMPLEX_CST with 0.0 arguments. This patch instead just uses build_zero_cst that creates the zero const= ant for any scalar types (and more) directly, instead of going through multiple hops. 2020-12-23 Jakub Jelinek PR c++/98353 * init.c (build_zero_init_1): Use build_zero_cst for SCALAR_TYP= E_P zero initializers.=