Monday, November 17, 2025

JVM Startup

 After reading this great article:JVM Startup

I tested a few things on my Macbook and on my Ubuntu laptop to see very different startup in Java 25.

On Linux, I see that the first thing it checks is if it is in a container. I don't see that on MacOS.

On linux it checks for hugepage support which is not need or done on MacOS.

It is interesting to see the differences between the two OS.

It is nice to see all the resources allocations that are done and they vary to match the different laptops that I have. 

I feel that there are more details under Linux about the librairies and allocation of resources.

The allocation of the garbage collector seems the same on both and for a start with no parameters it is good to see the same defaults.

A very long output of trace logs but very interesting to compare and learn a little bit more about the startup of a JVM.