memory areas are allocated by JVM

Java Predefined & User defined Methods, Java String Methods, Java Number Methods, Java Array Methods and Java Character Methods. Java User defined methods with return a value, User defined methods without return any value, and Java Static & Non-static Methods.
Post Reply
Posts: 30
Joined: Sun Mar 31, 2019 3:07 pm

memory areas are allocated by JVM

Post by tejaswini1 » Wed Apr 17, 2019 4:54 pm

How many types of memory areas are allocated by JVM?

Teja Reddy
Posts: 38
Joined: Sun Mar 31, 2019 6:24 am

Re: memory areas are allocated by JVM

Post by Teja Reddy » Wed Apr 17, 2019 4:56 pm

Many types:

Class(Method) Area: Class Area stores per-class structures such as the runtime constant pool, field, method data, and the code for methods.
Heap: It is the runtime data area in which the memory is allocated to the objects
Stack: Java Stack stores frames. It holds local variables and partial results, and plays a part in method invocation and return. Each thread has a private JVM stack, created at the same time as the thread. A new frame is created each time a method is invoked. A frame is destroyed when its method invocation completes.
Program Counter Register: PC (program counter) register contains the address of the Java virtual machine instruction currently being executed.
Native Method Stack: It contains all the native methods used in the application.

Post Reply

Return to “Java Methods”