This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: gcjx integration
- From: Tom Tromey <tromey at redhat dot com>
- To: Jakob Praher <jpraher at yahoo dot de>
- Cc: "java at gcc dot gnu dot org" <java at gcc dot gnu dot org>
- Date: 18 Jan 2005 13:13:22 -0700
- Subject: Re: gcjx integration
- References: <1105959301.5263.8.camel@jaques2>
- Reply-to: tromey at redhat dot com
>>>>> "Jakob" == Jakob Praher <jpraher@yahoo.de> writes:
Jakob> The Make-lang.in has to be updated.
Yeah, haven't really gotten around to that yet.
Probably the minimum here is add some C++ stuff to gcc/configure.ac
(e.g., AC_PROG_CXX), update Makefile.in and java/Make-lang.in to
compile the C++ source, and also arrange for gengtype to be run over
the C++ sources in gcc/java/.
Jakob> in the new frontend, there is
Jakob> gcjx/gcjx
Jakob> and then you have the tree stuff in
Jakob> gcc/java/
Jakob> from a system approach, maybe you can point me to some overall
Jakob> ideas of how the system is combined.
There is a short tour of the source in gcjx/PROJECTS.
Basically, the gcjx directory holds the bulk of the compiler. When
compiling it builds up data structures representing the program being
compiled, these structures are all defined in model/.
Each back end (currently there are several: bytecode, JNI and CNI
header and stub generation, and trees) is a concrete subclass of the
'code_generator' class. The compiler hands classes to the code
generator for action. For the most part, the model is independent of
the back end (there are some open questions regarding accessor
methods).
The code in gcc/java/ is simply the code generator for creating trees.
There is also some code for hooking gcjx into the gcc command line
(driver.cc). The tree back end, btw, is the least complete code in
gcjx. I've gotten assembly out of it, but not working code yet.
Jakob> regarding c++: the d frontend for gcc also uses c++, since the d
Jakob> compiler by digitalmars is in c++ too. I've looked at their
Jakob> Make-lang.in, which is pretty straightforward too.
Do they try to handle the bootstrap problem? The problem is mainly
one of ordering: when doing a native bootstrap it would be nice to use
the just-built g++ and libstdc++ to build a C++ front end.
Tom