From patchwork Fri May 23 15:48:44 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wilco X-Patchwork-Id: 351928 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 65E471400A0 for ; Sat, 24 May 2014 01:49:04 +1000 (EST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:subject:date:message-id:mime-version :content-type; q=dns; s=default; b=s5GUwa2W6OhojUNRyL8fnI0Y8qTim 5aYjCjO+R9+3Fhi11mxnTdati6l5F218cq0YL4SmqV2wTYQyOEQPisuOxomPtIZf VQI/7ZRtIHekqTGj5inq5/RvnXv4pygGP17IShVKoU2wVtAasGMzQgX3S3P5MOB/ JPERK/TcQH3iNk= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:subject:date:message-id:mime-version :content-type; s=default; bh=ukmlx4fw4VjLbKLRAtK01zaYKSo=; b=di3 Ry8wDGujGcLl1zJlokS/gHt5oAJ5L9ew6c7AX633fqxnD4vkjH0NENqO14IfeLkD FxHAf8D+DzCJ8Fs89+3jygOk2lFELqWALo63B80AlFBn8zTBLnnieDrI/1c1vamO vN4MqH7fuDID77hjnTO2ywkKmU8zSjABEymvkl2c= Received: (qmail 15303 invoked by alias); 23 May 2014 15:48:59 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 15292 invoked by uid 89); 23 May 2014 15:48:59 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.2 required=5.0 tests=AWL, BAYES_00, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.2 X-HELO: service87.mimecast.com From: "Wilco" To: Subject: [PATCH 1/2] Aarch64: Cleanup math_private.h Date: Fri, 23 May 2014 16:48:44 +0100 Message-ID: <001101cf769e$7abcaf10$70360d30$@com> MIME-Version: 1.0 X-MC-Unique: 114052316485214001 Hi, This is a series of patches to cleanup the aarch64 fenv implementation. Fix declarations in math_private.h to use fpu_fpsr_t correctly, and use one line per declaration. Ok for commit? Wilco ChangeLog: 2014-05-23 Wilco * sysdeps/aarch64/fpu/math_private.h (libc_feholdexcept_aarch64) (libc_feholdexcept_setround_aarch64) (libc_fetestexcept_aarch64) (libc_fesetenv_aarch64) (libc_feupdateenv_test_aarch64) (libc_feholdsetround_aarch64) (libc_feresetround_aarch64) (libc_feholdsetround_aarch64_ctx): Fix declarations. --- sysdeps/aarch64/fpu/math_private.h | 30 ++++++++++++++++++++++-------- 1 file changed, 22 insertions(+), 8 deletions(-) diff --git a/sysdeps/aarch64/fpu/math_private.h b/sysdeps/aarch64/fpu/math_private.h index 7424952..a3f466b 100644 --- a/sysdeps/aarch64/fpu/math_private.h +++ b/sysdeps/aarch64/fpu/math_private.h @@ -25,7 +25,10 @@ static __always_inline void libc_feholdexcept_aarch64 (fenv_t *envp) { - fpu_control_t fpcr, new_fpcr, fpsr, new_fpsr; + fpu_control_t fpcr; + fpu_control_t new_fpcr; + fpu_fpsr_t fpsr; + fpu_fpsr_t new_fpsr; _FPU_GETCW (fpcr); _FPU_GETFPSR (fpsr); @@ -69,7 +72,10 @@ libc_fesetround_aarch64 (int round) static __always_inline void libc_feholdexcept_setround_aarch64 (fenv_t *envp, int round) { - fpu_control_t fpcr, new_fpcr, fpsr, new_fpsr; + fpu_control_t fpcr; + fpu_control_t new_fpcr; + fpu_fpsr_t fpsr; + fpu_fpsr_t new_fpsr; _FPU_GETCW (fpcr); _FPU_GETFPSR (fpsr); @@ -96,7 +102,7 @@ libc_feholdexcept_setround_aarch64 (fenv_t *envp, int round) static __always_inline int libc_fetestexcept_aarch64 (int ex) { - fpu_control_t fpsr; + fpu_fpsr_t fpsr; _FPU_GETFPSR (fpsr); return fpsr & ex & FE_ALL_EXCEPT; @@ -109,7 +115,8 @@ libc_fetestexcept_aarch64 (int ex) static __always_inline void libc_fesetenv_aarch64 (const fenv_t *envp) { - fpu_control_t fpcr, new_fpcr; + fpu_control_t fpcr; + fpu_control_t new_fpcr; _FPU_GETCW (fpcr); new_fpcr = envp->__fpcr; @@ -130,7 +137,10 @@ libc_fesetenv_aarch64 (const fenv_t *envp) static __always_inline int libc_feupdateenv_test_aarch64 (const fenv_t *envp, int ex) { - fpu_control_t fpcr, new_fpcr, fpsr, new_fpsr; + fpu_control_t fpcr; + fpu_control_t new_fpcr; + fpu_fpsr_t fpsr; + fpu_fpsr_t new_fpsr; int excepts; _FPU_GETCW (fpcr); @@ -171,7 +181,8 @@ libc_feupdateenv_aarch64 (const fenv_t *envp) static __always_inline void libc_feholdsetround_aarch64 (fenv_t *envp, int round) { - fpu_control_t fpcr, fpsr; + fpu_control_t fpcr; + fpu_fpsr_t fpsr; _FPU_GETCW (fpcr); _FPU_GETFPSR (fpsr); @@ -193,7 +204,8 @@ libc_feholdsetround_aarch64 (fenv_t *envp, int round) static __always_inline void libc_feresetround_aarch64 (fenv_t *envp) { - fpu_control_t fpcr, round; + fpu_control_t fpcr; + int round; _FPU_GETCW (fpcr); @@ -215,7 +227,9 @@ libc_feresetround_aarch64 (fenv_t *envp) static __always_inline void libc_feholdsetround_aarch64_ctx (struct rm_ctx *ctx, int r) { - fpu_control_t fpcr, fpsr, round; + fpu_control_t fpcr; + fpu_fpsr_t fpsr; + int round; _FPU_GETCW (fpcr); _FPU_GETFPSR (fpsr);