From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 393293858D35; Tue, 31 Jan 2023 04:55:06 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 393293858D35 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1675140906; bh=cW6kCQPEbsIyJuLaghM8v+tRXMXI4o6+mj9KR5ufGMo=; h=From:To:Subject:Date:In-Reply-To:References:From; b=oekGc/ejpYauox+TqsirFe4jwg2Ndi26wUrc5dUnSNRtBXTSqUgwuvI1XANAlUl13 y8J5QCSQ8rTytefrCDqLdyhRJ2/Mma0Cdaa4I8qgIuvuJHjpksJOb2GU1dkBvBS827 z/+dSbBP5SL53WL9BjWps4PHplUvIaKmyVMnofHg= From: "pinskia at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/96921] Failure to optimize combined boolean not patterns Date: Tue, 31 Jan 2023 04:55:05 +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: 11.0 X-Bugzilla-Keywords: missed-optimization X-Bugzilla-Severity: enhancement X-Bugzilla-Who: pinskia at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: pinskia 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=3D96921 --- Comment #9 from Andrew Pinski --- (In reply to Andrew Pinski from comment #3) > So something like: > (simplify > (minus integer_one@0 SSA_NAME@1) > (if (TREE_CODE (@0) =3D=3D SSA_NAME > && ssa_name_has_boolean_range (@0)) > (bit_xor @1 @0))) I ended up with this only in the end (I actually came up with this the seco= nd time too) as it fixes a regression The expanded one should wait and might be worse.=