From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 54523385840D; Tue, 24 Aug 2021 07:14:33 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 54523385840D From: "rguenth at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: =?UTF-8?B?W0J1ZyBtaWRkbGUtZW5kLzEwMjAyOV0gWzEyIFJlZ3Jlc3Npb25d?= =?UTF-8?B?IGljZTogIGVycm9yOiB0eXBlIG1pc21hdGNoIGluIOKAmGxzaGlmdF9leHBy?= =?UTF-8?B?4oCZ?= Date: Tue, 24 Aug 2021 07:14:33 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: middle-end 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: RESOLVED X-Bugzilla-Resolution: FIXED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: roger at nextmovesoftware dot com X-Bugzilla-Target-Milestone: 12.0 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_status resolution 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, 24 Aug 2021 07:14:33 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D102029 Richard Biener changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |RESOLVED Resolution|--- |FIXED --- Comment #5 from Richard Biener --- (In reply to Roger Sayle from comment #3) > Here's the fix that I'm currently testing... >=20 > (simplify > (convert (lshift:s@0 (convert:s@1 @2) INTEGER_CST@3)) > - (if (tree_nop_conversion_p (type, TREE_TYPE (@0)) > + (if (INTEGRAL_TYPE_P (type) > + && !POINTER_TYPE_P (type) either of both is redundant, I think keeping INTEGRAL_TYPE_P is better. > + && tree_nop_conversion_p (type, TREE_TYPE (@0)) > && INTEGRAL_TYPE_P (TREE_TYPE (@2)) > && TYPE_PRECISION (TREE_TYPE (@2)) <=3D TYPE_PRECISION (type)) > (lshift (convert @2) @3)))=