[doc,patch] Document that -fwhole-program isn't supported for Fortran
Tom Tromey
tromey@redhat.com
Mon Oct 1 18:10:00 GMT 2007
>>>>> "FX" == François-Xavier Coudert <fxcoudert@gmail.com> writes:
FX> For Fortran, -fwhole-program isn't usable because the Fortran
FX> front-end issues more than one decl per function, thus making the call
FX> graph used in this optimisation wrong.
FWIW, the compile server ends up in this same situation. (This
happens because in the server we want to avoid decl smashing, so when
we see a declaration and then a definition we wind up with two decls.)
My current solution is to make a map that lists duplicates, then
canonicalize references during gimplification. To make this work in
the C FE, I had to move gimplification a bit later.
Tom
More information about the Fortran
mailing list