This is the mail archive of the
mailing list for the GCC project.
Re: C as target platform?
- From: Erik Schnetter <schnetter at uni-tuebingen dot de>
- To: gcc at gcc dot gnu dot org
- Date: Fri, 23 Aug 2002 18:33:42 +0200
- Subject: Re: C as target platform?
- Organization: Theoretische Astrophysik Tuebingen
On Fri, 23 Aug 2002 08:47:26 -0400, Daniel Jacobowitz <drow at mvista
dot com> wrote:
> On Fri, Aug 23, 2002 at 09:03:05AM +0200, Helmut Zeisel wrote:
> > Could C (or even KR-C) as a supported target platform solve
> > many of the problems with respect to a front-end
> > written in C++ or any other language?
> > In that case, one would have not only a Fortran to C
> > (similar to the existing F2C), but also an ADA2C, C++2C etc.
> > For bootstrapping (and maybe for the distribution) of GCC,
> > one could use the C-"compiled" version of GCC,
> > although the real source is written in some other language.
> Code to compile to C has been repeatedly declined, at RMS's request.
> It makes using GCC as a frontend for a proprietary compiler too
An alternative would be an assembler-to-C converter. Pick an easy
assembler language supported by gcc (e.g. Sparc or MMIX), and write a
standalone application that converts it to C. If you read object code,
then parsing is not a problem. The produced C code need not be
optimal, and a "reasonable" C compiler will produce "reasonable"
programmes from it.
Erik Schnetter <email@example.com>
My email is as private as my paper mail. I therefore support encrypting
and signing email messages. Tell me if I can encrypt messages to you.
(For more information, go e.g. to http://www.pgpi.org.)