From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 80235 invoked by alias); 9 Nov 2015 16:30:10 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 80220 invoked by uid 89); 9 Nov 2015 16:30:09 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.5 required=5.0 tests=AWL,BAYES_00,SPF_PASS autolearn=ham version=3.3.2 X-HELO: eu-smtp-delivery-143.mimecast.com Received: from eu-smtp-delivery-143.mimecast.com (HELO eu-smtp-delivery-143.mimecast.com) (207.82.80.143) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 09 Nov 2015 16:30:09 +0000 Received: from cam-owa1.Emea.Arm.com (fw-tnat.cambridge.arm.com [217.140.96.140]) by eu-smtp-1.mimecast.com with ESMTP id uk-mta-18-1KGrJeYRQbSyaEQPQGnp1g-1; Mon, 09 Nov 2015 16:30:03 +0000 Received: from localhost ([10.1.2.79]) by cam-owa1.Emea.Arm.com with Microsoft SMTPSVC(6.0.3790.3959); Mon, 9 Nov 2015 16:30:02 +0000 From: Richard Sandiford To: gcc-patches@gcc.gnu.org Mail-Followup-To: gcc-patches@gcc.gnu.org,dje.gcc@gmail.com, richard.sandiford@arm.com Cc: dje.gcc@gmail.com Subject: [PATCH 5/6] Simplify rs6000_builtin_vectorized_function References: <87io5bno02.fsf@e105548-lin.cambridge.arm.com> Date: Mon, 09 Nov 2015 16:30:00 -0000 In-Reply-To: <87io5bno02.fsf@e105548-lin.cambridge.arm.com> (Richard Sandiford's message of "Mon, 09 Nov 2015 16:20:13 +0000") Message-ID: <87wptrm8z9.fsf@e105548-lin.cambridge.arm.com> User-Agent: Gnus/5.130012 (Ma Gnus v0.12) Emacs/24.3 (gnu/linux) MIME-Version: 1.0 X-MC-Unique: 1KGrJeYRQbSyaEQPQGnp1g-1 Content-Type: text/plain; charset=WINDOWS-1252 Content-Transfer-Encoding: quoted-printable X-SW-Source: 2015-11/txt/msg01010.txt.bz2 After the previous patches it's no longer necessary for TARGET_BUILTIN_VECTORIZED_FUNCTION to return functions that map to the vector optab of the original operation. We'll use a vector form of the internal function instead. gcc/ * config/rs6000/rs6000.c (rs6000_builtin_vectorized_function): Remove entries that map directly to optabs. diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index 26a0410..aa55b8e 100644 --- a/gcc/config/rs6000/rs6000.c +++ b/gcc/config/rs6000/rs6000.c @@ -4913,19 +4913,6 @@ rs6000_builtin_vectorized_function (unsigned int fn,= tree type_out, =20 switch (fn) { - CASE_CFN_CLZ: - if (TARGET_P8_VECTOR && in_mode =3D=3D out_mode && out_n =3D=3D in_n) - { - if (out_mode =3D=3D QImode && out_n =3D=3D 16) - return rs6000_builtin_decls[P8V_BUILTIN_VCLZB]; - else if (out_mode =3D=3D HImode && out_n =3D=3D 8) - return rs6000_builtin_decls[P8V_BUILTIN_VCLZH]; - else if (out_mode =3D=3D SImode && out_n =3D=3D 4) - return rs6000_builtin_decls[P8V_BUILTIN_VCLZW]; - else if (out_mode =3D=3D DImode && out_n =3D=3D 2) - return rs6000_builtin_decls[P8V_BUILTIN_VCLZD]; - } - break; CASE_CFN_COPYSIGN: if (VECTOR_UNIT_VSX_P (V2DFmode) && out_mode =3D=3D DFmode && out_n =3D=3D 2 @@ -4940,29 +4927,6 @@ rs6000_builtin_vectorized_function (unsigned int fn,= tree type_out, && in_mode =3D=3D SFmode && in_n =3D=3D 4) return rs6000_builtin_decls[ALTIVEC_BUILTIN_COPYSIGN_V4SF]; break; - CASE_CFN_POPCOUNT: - if (TARGET_P8_VECTOR && in_mode =3D=3D out_mode && out_n =3D=3D in_n) - { - if (out_mode =3D=3D QImode && out_n =3D=3D 16) - return rs6000_builtin_decls[P8V_BUILTIN_VPOPCNTB]; - else if (out_mode =3D=3D HImode && out_n =3D=3D 8) - return rs6000_builtin_decls[P8V_BUILTIN_VPOPCNTH]; - else if (out_mode =3D=3D SImode && out_n =3D=3D 4) - return rs6000_builtin_decls[P8V_BUILTIN_VPOPCNTW]; - else if (out_mode =3D=3D DImode && out_n =3D=3D 2) - return rs6000_builtin_decls[P8V_BUILTIN_VPOPCNTD]; - } - break; - CASE_CFN_SQRT: - if (VECTOR_UNIT_VSX_P (V2DFmode) - && out_mode =3D=3D DFmode && out_n =3D=3D 2 - && in_mode =3D=3D DFmode && in_n =3D=3D 2) - return rs6000_builtin_decls[VSX_BUILTIN_XVSQRTDP]; - if (VECTOR_UNIT_VSX_P (V4SFmode) - && out_mode =3D=3D SFmode && out_n =3D=3D 4 - && in_mode =3D=3D SFmode && in_n =3D=3D 4) - return rs6000_builtin_decls[VSX_BUILTIN_XVSQRTSP]; - break; CASE_CFN_CEIL: if (VECTOR_UNIT_VSX_P (V2DFmode) && out_mode =3D=3D DFmode && out_n =3D=3D 2