GCJ as a general backend for the GCC ?

Cedric Berger cedric@wireless-networks.com
Fri Apr 6 08:12:00 GMT 2001


Stefan Behnel wrote:
> I'm just curious:
> GCJ compiles Java->bytecode, bytecode->native, Java->native
>> Whould it be possible to use GCJ in order to compile any of the other languages supported by the GCC to JVM-bytecode? At least, if they don't depend on external libraries or special IO support?
>> I didn't find any hints to that on the GCJ page.
>> That way you could write your programs in basically any language and compile them for the JVM. You could even mix different languages which would allow for example the generation of interfaces by a Java-GUI builder and writing the rest of the JVM-application in C, FORTRAN or whatever (I love gcc...)

You cannot compile C->bytecode without extending the bytecode set, because bytecode doesn't
support raw access to memory (read C pointers).
Native java chips (like picojava) adds new bytecodes to support that and other related things.
Cedric


More information about the Java mailing list

AltStyle によって変換されたページ (->オリジナル) /