14.07.2013 Views

Contents - Cultural View

Contents - Cultural View

Contents - Cultural View

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Java compiler 159<br />

Java compiler<br />

A Java compiler is a compiler for the Java programming language. The most common form of output from a Java<br />

compiler are Java class files containing platform-neutral Java bytecode. There exist also compilers emitting<br />

optimized native machine code for a particular hardware/operating system combination.<br />

Most Java-to-bytecode compilers, Jikes being a well known exception, do virtually no optimization, leaving this<br />

until runtime to be done by the JRE.<br />

The Java Virtual Machine (JVM) loads the class files and either interprets the bytecode or just-in-time compiles it to<br />

machine code and then possibly optimizes it using dynamic compilation.<br />

The very first Java compiler developed by Sun Microsystems was written in C using some libraries from C++.<br />

Major Java compilers<br />

As of 2010, the following are major Java compilers:<br />

• javac, included in JDK from Sun Microsystems, open-sourced since 13 November 2006.<br />

• GCJ, a part of gcc which compiles C, Fortran, Pascal and other programming languages besides Java. It can also<br />

generate native code using the back-end of gcc.<br />

• ECJ, the Eclipse Compiler for Java, is an open source incremental compiler used by the Eclipse JDT.<br />

Java decompilers<br />

A Java decompiler tries to reverse the process of compiling, that is it tries to decompile Java bytecode files (*.class)<br />

back to Java source files (*.java).<br />

• DJ Java Decompiler [1] (Uses JAD) 10 use trial version<br />

• JAD, written in C++, free for non-commercial use.<br />

• JD [1], younger project, includes GUI, optional Eclipse-plugin.<br />

• JODE [2], decompiler and optimizer, open-source.<br />

• Mocha, one of the first decompilers for Java.<br />

External links<br />

• Sun's OpenJDK javac page [3]<br />

• Jikes homepage [4]<br />

• JSR 199 [5] Java Compiler API Java Specification Request for invoking the Java compiler from a Java program<br />

References<br />

[1] http:/ / www. neshkov. com/<br />

[2] http:/ / jode. sourceforge. net/<br />

[3] http:/ / openjdk. java. net/ groups/ compiler/<br />

[4] http:/ / jikes. sourceforge. net/<br />

[5] http:/ / www. jcp. org/ en/ jsr/ detail?id=199

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!