[cfp-interest 3639] The C-23 approach to encode and decode.
Damian McGuckin
damianm at esi.com.au
Sun Oct 5 15:27:12 PDT 2025
Interesting comments on Annex H.
FYI only - Damian
---------- Forwarded message ----------
Date: Mon, 6 Oct 2025 08:59:30
From: Michel Hack <00002fdf62126191-dmarc-request at listserv.ieee.org>
To: stds-754 <stds-754 at listserv.ieee.org>
Subject: The C-23 approach to encode and decode.
On Sun, 5 Oct 2025 23:46:43 +1100, Peter C B Henderson wrote:
> They prompted me to look at a draft of C2Y, the revision of C23.
> The relevant contents are much that same as n2601.pdf. The Clause
> of interest, Annex H. deals with interchange and extended types.
Thanks very much; a lot to digest, especially how this manages to make
sense of the 754-2008 approach to arithmetic vs interchange formats
(which 2019 did not change). I'm also glad to finally see explicit
mentions of the 5.5.2 decimal re-encoding operations.
I do however note a significant flaw in the choice of unsigned char
arrays for the representations, because those brutally expose the
Endianness issue! It would have been much better to use uint_32_t,
uint_64_t, and uint_128_t for this. (LLVM may also support uint_256_t,
at any rate I recall that a colleague worked on this a few years ago.)
I wonder if there are Endian-neutral vector register types, now that
there are many architectures with wide vector registers. I'm afraid
however that these may have Little-Endian ordering built-in...
In the context of 754 this affects the parameterized extra-wide formats,
which implicitly assume array-like backing, but ordering of elements
within an array may or may not match the ordering of bytes within a
register-size word. Anyone remember the messy Vax wide FP formats?
It's good that 754 decided that these issues are out-of-scope... but
are we all clear on that?
Michel.
---Sent: 2025-10-05 22:19:51 UTC
________________________________________________________________________
To unsubscribe from the STDS-754 list, click the following link: https://listserv.ieee.org/cgi-bin/wa?SUBED1=STDS-754&A=1
More information about the cfp-interest
mailing list