From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/14603 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Pascal Cuoq Newsgroups: gmane.linux.lib.musl.general Subject: Re: Looking for a libm suitable for float128 (using softfloat or softfp) Date: Sat, 31 Aug 2019 12:25:08 +0000 Message-ID: References: Reply-To: musl@lists.openwall.com Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="76455"; mail-complaints-to="usenet@blaine.gmane.org" To: "musl@lists.openwall.com" Original-X-From: musl-return-14619-gllmg-musl=m.gmane.org@lists.openwall.com Sat Aug 31 14:25:23 2019 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by blaine.gmane.org with smtp (Exim 4.89) (envelope-from ) id 1i42RX-000Jl6-3M for gllmg-musl@m.gmane.org; Sat, 31 Aug 2019 14:25:23 +0200 Original-Received: (qmail 22211 invoked by uid 550); 31 Aug 2019 12:25:20 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Original-Received: (qmail 22190 invoked from network); 31 Aug 2019 12:25:20 -0000 Thread-Topic: [musl] Looking for a libm suitable for float128 (using softfloat or softfp) Thread-Index: AQHVX/ALKxQjiNC53Eqs1BCQNjhOyqcVDNiA In-Reply-To: Accept-Language: en-US Content-Language: en-US x-ms-exchange-messagesentrepresentingtype: 1 x-ms-exchange-transport-fromentityheader: Hosted x-originating-ip: [86.246.61.97] Content-ID: <7E43CF971B8D7843AF2240214D79E639@EX1688.lan> Xref: news.gmane.org gmane.linux.lib.musl.general:14603 Archived-At: > On 31 Aug 2019, at 13:33, ardi wrote: >=20 > Hi, >=20 > I'm looking for a software implementation of libm that can deal with > the IEEE float128 (float128 as implemented by either the John Hauser's > softfloat or Fabrice Bellard's softfp libraries). >=20 > Looking at the musl source in src/math it certainly implements long > double versions of all libm functions, and it seems that the source > code makes checks to confirm whether to use the Intel 80bit long > double, or a 128bit long double, so, at first glance I think musl > could be a great choice for this task. As far as I know, most functions are not implemented for binary128 in musl. Yes, there are long double version of everything and #ifdefs for the cases = where long double is binary64, double-extended or binary128, but binary128 = is not actually implemented. In most cases you will be worse off than if yo= u had opted for double-extended: https://git.musl-libc.org/cgit/musl/tree/src/math/powl.c?id=3D6ad514e4e278f= 0c3b18eb2db1d45638c9af1c07f#n517 #elif LDBL_MANT_DIG =3D=3D 113 && LDBL_MAX_EXP =3D=3D 16384 // TODO: broken implementation to make things compile long double powl(long double x, long double y) { return pow(x, y); } #endif