]> git.ipfire.org Git - thirdparty/gcc.git/commit
power-ieee128: Fix up byte-swapping for IBM extended real(kind=16)
authorJakub Jelinek <jakub@redhat.com>
Tue, 11 Jan 2022 22:03:11 +0000 (23:03 +0100)
committerJakub Jelinek <jakub@redhat.com>
Tue, 11 Jan 2022 22:03:11 +0000 (23:03 +0100)
commitdffb2646d1c231dbe1159e1d4cfeab374adf91af
tree3c666b71e4d5e77cc37163aa36c93e4a465a5356
parent8d87dd6069d5bdfab3f611bdb0399c7da5058041
power-ieee128: Fix up byte-swapping for IBM extended real(kind=16)

Here is a patch to fix up the ppc64be vs. ppc64le byteswapping
of IBM extended real(kind=16) and complex(kind=16).
Similarly to the BT_COMPLEX case it halves size and doubles nelems
for the bswap_array calls.  Of course for r16_ibm and r16_ieee conversions
one needs to make sure it is only done when the on file data is in that
format and not in IEEE quad.

2022-01-11  Jakub Jelinek  <jakub@redhat.com>

* io/transfer.c (unformatted_read, unformatted_write): When
byteswapping IBM extended real(kind=16), handle it as byteswapping
two real(kind=8) values.
libgfortran/io/transfer.c