3 ms·
Java runs a Hello World, cold, in a packaged JAR, in about 40ms. What you've seen isn't JVM startup but programs that do a lot at initialisation (like MS Word),
by pron 5mo ago
Java runs a Hello World, cold, in a packaged JAR, in about 40ms. What you've seen isn't JVM startup but programs that do a lot at initialisation (like MS Word), as many Java programs like to do (because they often expect to run for a long time, so they don't care about startup time).
- pdimitar 5mo agoI have not worked with Java in a long time but I seem to remember that most Java programs also accrue a good amount of dependencies and some of them have their own init routines. That adds up, fast. No idea how is it nowadays, admittedly. Maybe a ton of optimization work was done.
- Mashimo 5mo ago> I have not worked with Java in a long time > No idea how is it nowadays, admittedly. Yes, between Java 8 and modern java there were changes to the GC, startup time, JIT and probably more. If you want, it java should now start pretty quickly.