4 ms·
I think the entirety of Hotspot is written in C++ [0]? The standard library in the JDK is mostly written in Java, but the VM itself with the GC and JIT code is
by fathyb 4y ago
I think the entirety of Hotspot is written in C++ [0]? The standard library in the JDK is mostly written in Java, but the VM itself with the GC and JIT code is in C++, which makes sense.
If you do not count the standard library as part of the JVM (but part of the JDK), then the JVM is written mostly in C++.
[0]: https://github.com/openjdk/jdk/tree/master/src/hotspot https://github.com/openjdk/jdk/tree/master/src/hotspot
- taeric 4y agoThat definitely matches my read of the source. Would still be delighted to know there is something else going on, though. :D
- samus 4y agoBecause of its inherent memory safety, Java is attractive for anything in the JVM which is not strictly necessary to be coded in C/C++ for some reason (raw performance, low-level, or OS-specific). With Projects Valhalla ann Panama around the corner, there will be even less hard reasons going forward. Also, C/C++ compilers can be tricky dependencies at times.