[LLVMdev] Compiler Driver Decisions

Chris Lattner sabre at nondot.org
Wed Aug 4 13:37:24 PDT 2004


On Wed, 4 Aug 2004, John Criswell wrote:
> > I don't buy this at all.  In particular, these files are provided by
> > front-end designers for the sole consumption of the driver.  NO other
> > tools should be looking in these files, they should use the compiler
> > driver directly.
>
> I don't believe this is realistic.  This is a configuration file that
> tells the driver how to compile stuff.  There is a definite chance that
> it will need to be modified as parts of the compiler are updated,
> replaced, or removed.

Yes, exactly.  But this is strictly for communication between the
front-end and the compiler driver, nothing more, nothing less.  We want
the driver to be able to evolve without the front-ends having to be
upgraded.  As such, we could just have a version number if needed.

> Think of installing a new frontend.  It would be nice if its
> installation could automatically insert itself into the driver's
> configuration file.

It would just add a fixed file to a directory, not modify any existing
files.

> Or how about writing a program that prints the compiler's configuration
> to stdout?

llvm-driver -print-compiler-configuration

> Or an administrator who wants to write a quick program to re-configure
> the compiler on several different machines he administrates?

You're missing the point.  The driver is the interface to the program, not
these text files.

> I think we have two choice to make these operations convenient.  Either
> we provide command line tools for modifying the configuration, or make
> the file's format in such a way that these tools can be easily and
> accurately written by others on an on-demand basis.

No, if people are trying to do these things, it is a sign that we have
done something fatally wrong.

-Chris

-- 
http://llvm.cs.uiuc.edu/
http://nondot.org/sabre/




More information about the llvm-dev mailing list