chapter we always assumed that Java program class files provided
bytecode instructions to Java Virtual Machine programs that
run on conventional processors. However, there is no reason a Java
Real Machine that processes bytecodes directly in hardware
cannot be built and in fact several have been. Sun Microsystems
initially proved the concept in the late 1990s with its PicoJava
chip. Since then several independent Java hardware implementations
have hit the market.
specification requires a stack based processing scheme rather than
the register approach common in conventional hardware (see the JVM
discussions in the web course supplements section.) The language
designers wanted Java to run on a wide range of processors, including
simple embedded types that had few registers, and so decided the
stack approach was the most portable.
cover a wide range of designs and purposes. A standalone Java chip design provides all the capabilities needed to
act as a general-purpose computer. The processor executes the bytecodes
directly. Most of the current processors only execute a subset of
the full Java instruction set. For example, a chip might leave out
the floating-point instructions since for many applications, such
as a micro-controller, floating point instructions are not needed.
approach is to add a Java co-processor
to a conventional processor. The Java co-processor in some designs
translates the bytecodes into the instruction set of the conventional
processor and accelerates the running of Java programs. In more
of a “companion processor” approach (Ref.), the Java hardware takes
over the execution of Java bytecodes completely whenever a Java
program runs while the operating system and other types of non-Java
code run separately in the conventional processor.
processor may refer to a core,
which is a circuit added to FPGA or ASIC/SoC (System-on-a-chip)
to provide either the primary processing capability or to act as
a co-processor. Such cores are not sold as silicon hardware by their
designers but as intellectual property, in the form of a RTL (Register
Transfer Language) description of the circuit, to those who make
of Java Hardware Processing
Real Java machines offer a number of advantages
for embedded applications where the processor must typically work
with limited memory and power resources. As we mentioned in the
J2ME section, there may not be sufficient resources for a JVM with
or other sophisticated acceleration capabilities.
However, for small platforms with limited resources
there literally may not be room for both a JVM and a program to
run. A JVM can easily take up a megabyte or more of RAM, while the
entire memory available on a micro-platform like a cell phone may
consist of 500 kilobytes or less.
One option is to use AOT (ahead-of-time) compilers
that interpret the Java code in advance and transform it into machine
code for a target platform. The code then runs at full native speeds.
This obviously eliminates portability but works well for permanent,
non-networked situations such as a controller in a washing machine.
For platforms, such as a cell phone, that can download new Java
programs, an interpreter either as a JVM or in hardware is required.
Even when there is sufficient memory for a JVM,
a hardware Java processor could provide greater speed since a low
power embedded conventional processor may offer limited performance.
If a pure Java processor cannot handle all of the tasks required,
an option is to add a Java accelerator core that will assist a conventional
processor with running Java programs. Multimedia operations in video,
audio, and 2D/3D graphics can especially benefit from the performance
enhancements of Java acceleration hardware.
In this chapter we review examples of the following
- Java Processor Chips - examples of
chips that execute bytecodes directly or translate them into instructions
for a conventional processor.
- Java Cores - these processor circuits
are sold as IP (Intellectual Property) for implementation on chips,
FPGAs, and systems-on-a-chip.
- Java Boards - board level systems
with Java processors. In some cases they are complete standalone
computers, while in other cases they plug into a bus to assist
a conventional processor with Java programs.
& Web Resources
Latest update: Dec. 14, 2004