From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id DFFDF3858410; Mon, 8 May 2023 07:38:14 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org DFFDF3858410 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1683531494; bh=GNyhDdUWdeTBWTHGkXjnncIPKa4tEVMSCArMF+lhmso=; h=From:To:Subject:Date:In-Reply-To:References:From; b=iFc+clqn4SZXxJpRIYHSvVjVxTr469Di7LDDPBqM5JU/yXnnzPXqK4XbKrLn7+x0h /LFStHuTHIKAfvLRyPKzZymV7GfdRvl8MeyjdGfc1yq3wkgoXHWqVziTeozsQRGTpY zdMNFiJuG57Ybtl/u7uQxesIQPQjC8mrfoeLjsIU= From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/103771] [12/13/14 Regression] Missed vectorization under -mavx512f -mavx512vl after r12-5489 Date: Mon, 08 May 2023 07:38:12 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: missed-optimization, patch X-Bugzilla-Severity: normal X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: pinskia at gcc dot gnu.org X-Bugzilla-Target-Milestone: 13.2 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=3D103771 --- Comment #43 from CVS Commits --- The trunk branch has been updated by Andrew Pinski : https://gcc.gnu.org/g:69f1a8af45d8a42003c21489019ddfb01d88d30d commit r14-573-g69f1a8af45d8a42003c21489019ddfb01d88d30d Author: Andrew Pinski Date: Wed Apr 26 14:55:46 2023 -0700 PHIOPT: Add diamond bb form to factor_out_conditional_conversion So the function factor_out_conditional_conversion already supports diamond shaped bb forms, just need to be called for such a thing. harden-cond-comp.c needed to be changed as we would optimize out the conversion now and that causes the compare hardening not needing to split the block which it was testing. So change it such that there would be no chance of optimization. Also add two testcases that showed the improvement. PR 103771 is solved in ifconvert also for the vectorizer but now it is solved in a general sense. OK? Bootstrapped and tested on x86_64-linux-gnu with no regressions. PR tree-optimization/49959 PR tree-optimization/103771 gcc/ChangeLog: * tree-ssa-phiopt.cc (pass_phiopt::execute): Support Diamond shapped bb form for factor_out_conditional_conversion. gcc/testsuite/ChangeLog: * c-c++-common/torture/harden-cond-comp.c: Change testcase slightly to avoid the new phiopt optimization. * gcc.dg/tree-ssa/abs-2.c: New test. * gcc.dg/tree-ssa/pr103771.c: New test.=