From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id C38103898526; Thu, 30 Apr 2020 14:42:38 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org C38103898526 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1588257758; bh=aP8of4mnRdVGIUuVfIapzTKY0u9hj1OJO6XMZzyvS2M=; h=From:To:Subject:Date:In-Reply-To:References:From; b=uco0H8ck9kYYh7wuAcZZZWe/WIhMruiQhLfBbOINjodw0/09DNKnfEPIUcIVO8Adk T47n/alYa4ROiN8jIiIE6yHDdLX0TvPcuY6OBjqZLbk02HAhKd7Pd10Ytsw2ZbTOq3 jIcDjUazdDo8QmeSUz3VQXVD94Cp5ICrAies7cWs= From: "gabravier at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c/94889] Negate function not getting optimised to negate call Date: Thu, 30 Apr 2020 14:42:38 +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: 9.3.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: gabravier at gmail dot com X-Bugzilla-Status: UNCONFIRMED 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: cc 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: Thu, 30 Apr 2020 14:42:38 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D94889 Gabriel Ravier changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |gabravier at gmail dot com --- Comment #1 from Gabriel Ravier --- For some reason, I can reproduce this, but only if `-mavx2` is not present. Having AVX2 enabled somehow ends up makes it so this is optimized to a `ret= urn ~x`. (Also, this means that it is a bitwise not and not a negate that this should optimize down to)=