Here are some rough notes on things observed in the codebase - not by the Espresso authors so may all be totally wrong.
Espresso is mostly written in Java but has some C components as well. These serve two purposes:
- The espresso engine can be compiled with native-image down to a shared library so it no longer needs hotspot and runs AOT. This is called “libespresso”
- Native code components from OpenJDK that use internal HotSpot APIs can be loaded. This allows a high degree of code re-use and means that unlike most JVM implementations, this one doesn’t need to implement the JDK class library, not even tricky parts in java.base or internal modules - in fact the classes you’d find in the java.base module in a regular OpenJDK should work as long as it’s of the right versions.
OpenJDK native code components include libjava
, libjimage
etc. These can be loaded as genuinely native components and also (it appears) via Sulong, which on GraalVM EE would give you sandboxing of these compon