Figure below explains the Runtime data areas that JVM has:

JVM has only two Runtime memory area types.:
- Heap
- Non-Heap
- PC register
- JVM stack
- JVM Heap:
- shared across all the Threads
- Created on JVM start-up
- Memory is reclaimed using the Garbage Collection.
- Heap can be of fixed size or dynamically expandable. Users can expand the memory between permissible limits.
- If JVM Heap is configured for dynamic expansion and sufficient memory is not available then JVM will throw OutOfMemoryError Error
- PC(program Counter) Register: PC is created per Thread. At one time, it executes code of one method for the associated thread.
- If that method is not native, It contains the address of the JVM instruction currently being executed.
- If the method currently being executed by the thread is native, the value of the Java virtual machine's pc register is undefined.
- JVM stack: Each JVM thread has a private Java virtual machine stack, created at the same time as the thread
- It stores frames.frames
- Stacks are similar to conventional language(example,) stacks
- These store local variables, partial results and plays part in method invocation and return
- Size of JVM stack can be fix or expandable. If the size is fixed and for some operation memory required is more than the size then JVM throws StackOverFlowError. If Stack size is dynamically expandable and now if the required memory is more then the available then JVM will throw OutOfMemoryError Error
- Method Area: It is shared among all Java virtual machine threads.It is created on virtual machine start-up.
- It stores per-class structures such as the runtime constant pool, field and method data, and the code for methods and constructors, including the special methods used in class and instance initialization and interface type initialization
- It is logically part of the heap but Specification doesn't restrict this.So it can be independent part also
- if JVM runs short of Method Area memory for a request then OutOfMemoryError Error will be thrown.
- Runtime Constant Pool: Runtime constant Pool memory is allocated from the Method Area. The runtime constant pool for a class or interface is constructed when the class or interface is created by the Java virtual machine.
- It is a per-class or per-interface runtime representation of the constant_pool table in a class file. Similar to symbol table in conventional languages
- It stores different kinds of constants, ranging from numeric literals known at compile time to method and field references that must be resolved at run time.
- Native Method Stacks: These stacks are provided by JVMs that support native methods (methods written in languages other than Java). They are created per thread.
- Local variables's stack
- Operand stack
- Frame Data
- Instance variables are stored in Heap
- Local variables are stored on stack
- Static variables are stored in Method Area
- Arrays are stored on heap