[PATCH 2/2] libstdc++: Fix endianness issue with IBM long double [PR98384]
Jonathan Wakely
jwakely.gcc@gmail.com
Mon Feb 22 22:22:43 GMT 2021
On Mon, 22 Feb 2021, 22:13 Patrick Palka via Libstdc++, <
libstdc++@gcc.gnu.org> wrote:
> The logic in std::to_chars for extracting the high- and low-order parts
> of a IBM long double value does the right thing on powerpc64le, but not
> on powerpc64be. This patch makes the extraction endian-agnostic, which
> fixes the execution FAIL of to_chars/long_double.cc on powerpc64be.
>
> Tested on powerpc64le and powerpc64be. Does this look OK for trunk?
>
I was going to suggest __builtin_unpack_longdouble but actually since you
want the bits this is better. You'd need another step to get the bits from
each double.
OK for trunk.
More information about the Libstdc++
mailing list