This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [gfortran] commited, patch for PR 24685
> FYI, this testcase fails on arches using real*16, e.g.
> {ppc,ppc64,s390,s390x}-linux (with -mlong-double-128).
> I have added
> write (*, fmt='(60a)') tmp
> right after the first:
> write (tmp, *) b
>
> 1.1897314953572317650858000000000E+4932 1.1897314953572317650858000000000E+4932
>
> At line 10 of file large_real_kind_form_io_2.f90
> Fortran runtime error: Range error during floating point read
OK, so I guess it's time to widen the real(16) default format too.
Please note this bug was already present, the new testcase only
exposed it. Could you run the same testcase with a
"write(*,fmt='(F70.40)') b" line added?
The more I see the problems with have with system printf everywhere
and the performance numbers for formatted I/O, the more I think we'll
need to have our own dtoa implementation somewhere in libgfortran
(independence from buggy system printf, and one less call to log10 per
floating-point number written).
FX