From: Szabolcs Nagy <nsz@port70.net>
To: musl@lists.openwall.com
Subject: Re: 32-bit double and long double
Date: Tue, 27 Nov 2018 13:52:01 +0100 [thread overview]
Message-ID: <20181127125201.GS21289@port70.net> (raw)
In-Reply-To: <20181127023211.GR23599@brightrain.aerifal.cx>
* Rich Felker <dalias@libc.org> [2018-11-26 21:32:11 -0500]:
> On Mon, Nov 26, 2018 at 05:36:58PM +0000, Jon Chesterfield wrote:
> > Arguments to variadic functions promote to double. Again I would prefer 32
> > bit float.
>
> Indeed this is a hard limitation of the language. I suppose it comes
> in mostly/only for passing floating point values to printf. The
> promotion should at least be nothing more than a few 64-bit shift/or
> ops.
well floating-point is usually tricky..
conversion to double should signal an invalid exception for snan.
subnormal range values need different logic than normal range ones
and likely require a clz operation.
if you support flush-to-zero arithmetics then subnormal input
should raise an input-denormal exception and treat it as zero.
..but all this is implemented in libgcc soft-fp support.
prev parent reply other threads:[~2018-11-27 12:52 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-26 15:25 Eugene Sharygin
2018-11-26 17:03 ` Rich Felker
2018-11-26 17:30 ` Eugene Sharygin
2018-11-26 17:35 ` Eugene Sharygin
2018-11-26 17:36 ` Jon Chesterfield
2018-11-26 18:19 ` Szabolcs Nagy
2018-11-27 2:32 ` Rich Felker
2018-11-27 12:52 ` Szabolcs Nagy [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20181127125201.GS21289@port70.net \
--to=nsz@port70.net \
--cc=musl@lists.openwall.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/musl/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).