Java Bytecode - Generation

Generation

The most common language targeting Java Virtual Machine by producing Java bytecode is Java. Originally only one compiler existed, the javac compiler from Sun Microsystems, which compiles Java source code to Java bytecode; but because all the specifications for Java bytecode are now available, other parties have supplied compilers that produce Java bytecode. Examples of other compilers include:

  • Jikes, compiles from Java to Java bytecode (developed by IBM, implemented in C++)
  • Espresso, compiles from Java to Java bytecode (Java 1.0 only)
  • GCJ, the GNU Compiler for Java, compiles from Java to Java bytecode; it is also able to compile to native machine code and is available as part of the GNU Compiler Collection (GCC).

Some projects provide Java assemblers to enable writing Java bytecode by hand. Assembly code may be also generated by machine, for example by compiler targeting Java virtual machine. Notable Java assemblers include:

  • Jasmin, takes textual descriptions for Java classes, written in a simple assembly-like syntax using Java Virtual Machine instruction set and generates a Java class file
  • Jamaica, a macro assembly language for the Java virtual machine. Java syntax is used for class or interface definition. Method bodies are specified using bytecode instructions.

Others have developed compilers, for different programming languages, in order to target the Java virtual machine, such as:

  • JRuby and Jython, two scripting languages based on Ruby and Python
  • Groovy, a scripting language based on Java
  • Scala, a type-safe general-purpose programming language supporting object-oriented and functional programming
  • JGNAT and AppletMagic, compile from the Ada programming language to Java bytecode
  • C to Java byte-code compilers
  • Clojure
  • MIDletPascal
  • JavaFX Script code is also compiled to Java bytecode.

Read more about this topic:  Java Bytecode

Famous quotes containing the word generation:

    Generation after generation of women have pledged to raise their daughters differently, only to find that their daughters grow up and fervently pledge the same thing.
    Elizabeth Debold (20th century)

    If you think about it seriously, all the questions about the soul and the immortality of the soul and paradise and hell are at bottom only a way of seeing this very simple fact: that every action of ours is passed on to others according to its value, of good or evil, it passes from father to son, from one generation to the next, in a perpetual movement.
    Antonio Gramsci (1891–1937)

    I do not mean to imply that the good old days were perfect. But the institutions and structure—the web—of society needed reform, not demolition. To have cut the institutional and community strands without replacing them with new ones proved to be a form of abuse to one generation and to the next. For so many Americans, the tragedy was not in dreaming that life could be better; the tragedy was that the dreaming ended.
    Richard Louv (20th century)