I took a compiler, an operating system, a course in computer architecture in graduate school. But I want to see these concepts in a simple but real example (not too theoretical). HelloWorld is a good choice for a simple example.
Not only the life cycle of this small program is interesting, but also the knowledge of how the JVM, OS and architecture can help us become a better programmer.
In short, my question is: am I describing the steps correctly and completely?
In particular, I need your help in the following:
- Indicate any part in which I am mistaken.
- I'm sure I will miss a lot of valuable points, so add any point that makes sense in the life cycle.
I want to know how HelloWorld goes through each layer and then comes back from it. Suppose this program runs on an Intel processor with Ubuntu .
I will keep this post updated by combining good answers until a final answer is accepted.
Below is the HelloWorld program that everyone knows.

It is compiled into bytecode as shown below.

The bytecode is not readable, but we can use javap -classpath . -c HelloWorldto see the mnemonics as follows.

It is then loaded, linked, and initialized in the JVM.

Since it has only one thread, suppose it is the left thread in the next data region of the JVM runtime.

JVM , . Ubuntu " " :

JVM x86? ()
?
?
, , , , 5- MIPS.

:
. API, .