From patchwork Thu Jan 17 15:02:00 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tamar Christina X-Patchwork-Id: 1026697 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-494243-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=arm.com Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="KpntIDJ+"; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=armh.onmicrosoft.com header.i=@armh.onmicrosoft.com header.b="BAiqIds/"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 43gS3c2T77z9sCh for ; Fri, 18 Jan 2019 02:02:19 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:date:message-id:content-type:mime-version; q=dns; s=default; b=dGyi54xPcxWvdfwdl8fzyK1sBArJaOr/vnKLnFZwl+TTOoyVcA hIZAjp/5zUQk/JhPRBJFxdDqtEebY9Pn5s4QAmRS/x/k+GtLKyN733MCfI+BkojC cMhEuzIF1189SClBiTvDTI14NqsYcC7ESE1wQlsZ5ZbzZIECwaiGpxXAE= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:cc:subject:date:message-id:content-type:mime-version; s= default; bh=c6/RTXD8kuguCmcvv8Ij5Dmvj9M=; b=KpntIDJ+36MThne4J9dL muoYYD7g0Js+7TiIRQPxE9Axs3l8NYiNbC1wt0+agvVAYkVvBMTfpk7HMAyhaSHw M0bvs4OhWcOtREAwB9RJNsUn8/R/mcBFTQii//7OsM8xJ/mEMqhtYf0IV+lEwYPT HMO20oUT4p3rPzv5TgvSdcI= Received: (qmail 88678 invoked by alias); 17 Jan 2019 15:02:12 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 88667 invoked by uid 89); 17 Jan 2019 15:02:11 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-26.9 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE, SPF_HELO_PASS, SPF_PASS autolearn=ham version=3.3.2 spammy=Hx-languages-length:2110, H*c:HHH X-HELO: EUR03-AM5-obe.outbound.protection.outlook.com Received: from mail-eopbgr30052.outbound.protection.outlook.com (HELO EUR03-AM5-obe.outbound.protection.outlook.com) (40.107.3.52) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 17 Jan 2019 15:02:04 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector1-arm-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=KxfC16vgiJcQ7r8NtkQ9F8Y/9sFfcy0sJjUWFXVUZr8=; b=BAiqIds/MxOcqaAuOEVbHNwhz2fFzEC8syTM6aMbMwxHCdo7bkzPaz8viZJ0ZYTbwO8d1OjCmXLxqXIICU/auUSOQ5solUisxcdt1YClj6wI83m5CxYCegWdvFwixbqKOL5b8MteR9Q6Hnvaal3vtylfW4PSr9RMSD4ERmbzPe4= Received: from DB6PR0802MB2309.eurprd08.prod.outlook.com (10.172.228.13) by DB6PR0802MB2566.eurprd08.prod.outlook.com (10.172.252.7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1537.26; Thu, 17 Jan 2019 15:02:01 +0000 Received: from DB6PR0802MB2309.eurprd08.prod.outlook.com ([fe80::ad19:20e5:52a5:b3df]) by DB6PR0802MB2309.eurprd08.prod.outlook.com ([fe80::ad19:20e5:52a5:b3df%7]) with mapi id 15.20.1537.018; Thu, 17 Jan 2019 15:02:01 +0000 From: Tamar Christina To: "gcc-patches@gcc.gnu.org" CC: nd , Ramana Radhakrishnan , Richard Earnshaw , "nickc@redhat.com" , Kyrylo Tkachov Subject: [PATCH][GCC][Arm] Rewrite arm testcase to use intrinsics Date: Thu, 17 Jan 2019 15:02:00 +0000 Message-ID: <20190117150157.GA10148@arm.com> received-spf: None (protection.outlook.com: arm.com does not designate permitted sender hosts) authentication-results: spf=none (sender IP is ) smtp.mailfrom=Tamar.Christina@arm.com; MIME-Version: 1.0 X-IsSubscribed: yes Hi All, This test was added back when builtins were being used instead of ACLE intrinsics. The test as far as I can tell is really testing vcombine, however some of these builtins no longer exist and causes an ICE. This fixes the testcase by changing it to use neon intrinsics. Regtested on arm-none-eabi and no issues. Ok for trunk? Thanks, Tamar gcc/testsuite/ChangeLog: 2019-01-17 Tamar Christina PR target/88850 * gcc.target/arm/pr51968.c: Use neon intrinsics. diff --git a/gcc/testsuite/gcc.target/arm/pr51968.c b/gcc/testsuite/gcc.target/arm/pr51968.c index 99bdb961757bfa62aec5ef1426137425e57898b0..781470223db0d85214bced0b64fda68b4c43967f 100644 --- a/gcc/testsuite/gcc.target/arm/pr51968.c +++ b/gcc/testsuite/gcc.target/arm/pr51968.c @@ -1,14 +1,10 @@ /* PR target/51968 */ /* { dg-do compile } */ -/* { dg-options "-O2 -Wno-implicit-function-declaration -march=armv7-a -mfloat-abi=softfp -mfpu=neon" } */ +/* { dg-options "-O2 -march=armv7-a -mfloat-abi=softfp -mfpu=neon" } */ /* { dg-require-effective-target arm_neon_ok } */ +#include -typedef __builtin_neon_qi int8x8_t __attribute__ ((__vector_size__ (8))); -typedef __builtin_neon_uqi uint8x8_t __attribute__ ((__vector_size__ (8))); -typedef __builtin_neon_qi int8x16_t __attribute__ ((__vector_size__ (16))); -typedef __builtin_neon_hi int16x8_t __attribute__ ((__vector_size__ (16))); -typedef __builtin_neon_si int32x4_t __attribute__ ((__vector_size__ (16))); -struct T { int8x8_t val[2]; }; +struct T { int8x8x2_t val; }; int y; void @@ -17,16 +13,16 @@ foo (int8x8_t z, int8x8_t x, int16x8_t b, int8x8_t n) if (y) { struct T m; - __builtin_neon_vuzpv8qi (&m.val[0], z, x); + m.val = vuzp_s8 (z, x); } for (;;) { int8x16_t g; int8x8_t h, j, k; struct T m; - j = __builtin_neon_vqmovunv8hi (b); - g = __builtin_neon_vcombinev8qi (j, h); - k = __builtin_neon_vget_lowv16qi (g); - __builtin_neon_vuzpv8qi (&m.val[0], k, n); + j = vqmovn_s16 (b); + g = vcombine_s8 (j, h); + k = vget_low_s8 (g); + m.val = vuzp_s8 (k, n); } }