xxxxxxxxxx
Java Virtual Machine:
JVM (Java Virtual Machine) is an abstract machine. It is a specification that provides runtime environment in which java bytecode can be executed.
What is JVM :
A specification where working of Java Virtual Machine is specified. But implementation provider is independent to choose the algorithm. Its implementation has been provided by Oracle and other companies.
An implementation Its implementation is known as JRE (Java Runtime Environment).
Runtime Instance Whenever you write java command on the command prompt to run the java class, an instance of JVM is created.
The JVM performs following operation:
Loads code
Verifies code
Executes code
Provides runtime environment
JVM provides definitions for the:
Memory area
Class file format
Register set
Garbage-collected heap
Fatal error reporting etc.
xxxxxxxxxx
JVM:
1. JVM is an abstract machine.
Because it doesn't physically exist.
2. It is a very important part of both JDK
and JRE because it is inbuilt in both.
3. Whatever Java program we want to run, goes into JVM.
4. And JVM is responsible for loading,
verifying and executing the java program
line by line hence it is also known as interpreter.
xxxxxxxxxx
jvm stands for java virtual machine and it s platform dependent which is used to execute the java file i,e .class files.
A Java virtual machine (JVM) is a process virtual machine that can execute Java bytecode. Each Java source file is compiled into a bytecode file, which is executed by the JVM.