From patchwork Thu Nov 27 10:03:28 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kyrylo Tkachov X-Patchwork-Id: 415421 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org 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 BBC9D1401DC for ; Thu, 27 Nov 2014 21:03:58 +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 :message-id:date:from:mime-version:to:cc:subject:references :in-reply-to:content-type; q=dns; s=default; b=rIpeqE2kMUqrPQFRX s65WMZ5pRw3J7PTplOA6RmQwfA9c5zZ5zp4pB3sHhJG5D735llZ/tb+XxRDx9sG+ 4sqsRk2OzoETEoTux3nfWR25mJQDb6AtRi+XTxoH3EgCay8Coo2c3lBaOBB9x/bU mCyIlwpdo+IHKUrQq/rrwDoBOM= 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 :message-id:date:from:mime-version:to:cc:subject:references :in-reply-to:content-type; s=default; bh=c2zzYRmR+bZoCg4RkkItAM1 nT/s=; b=LEjpTQuwQtb1z+sIScNBK6rfQrv6AIYnPLnMGEt2lwZS80W+VRvkXtZ HnjYN2y16lqbdBsHoefHcqrSuCcDG6T5Myu/raoUfMwLw9YjhVdDR3LxUxazIbcY GFdiX5/d4NIeokLWC20AjavHsvJQrOLCejeYHRNx10NVtFCmkD0c= Received: (qmail 13721 invoked by alias); 27 Nov 2014 10:03:36 -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 13585 invoked by uid 89); 27 Nov 2014 10:03:35 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.8 required=5.0 tests=AWL, BAYES_00, SPF_PASS autolearn=ham version=3.3.2 X-HELO: service87.mimecast.com Received: from service87.mimecast.com (HELO service87.mimecast.com) (91.220.42.44) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 27 Nov 2014 10:03:33 +0000 Received: from cam-owa1.Emea.Arm.com (fw-tnat.cambridge.arm.com [217.140.96.140]) by service87.mimecast.com; Thu, 27 Nov 2014 10:03:30 +0000 Received: from [10.1.207.43] ([10.1.255.212]) by cam-owa1.Emea.Arm.com with Microsoft SMTPSVC(6.0.3790.3959); Thu, 27 Nov 2014 10:03:28 +0000 Message-ID: <5476F6F0.4020103@arm.com> Date: Thu, 27 Nov 2014 10:03:28 +0000 From: Kyrill Tkachov User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.2.0 MIME-Version: 1.0 To: Christophe Lyon , Marcus Shawcroft CC: GCC Patches Subject: Re: [PATCH][AArch64] Implement vsqrt_f64 intrinsic References: <546A31DB.7040102@arm.com> In-Reply-To: X-MC-Unique: 114112710033001901 X-IsSubscribed: yes On 26/11/14 10:14, Christophe Lyon wrote: > Hi Kyrill, Hi Christophe, > > > On 21 November 2014 at 16:52, Marcus Shawcroft > wrote: >> On 17 November 2014 17:35, Kyrill Tkachov wrote: >> >>> 2014-11-17 Kyrylo Tkachov >>> >>> * config/aarch64/arm_neon.h (vsqrt_f64): New intrinsic. >>> >>> 2014-11-17 Kyrylo Tkachov >>> >>> * gcc.target/aarch64/simd/vsqrt_f64_1.c >> OK /Marcus > Your new test fails at the scan-assembly step because all the code is > optimized away (even at -O1). Sorry about that, I could have sworn I saw it pass when I initially wrote it... In any case, I've committed this patch (r218117) as obvious to mark one of the variables as volatile to make sure it's not optimised away. I've confirmed that the scan-assembler test fails without this patch and passes with it. Thanks, Kyrill > > Christophe. > diff --git a/gcc/testsuite/gcc.target/aarch64/simd/vsqrt_f64_1.c b/gcc/testsuite/gcc.target/aarch64/simd/vsqrt_f64_1.c index 57fb6bb..7f99bd5 100644 --- a/gcc/testsuite/gcc.target/aarch64/simd/vsqrt_f64_1.c +++ b/gcc/testsuite/gcc.target/aarch64/simd/vsqrt_f64_1.c @@ -11,7 +11,7 @@ extern void abort (void); int main (void) { - float64x1_t in = vcreate_f64(0x3febd3e560634d7bULL); + volatile float64x1_t in = vcreate_f64(0x3febd3e560634d7bULL); float64x1_t result = vsqrt_f64 (in); float64_t expected = 0.9325321502142351;