From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id ED9C43858D20; Wed, 9 Nov 2022 15:57:41 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org ED9C43858D20 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1668009461; bh=L5XGdjOrQiMvYxDgo/Im5xy3qZ/yb+P29elyHsC0BGo=; h=From:To:Subject:Date:In-Reply-To:References:From; b=YJqU5/IS33tWTOupW6HqSqe07kfF4vFqM2X930VrGcELpZjM3kfLG0/SgWIMUzm8y MSlUMejexznaMziW1ngGXuKXoP6J2ucsRcCJLGQqJs/4HAyqfH7uy10JwjHS4Js9O/ +BdD2sxxP9+TrT/PC1eBrf6mjqSyItf3GQmac6KU= From: "jakub at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/107591] range-op{,-float}.cc for x * x Date: Wed, 09 Nov 2022 15:57:32 +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: 13.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: jakub at gcc dot gnu.org X-Bugzilla-Status: NEW 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: 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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D107591 --- Comment #2 from Jakub Jelinek --- Perhaps before we try to map MULT_EXPR into some irange/frange op the usual way, while we still have access to gimple statement check if it is MULT_EXPR with the same operands and use a different artificial unary op for pow2. We could do this for PLUS_EXPR x + x as well and handle it as 2 * x if we d= on't do that already or if match.pd doesn't already canonicalize x + x that way.=