This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: documenting changes to the front-end interface (was:Remove make_function_rtl)


>>>>> "Fergus" == Fergus Henderson <fjh@cs.mu.oz.au> writes:

    Fergus> However, I noticed that there is a file gcc/LANGUAGES
    Fergus> which says it is supposed to to contain documentation of
    Fergus> any changes to the "GCC tree -> rtl interfaces (or more
    Fergus> generally the interfaces for adding new languages)".
    Fergus> Unfortunately this file has not been updated since 1998.

I didn't even know about this file.

Certainly, better documentation of the tree->rtl conversion functions
would be a boon.  Also good would be to clean up that interface; it is
presently a much bigger interface than it actually needs to be.  It
should really consist of about three functions:

  - main->front end: Start parsing, Mr. Front End.

  - front end->main: Here's a DECL.  Make me some code, data
                     statements, whatever.

  - main->front end: Clean yourself up, we're going away now.

And, then, some hooks that the main code uses to call back into the
front-end as it's generating code, debugging information, etc.  These
should be arranged in a structure, ala bfd, so that a front-end has to
define a global variable of that structure type.  This would be much,
much better.

Anyhow, that pipe dream doesn't say anything about the question you
asked.  (I am planning for a career in politics.)  I will update the
LANGUAGES file -- but that's really no substitute for proper
documentation.

--
Mark Mitchell                   mark@codesourcery.com
CodeSourcery, LLC               http://www.codesourcery.com

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]