Java Virtual Machine (JVM) is an abstract computing machine. Java Runtime Environment (JRE) is an implementation of the JVM. Java Development Kit (JDK) contains JRE along with various development tools like Java libraries, Java source compilers, Java debuggers, bundling and deployment tools.
JVM becomes an instance of JRE at runtime of a java program. It is widely known as a runtime interpreter. The Java virtual machine (JVM) is the cornerstone on top of which the Java technology is built upon. It is the component of the Java technology responsible for its hardware and platform independence. JVM largely helps in the abstraction of inner implementation from the programmers who make use of libraries for their programmes from JDK.

Diagram to show the relations between JVM JRE JDK
JVM Internals
Like a real computing machine, JVM has an instruction set and manipulates various memory areas at run time. Thus for different hardware platforms one has corresponding implementation of JVM available as vendor supplied JREs. It is common to implement a programming language using a virtual machine. Historicaly the best-known virtual machine may be the P-Code machine of UCSD Pascal.
A Java virtual machine instruction consists of an opcode specifying the operation to be performed, followed by zero or more operands embodying values to be operated upon. From the point of view of a compiler, the Java Virtual Machine (JVM)is just another processor with an instruction set, Java bytecode, for which code can be generated. Life cycle is as follows, source code to byte code to be interpreted by the JRE and gets converted to the platform specific executable ones.
Sun’s JVM
Sun’s implementations of the Java virtual machine (JVM) is itself called as JRE. Sun’s JRE is availabe as a separate application and also available as part of JDK. Sun’s Java Development Tool Kit (JDK) comes with utility tools for byte code compilation “javac”. Then execution of the byte codes through java programmes using “java” and many more utilities found in the binary directory of JDK. ‘java’ tools forks the JRE. Implementation of JVMs are also actively released by other companies besides Sun Micro Systems.
JVM for other languages
A JVM can also be used to implement programming languages other than Java. For example, Ada source code can be compiled to Java bytecode, which may then be executed by a Java virtual machine (JVM). That is, any language with functionality that can be expressed in terms of a valid class file can be hosted by the Java virtual machine (JVM). Attracted by a generally available, machine-independent platform, implementors of other languages are turning to the Java virtual machine (JVM) as a delivery vehicle for their languages. PHP with Quercus is such an example.
Just-in-time Compiler (JIT)
JIT is the part of the Java Virtual Machine (JVM) that is used to speed up the execution time. JIT compiles parts of the byte code that have similar functionality at the same time, and hence reduces the amount of time needed for compilation. Here the term “compiler” refers to a translator from the instruction set of a Java virtual machine (JVM) to the instruction set of a specific CPU.














Hi Joe,
Explanation on each are really good.
Thanks and Regards
Srikanth S on May 11th, 2010 2:48 pmSrikanth S
Thanks Srikanth.
Joe on May 11th, 2010 9:58 pmThe picture about the implementation is good. However, I read in the first paragrapth tha JRE is an implementation of JVM and in the very next the I read the reverse of it.
Can you confirm if JRE is the implementation of JVM or JVM is the implementation of JRE?
Also, if JRE is an implementation of JVM, then I assue [JDK, JIT, Compiler] will all come under JDK.
Please confirm my understanding.
Shreyas on July 9th, 2010 7:45 pmWhat you read in the first paragraph and in the next paragraph means the same.
“Java Runtime Environment (JRE) is an implementation of the JVM”. “JVM becomes an instance of JRE at runtime”. These are the two statements you are referring to.
They mean the same. If the second statement is confusing to understand the relationship between jvm and jre, just ignore it. If you understand the larger picture that “Java Runtime Environment (JRE) is an implementation of the JVM” is good.
Over a period, you will digest the complete relationship and difference between jre and jvm.
Joe on July 10th, 2010 3:39 amRealy a nice Explainasion ………
Anonymous on July 21st, 2010 7:03 amI like ur explainasion…..it realy anice one….thnks 4 it.
Amol Bhuibhar on July 21st, 2010 7:04 amThe information is really help. Good Work
Mahesh on August 12th, 2010 5:40 pmThe explaination given is really very good. reading it my most of the concepts are more clear nwo.Thanks
pooja on September 15th, 2010 8:02 amJIT is the part of the Java Virtual Machine (JVM) that is used to speed up the execution time. JIT compiles parts of the byte code that have similar functionality at the same time, and hence reduces the amount of time needed for compilation. Here the term “compiler” refers to a translator from the instruction set of a Java virtual machine (JVM) to the instruction set of a specific CPU.
CHAITALI JADHAV on September 16th, 2010 3:52 amDear sir,
pankaj on November 25th, 2010 1:56 pmI am pankaj kumat jha and read and learn full information about jvm,jre,jit in detail with diagram and really gg
good explanaton….
santhosh on December 13th, 2010 3:20 pmi want to seperate jre from the given java software.. is this possible???
Good explanation!!!
Shyam on January 13th, 2011 9:26 amnice explanation ….with pictures
Thimmappa on March 4th, 2011 11:38 amnice explanation ……with picture….it is so helpful……
Thimmappa on March 4th, 2011 11:38 amnice
dk on March 7th, 2011 5:49 pmsimple and easy to understand explanation.
Vinay on March 9th, 2011 4:00 pmI love the pictorial way of explaining it. Thanks.
kk on March 19th, 2011 11:58 amreally nice description……..
Goutam Sikder on March 22nd, 2011 6:43 amyour information really help me for knowing the internal working of jvm & all other..!!!
Abhi on March 26th, 2011 1:15 pmThank u
very nice description. Provide some data for java IO stream classes…..
Prerna on April 12th, 2011 12:19 pmthank u…gud explanation…:)
Anonymous on April 20th, 2011 4:39 amthanks very much
PRIYA on April 23rd, 2011 5:46 pmThank you, This is the really good explation with the pictures
Tushar Singh on May 21st, 2011 4:57 amI have a doubt…
Java Virtual Machine (JVM) is interpreter But Just-in-time Compiler is the compiler.. Why both Interpreter and Compiler both are needed?
vt on May 22nd, 2011 12:49 pmWhat Functions are done by JVM and what are done by JIT?
thaks… its really usefull..
Manu on June 9th, 2011 6:00 amIn the Diagram what is meant by java compiler is it not at all related to Jvm?
Divya on June 9th, 2011 11:10 amThanks a ton dewd…
peace!
gautam on June 12th, 2011 8:21 amnot very clear specification,but good effort
Ankit Sharma on June 29th, 2011 7:15 amhello sir, Your explanations are very nice and they are easy to understand
rajasekhar on July 13th, 2011 9:47 amthanks shrikant
TAPAN on August 2nd, 2011 5:42 amwell… i love the way you explore things….
Abhishek kumar verma on August 8th, 2011 9:13 amthanks a lot sir for providing us such a good information of Java..
gr8 explanation… just loved it.. :)
shri on September 21st, 2011 5:51 pmhiiiiiii,,,,.
Ram patidar on October 30th, 2011 8:10 pmi got a Question in test.that is
what is JVM.JVM is Compiler or
interpreter
Hi Sir,
your Explanation about jvm,jre are very excelent sir..
thank you
chandu on November 10th, 2011 5:10 pmhii…..joe…thnx for explntion….
Durgesh on November 15th, 2011 9:40 amit was gr8…..thnx again..
nice explanation with diagram
venkat on November 18th, 2011 6:29 amNICE EXPLANATION WITH DIAGRAMI
GOSWAMI SANJAYPURI on November 23rd, 2011 7:47 am[...] binary files are used in a java virtual machine for execution. Java bytecode (instruction to JVM) are interpreted using JVM directly. Latest [...]
Java Binary&hellip on November 27th, 2011 11:25 pmThanks… Short and Sweet.
John Jai on November 30th, 2011 1:12 pmsuper explanation
Anonymous on December 1st, 2011 8:11 amGood explanation
Preetha on December 1st, 2011 9:09 amhi…
Explanation on each are really very
good.
Thanks and Regards
amar bhukya on December 6th, 2011 6:56 pmAmazing!
Vivek on December 8th, 2011 12:35 pmHi Joe…..your way of explanation is good but still there is a little bit confusion in my mind that what do you mean by jre is instantiate of jvm at runtime and how a java application can access OS library function…..Will you please more elaborate it for me???
Shishir Gupta on December 15th, 2011 1:37 pmgood instruction for people like me who or new to java.KIU joe
ZAFF on December 17th, 2011 4:25 pmjoe,
manasi on December 28th, 2011 10:25 amnice explanation man.
tahnks
your teching is simply super very use full
Himakumar on December 28th, 2011 2:53 pmSimply awesome sir, this site is informative, keep doing it sir. :)
Arun K on January 7th, 2012 8:07 amVery Nice Explanation.
Kiran Kadav on January 8th, 2012 2:27 pmI Have 1 Doubt…
Who calls Main method compiler or Interpreter???
Thank u for ur answer sir..
Karpagavalli on January 16th, 2012 8:31 pmPlz post me new blogs of u..
Thanks sir…..
Nigam on January 18th, 2012 8:11 pmNice Explanation.
[...] the above two phases are complete, java virtual machine [...]
JVM Shutdown Hook&hellip on January 23rd, 2012 4:59 amNice explanation.
Rajesh on January 23rd, 2012 12:08 pmThanks for the article Joe!
excellent explanation
thank you sir
chandrashekar
chandrashekar on January 27th, 2012 3:56 pmi want to become a java developer…how to i learn the java in easy way?please tell me
karthik on January 28th, 2012 10:08 amnice material
Anonymous on February 3rd, 2012 3:19 pmnice
siva on February 6th, 2012 2:31 pmreally nice and usefull to us thank you :)
venkateshan on February 10th, 2012 1:39 pmThis website is really nice.It’s very helpful for pepole who are learning java.
padma on February 14th, 2012 11:19 pmHi Joe ,
The article is nice.
Can you tell me that, which one among three of them is plat form independent and plateform dependent (JRE,JVM,JDK).
waiting for your replay.
Thanks,
anurag on February 16th, 2012 11:22 amAnurag
Is JVM is platform independent?
Amit on February 23rd, 2012 5:40 pmhi Joy,
Jitendra on February 27th, 2012 3:47 amThanks for good explanation.
nice,
jamalaiah on March 18th, 2012 9:27 amthanks for good explanation.
i want ur core java total information
veera on March 21st, 2012 12:39 pmnice explanation…
Anonymous on March 21st, 2012 1:05 pmjdk is used for compilation of source code?
shekhar tyagi on March 24th, 2012 11:56 amreally to the point answer
santosh nikam on April 6th, 2012 9:37 pmIt’s Like Simple Formula To Understand These Major Components Of Java…Well Explained Joe! quite helpful…..
Anonymous on April 10th, 2012 2:11 amYns…
[...] object can be customized. out gets initialized by java runtime environment at startup and it can be changed by developer during execution. Instead of standard output, in [...]
System.out.println | All &hellip on May 1st, 2012 7:49 amSir ..
jdk makes class file into bye code.
so jdk acts as a compiler.
which one acts as a interpreter..? jre or jvm?
what do jvm and jre do?
is jvm equipped with jre?
Replu pls sir..thanks in advance…
Prabu on May 13th, 2012 9:57 amHello Where is My previous comments………..?
Prabu on May 13th, 2012 6:43 pmWhere is my previous questions posted in this ?
Prabu on May 13th, 2012 6:49 pmreally great relationships between them. u made them very clear in a clear and perfect diagram no need to go through the paragraphs nice job joe :-)
santhosh reddy on May 23rd, 2012 7:58 pm