-frecord-marker
Keith Bennett
keith@mcs.st-and.ac.uk
Sat Jul 22 13:48:00 GMT 2006
On Fri, Jul 21, 2006, Thomas Koenig wrote:
> On Fri, Jul 21, 2006 at 12:31:03PM +0100, Keith Bennett wrote:
> > On Thu, Jul 20, 2006, Thomas Koenig wrote:
> > > I don't even think we will make Intel's scheme the default.
> > > There is no need to differentiate between Intel's method and the
> > > behavior of gfortran when -frecord-marker=4 is specified, because
> > > they are identical when record length is below 2**31-1.
> >
> > Except for the fact that this only works when the main routine is
> > written in fortran.
>
> At the risk of repeating myself, you can add "-fdump-tree-original" to
> get a pretty good idea of what the gortran front end does.
>
> This reveals hat compiling a main program with -frecord-marker=4
> will introduce a call to _gfortran_set_record_marker (4), which
> is a C function defined in the library, which is entirely callable
> from a C main program.
>
> At current, this is an implementation detail. We can chose to
> document it, making it part of the API.
>
> Comments?
Well, it's better than nothing and it will work for some of my projects.
It's not a full solution, however. It means that the end user has to know
which compiler you used to create the library and then insert/remove this
call when applicable.
That's not really acceptable, so we still have no choice but to use a
different compiler when distributing libraries to other people.
It also makes it a bit of a pain if you regularly use a range of different
fortran compilers for creating the library. You'd have to add some
#ifdefs and add a new Makefile section for gfortran-specific builds.
Not pretty.
Keith.
More information about the Fortran
mailing list