Products  >  Java on the EJC

In the past, Java has often suffered from well-known problems such as low performance or large, bulky footprint. However, you will find that these problems are not present in the EJC Java solution!

Top prejudices against Java:

  1. "Java is slow, because it is interpreted"

    On the EJC, Java is fast. This is because on the EJC, Java is always translated to native machine code before execution, never interpreted. This makes it as fast as compiled C/C++ code. Translation takes place either statically, at system generation time, or dynamically, as new classes are loaded. Of course, this process happens automatically, without user or application intervention.


  2. "Java is bulky"

    On the EJC, Java is lightweight. The tight integration between the RTOS and the Java Virtual Machine avoids the need for "glue code" and duplication of functionality. This leads to reduced code size and a smaller RAM footprint.


    Different flavours of java

    Different flavours of Java


  3. "Java is unpredictable and non-deterministic"

    Traditional Java implementations have suffered from the loosely defined scheduling semantics of Java, and from the unpredictable pauses introduced by the garbage collection process. In the EJC, these issues are greatly alleviated:

    • Well-defined scheduling semantics, with Java threads being directly mapped to RTOS lightweight processes.

    • Interruptible garbage collection process, can be preempted by higher priority threads and resume operation later.

    • Highly configurable garbage collector, including the possibility of completely disabling asynchronous garbage collection for a specific JVM.


  4. "Java doesn't allow access to raw memory, I/O, or devices"

    The EJC includes class libraries that provide direct access to raw memory, I/O ports, hardware devices, handling of interrupt events, etc.

    With the EJC, a Java-only solution is possible, no need to go for a more complex, multi-language approach. Even device drivers can be written directly in Java.