WIPIVERSE All articles

Jazelle

Jazelle is a hardware extension developed by ARM Holdings for the ARM processor architecture. It is most commonly known as Jazelle DBX (Direct Bytecode Execution), a technology that allows certain ARM processors to execute Java bytecode directly in hardware as a third execution state, alongside the existing ARM and Thumb instruction set modes.

Technical foundation

Jazelle functionality was specified in the ARMv5TEJ architecture, and the first processor to incorporate Jazelle technology was the ARM926EJ-S. Processors featuring the technology are denoted by a "J" appended to the CPU name. In post-v5 ARM cores, Jazelle support is required (though in trivial form) for architecture conformance.

The extension operates by using low-level binary translation implemented as an additional stage between the fetch and decode stages of the processor instruction pipeline. Recognized Java bytecodes are converted into one or more native ARM instructions. Between 134 and 149 bytecodes (out of the 203 bytecodes defined in the JVM specification) are translated and executed directly in hardware.

Purpose and usage

Jazelle was primarily used by manufacturers of mobile phones to increase the execution speed of Java ME games and applications. A Jazelle-aware Java virtual machine (JVM) attempts to run Java bytecode in hardware while falling back to software for more complex or less commonly used bytecode operations. ARM claims that approximately 95% of bytecode in typical program usage is directly processed in hardware.

Jazelle mode is entered via the BXJ (Branch and eXchange to Java) instruction. The hardware implementation only covers a subset of JVM bytecodes; for unhandled bytecodes, or when overridden by the operating system, the hardware invokes the software JVM as a fallback.

Documentation limitations

The published specifications for Jazelle are intentionally incomplete, providing only enough detail to write operating system code that can support a JVM using Jazelle. ARM has not publicly released the application binary interface between the JVM and the Jazelle hardware state, which has rendered Jazelle effectively an undocumented feature for most users. This tight binding has given ARM considerable control over which JVMs can exploit the technology and has prevented open-source JVMs from using it.

Successor: ThumbEE

The ARMv7 architecture de-emphasized Jazelle direct bytecode execution. In implementation terms, only trivial hardware support for Jazelle is required in ARMv7 processors—support for entering and exiting Jazelle mode, but not for executing Java bytecodes. The ARMv7 architecture instead favored the Thumb Execution Environment (ThumbEE), a variant of the Thumb-2 instruction set designed for compiled environments using JIT technologies. ThumbEE was not specific to Java and was fully documented. ThumbEE has also since been deprecated.

Additional meaning

"Jazelle" is also used as a modern given name, primarily feminine, with various proposed etymologies. However, the principal encyclopedic usage of the term refers to the ARM hardware technology described above.

Browse

More topics to explore

    Browse all articles