This is the note I read about the JVM instructions, which I drew to improve my understanding.
1. Data area for each independent thread (unshared)
Separate data regions for each thread include program counters (Programs Counter Register), JVM stacks (JVM stack), and local methods (Native method Stack)
A. Program counter: Used to control every execution of each thread
B.JVM stack: includes the listed stack frames
C. Local method area: Used to support local methods, such as non-Java language methods
2. Data area shared by all threads
All threads share the heap and method area
A. Heap: This is the area that we often deal with, it stores all objects, is created when the JVM is started, and garbage collection is in this area.
B. Method area: It stores code that runs a constant pool (runtime Constant pool), member variable (field), and in-method data, methods (methods), and constructors (constructors).
C. Running a constant pool (runtime Constant pool): It is represented by a single-class or single-node run-time scale that is stored in a class file, and includes several constants, including numeric literals that are known at compile times (numeric literals) and a reference to the method and member variables that the runtime must determine (methods and field references).
E. Stack frame: When the method is called stack frame into the stack, the stack frame includes the local variable array, Operand stack, Reference to Constant Pool.
For more information, refer to the official JVM specification.
JVM run-time data area