From patchwork Wed Jun 6 22:39:01 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tulio Magno Quites Machado Filho X-Patchwork-Id: 926058 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=sourceware.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=libc-alpha-return-92965-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=linux.ibm.com Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="q0gMWYB8"; 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 411NvT0xjJz9s3R for ; Thu, 7 Jun 2018 08:41:40 +1000 (AEST) 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:cc:subject:date:in-reply-to:references :message-id; q=dns; s=default; b=xe79atamE9mH0u+eG6pB3nZAVwffe88 R4zZJ6yW0TXniykS1EioIHfLNGCWwxfyQxBfofwJOoe25ws7kAZWA+DwzUR//lhL EKedJFIrAkMUAiCeeUTlWprMWLZ/ZgCMAcscLGJhYaSZPJ1e1E3oN34NjiaCsxqC Xq0wfWLWb0Uw= 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:cc:subject:date:in-reply-to:references :message-id; s=default; bh=EmQVryFUZ4kFVyP+s3OALqlJhVY=; b=q0gMW YB8MpIFs0BhOmX8/3QYaFJTkDwdU5cfW/Ac9re9d26GFNg2NgoCLSd3eT7Cqt01I 0Oo3heqijbR1PfNP2LkGTM1eQqEOzHKDALq1Jx1h/xfu6z10zKi1ZAq10Udwo6kY V59KBFq+y1GWSoPDvX1ahRKyUx74GwXwT4nr88= Received: (qmail 69377 invoked by alias); 6 Jun 2018 22:41:28 -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 56055 invoked by uid 89); 6 Jun 2018 22:41:15 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.1 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_SHORT, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: mx0a-001b2d01.pphosted.com From: Tulio Magno Quites Machado Filho To: libc-alpha@sourceware.org Cc: joseph@codesourcery.com, gabriel@inconstante.eti.br, raji@linux.ibm.com Subject: [PATCH 1/9] ldbl-128ibm-compat: Create libm-alias-float128.h Date: Wed, 6 Jun 2018 19:39:01 -0300 In-Reply-To: <20180606223909.16675-1-tuliom@linux.ibm.com> References: <20180606223909.16675-1-tuliom@linux.ibm.com> X-TM-AS-GCONF: 00 x-cbid: 18060622-0036-0000-0000-000009EC4D52 X-IBM-SpamModules-Scores: X-IBM-SpamModules-Versions: BY=3.00009139; HX=3.00000241; KW=3.00000007; PH=3.00000004; SC=3.00000265; SDB=6.01043027; UDB=6.00534142; IPR=6.00822157; MB=3.00021491; MTD=3.00000008; XFM=3.00000015; UTC=2018-06-06 22:41:10 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 18060622-0037-0000-0000-000047969864 Message-Id: <20180606223909.16675-2-tuliom@linux.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2018-06-06_10:, , signatures=0 Add a new libm-alias-float128.h in order to provide the __*ieee128 aliases for the existing *f128 that do not have a globally exported symbol. 2018-06-06 Tulio Magno Quites Machado Filho Gabriel F. T. Gomes * sysdeps/ieee754/ldbl-128ibm-compat/Versions: New file. * sysdeps/ieee754/ldbl-128ibm-compat/libm-alias-float128.h: New file. --- sysdeps/ieee754/ldbl-128ibm-compat/Versions | 129 +++++++++++++++++++++ .../ldbl-128ibm-compat/libm-alias-float128.h | 64 ++++++++++ 2 files changed, 193 insertions(+) create mode 100644 sysdeps/ieee754/ldbl-128ibm-compat/Versions create mode 100644 sysdeps/ieee754/ldbl-128ibm-compat/libm-alias-float128.h diff --git a/sysdeps/ieee754/ldbl-128ibm-compat/Versions b/sysdeps/ieee754/ldbl-128ibm-compat/Versions new file mode 100644 index 0000000000..af6b4b3f60 --- /dev/null +++ b/sysdeps/ieee754/ldbl-128ibm-compat/Versions @@ -0,0 +1,129 @@ +%include +%ifndef LDBL_IBM128_VERSION +% error "ldbl-128ibm-compat-abi.h must define LDBL_IBM128_VERSION" +%endif + +libm { + LDBL_IBM128_VERSION { + __acoshieee128; + __acosieee128; + __asinhieee128; + __asinieee128; + __atan2ieee128; + __atanhieee128; + __atanieee128; + __cabsieee128; + __cacoshieee128; + __cacosieee128; + __canonicalizeieee128; + __cargieee128; + __casinhieee128; + __casinieee128; + __catanhieee128; + __catanieee128; + __cbrtieee128; + __ccoshieee128; + __ccosieee128; + __ceilieee128; + __cexpieee128; + __cimagieee128; + __clog10ieee128; + __clogieee128; + __conjieee128; + __copysignieee128; + __coshieee128; + __cosieee128; + __cpowieee128; + __cprojieee128; + __crealieee128; + __csinhieee128; + __csinieee128; + __csqrtieee128; + __ctanhieee128; + __ctanieee128; + __erfcieee128; + __erfieee128; + __exp10ieee128; + __exp2ieee128; + __expieee128; + __expm1ieee128; + __f32addieee128; + __f32divieee128; + __f32mulieee128; + __f32subieee128; + __f64addieee128; + __f64divieee128; + __f64mulieee128; + __f64subieee128; + __f64xaddieee128; + __f64xdivieee128; + __f64xmulieee128; + __f64xsubieee128; + __fabsieee128; + __fdimieee128; + __floorieee128; + __fmaieee128; + __fmaxieee128; + __fmaxmagieee128; + __fminieee128; + __fminmagieee128; + __fmodieee128; + __frexpieee128; + __fromfpieee128; + __fromfpxieee128; + __gamma_productieee128; + __getpayloadieee128; + __hypotieee128; + __ilogbieee128; + __j0ieee128; + __j1ieee128; + __jnieee128; + __ldexpieee128; + __lgammaieee128; + __lgammaieee128_r; + __lgamma_negieee128; + __lgamma_productieee128; + __llogbieee128; + __llrintieee128; + __llroundieee128; + __log10ieee128; + __log1pieee128; + __log2ieee128; + __logbieee128; + __logieee128; + __lrintieee128; + __lroundieee128; + __modfieee128; + __nanieee128; + __nearbyintieee128; + __nextafterieee128; + __nextdownieee128; + __nextupieee128; + __powieee128; + __remainderieee128; + __remquoieee128; + __rintieee128; + __roundevenieee128; + __roundieee128; + __scalblnieee128; + __scalbnieee128; + __setpayloadieee128; + __setpayloadsigieee128; + __sincosieee128; + __sinhieee128; + __sinieee128; + __sqrtieee128; + __tanhieee128; + __tanieee128; + __tgammaieee128; + __totalorderieee128; + __totalordermagieee128; + __truncieee128; + __ufromfpieee128; + __ufromfpxieee128; + __x2y2m1ieee128; + __y0ieee128; + __y1ieee128; + __ynieee128; + } +} diff --git a/sysdeps/ieee754/ldbl-128ibm-compat/libm-alias-float128.h b/sysdeps/ieee754/ldbl-128ibm-compat/libm-alias-float128.h new file mode 100644 index 0000000000..a21dfcaea5 --- /dev/null +++ b/sysdeps/ieee754/ldbl-128ibm-compat/libm-alias-float128.h @@ -0,0 +1,64 @@ +/* Define aliases for libm _Float128 functions. + Copyright (C) 2018 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with the GNU C Library; if not, see + . */ + +#ifndef _LIBM_ALIAS_FLOAT128_H +#define _LIBM_ALIAS_FLOAT128_H + +#include +#include + +/* This macro should be used on all long double functions that are not part of + the _Float128 API in order to provide *ieee128 symbols without exposing + internal *f128 symbols. */ +#define libm_alias_float128_other_r_ldbl(from, to, r) \ + strong_alias (from ## f128 ## r, __ ## to ## ieee128 ## r) + +/* Define _FloatN / _FloatNx aliases (other than that for _Float128) + for a _Float128 libm function that has internal name FROM ## f128 + ## R and public names TO ## suffix ## R for each suffix of a + supported _FloatN / _FloatNx floating-point type with the same + format as _Float128. */ +#if __HAVE_FLOAT64X && !__HAVE_FLOAT64X_LONG_DOUBLE +# define libm_alias_float128_other_r(from, to, r) \ + weak_alias (from ## f128 ## r, to ## f64x ## r); \ + libm_alias_float128_other_r_ldbl(from, to, r) +#else +# define libm_alias_float128_other_r(from, to, r) \ + libm_alias_float128_other_r_ldbl(from, to, r) +#endif + +/* Likewise, but without the R suffix. */ +#define libm_alias_float128_other(from, to) \ + libm_alias_float128_other_r (from, to, ) + +/* Define aliases for a _Float128 libm function that has internal name + FROM ## f128 ## R and public names TO ## suffix ## R for each + suffix of a supported floating-point type with the same format as + _Float128. This should only be used for functions where such + public names exist for _FloatN types, not for + implementation-namespace exported names (where there is one name + per format, not per type) or for obsolescent functions not provided + for _FloatN types. */ +#define libm_alias_float128_r(from, to, r) \ + weak_alias (from ## f128 ## r, to ## f128 ## r); \ + libm_alias_float128_other_r (from, to, r) + +/* Likewise, but without the R suffix. */ +#define libm_alias_float128(from, to) libm_alias_float128_r (from, to, ) + +#endif