From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 951BD3844769; Tue, 9 Apr 2024 22:58:08 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 951BD3844769 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1712703488; bh=3E040EwkHi8KR724zhdy5SS0n/tTU8hh5lFnexerfKY=; h=From:To:Subject:Date:In-Reply-To:References:From; b=ZvOCOmfQJwxvxRXf/nT9yl8v0FIwFVR6vgC8SXGX5jyMsEx0awQolTVoSvDRXyDwq n2D7cl/YpZWL5xPcYfbSnFM4MZXmEvkQk/c7qx/fJN1TlV6fmgqaxOBb6y25MGzAeg 5dbI0ZDZGTLEse4VPRICR12s5N/oaj58xqnfdnC8= From: "pinskia at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/114666] [14 Regression] Signed single bit comparison miscompile at -O2 Date: Tue, 09 Apr 2024 22:58:08 +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: 14.0 X-Bugzilla-Keywords: wrong-code X-Bugzilla-Severity: normal X-Bugzilla-Who: pinskia at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P1 X-Bugzilla-Assigned-To: pinskia at gcc dot gnu.org X-Bugzilla-Target-Milestone: 14.0 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=3D114666 --- Comment #6 from Andrew Pinski --- Note fixing the `!A ? B : C` pattern generates worse code in this case but = that is a different issue where we don't convert `a <=3D 2` into `a =3D=3D 1` if= we know only 1 could be the value that works (I have a patch which I need to work on for GCC 15).=