Hi FX,
(We could also do something like that for a 32-bit system, but
that is another kettle of fish).
We probably wouldn’t get a speed-up that big. Even on 32-bit targets
(at least common ones), the 64-bit type and its operations (notably
division) are implemented via CPU instructions, not library calls.
I'll look at this a bit more closely and report :-)
At this point, the output of integers is probably bound by the
many layers of indirection of libgfortran's I/O system (which
are necessary because of the rich I/O formatting allowed by
the standard).
There are a few things we could do. Getting a LTO-capable version
of libgfortran would be a huge step, because the compiler could
then strip out all of these layers. The speed of
character:: c
write (*,'(A)', advance="no") c
could stand some improvement :-)
Regards
Thomas