[Patch, fortran, RFC] PR 40958 Reduce size of module files

Salvatore Filippone filippone.salvatore@gmail.com
Sat Nov 26 07:30:00 GMT 2011


Unfortunately, Mikael is right. The effect on the module sizes is
spectacular, but so is the runtime.
An unpatched 4.7 has completed its build in about 37 minutes; with the
patched compiler I had to stop the build after 10 hours, and it still
was at about at 8% or less of the total work to be done.
On the other hand, the module sizes were reduced by something like
90%, and I would expect that the modules downstream which are more
involved and bloated out of all proportions would be further
compressed. I do not have precise figures now because the machine at
the office has become unreachable right after killing the build :(

My (provisional) conclusions:
1. The bloat in the current module file format is definitely very bad,
but is the kind of bloat that's handled reasonably well by zlib;
2.  Even in the case of the current 4.7 compiler 37 minutes is way too
much, and from Mikael's description I suspect a large part of this is
due to the seeks.

To get you a reference point: the machine at the office is an AMD
athlon; the total module size produce is about 420 MB.
On the laptop from which I am writing this I have a NAG license: the
build takes about 4 mins, and the total module size produced is about
1.2 MB
(yes, that's a little more than ONE MB instead of 400+)

So, I am afraid that the module handling code needs a radical rewrite:
going down the zlib path requires getting rid of the seeks (something
that would be useful even in the plain text format!). I am not at all
sure whether this is any easier than redesigning the module format
from the ground up.

Salvatore
p.s.: if anyone wants to pursue this further contact me offlist  and
I'll send you  the code.



More information about the Fortran mailing list