JVM
-
Upload
baabtracom-first-coding-school-in-india -
Category
Technology
-
view
368 -
download
1
Transcript of JVM
![Page 1: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/1.jpg)
![Page 2: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/2.jpg)
Sreya [email protected]
mwww.facebook.com/sreyatwitter.com/usernamein.linkedin.com/in/
profilename
JVM
![Page 3: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/3.jpg)
Disclaimer: This presentation is prepared by trainees of baabtra as a part of mentoring program. This is not official document of baabtra –Mentoring PartnerBaabtra-Mentoring Partner is the mentoring division of baabte System Technologies Pvt . Ltd
![Page 4: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/4.jpg)
JAVA
• Java programming language was originally developed by Sun
Microsystems.
• Object Oriented : In Java, everything is an Object based.
• Platform independent.
![Page 5: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/5.jpg)
Virtual Machine
• A virtual machine (VM) is a software implementation of a
machine (for example, a computer) that executes programs
like a physical machine.
• Virtual machines are separated into two major
classifications:
system virtual machine and process virtual machine.
![Page 6: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/6.jpg)
JVM
• A Java virtual machine (JVM) is a process virtual
machine that can execute java byte code.
• JVM converts Java byte code into machine language and
executes it.
• JVM is platform dependent : JVMs are available for many
hardware and software platforms.
• JVM gives Java the flexibility of platform independence.
![Page 7: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/7.jpg)
Diagram of JVM
Java source code Byte codeJava compiler
Java Virtual Machine
Java Interpreter
Computer Operating System
Byte code loaded into JVM
![Page 8: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/8.jpg)
Block DiagramClass loader sub
system
Execution engine
![Page 9: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/9.jpg)
Class loader
• All Java virtual machines include one class loader that is
embedded in the virtual machine.
• Class loader loads java classes into java virtual machine.
• Class loader reads bytecode and creates the instance of
java.lang.class.
![Page 10: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/10.jpg)
Execution engine
• The execution engine helps JVM to convert bytecode into
machine code.
• A mechanism responsible for executing the instructions
contained in the methods of loaded classes.
![Page 11: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/11.jpg)
Stack
• Stack stores various method arguments and local variables of
any method .
• There are three registers that help in stack manipulation.
– Vars register
– Frame register
– Optop register
![Page 12: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/12.jpg)
Sections in stack
• Local variable
– This section contain all local variable being used by current method.
• Execution environment
– Execution section is used to maintain the operation of stack itself.
• Operand stack
– The operand stack is used as a work space by bytecode instruction.
![Page 13: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/13.jpg)
Method Area
• This is the area where byte code is placed.
• The program counter points to the next instruction in the
method area.
• After the execution of an instruction , JVM set pc to next
instruction.
![Page 14: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/14.jpg)
Garbage Collected Heap
• The object in java program are stored in Garbage collected
heap.
• Arrays in java program are objects, hence they also stored
in heap.
• Java does not have a free operator to free any previously
allocated memory.
• Java done this automatically by Garbage collection
mechanism.
![Page 15: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/15.jpg)
• JRE is an acronym for Java Runtime Environment.
• Java Runtime Environment contains JVM, class libraries, and
other supporting files.
• It does not contain any development tools such as compiler,
debugger, etc
JRE
![Page 16: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/16.jpg)
JDK
• JDK is an acronym for Java Development Kit . It physically
exists . It contains JRE + development tools.
![Page 17: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/17.jpg)
JIT
• Just-in-time Compiler -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.
![Page 18: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/18.jpg)
Is java a compiled or interpreted language ?
• Java is a compiled language because the source code is
converted into byte code.
• Java is an interpreted language because the byte code is
interpreted by a virtual machine.
![Page 19: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/19.jpg)
THANK YOU
![Page 20: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/20.jpg)
Want to learn more about programming or Looking to become a good programmer?
Are you wasting time on searching so many contents online?
Do you want to learn things quickly?
Tired of spending huge amount of money to become a Software professional?
Do an online course @ baabtra.com
We put industry standards to practice. Our structured, activity based courses are so designed to make a quick, good software professional out of anybody who holds a passion for coding.
![Page 21: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/21.jpg)
Follow us @ twitter.com/baabtra
Like us @ facebook.com/baabtra
Subscribe to us @ youtube.com/baabtra
Become a follower @ slideshare.net/BaabtraMentoringPartner
Connect to us @ in.linkedin.com/in/baabtra
Give a feedback @ massbaab.com/baabtra
Thanks in advance
www.baabtra.com | www.massbaab.com |www.baabte.com
![Page 22: JVM](https://reader033.fdocuments.net/reader033/viewer/2022060110/555c3ed9d8b42a2c068b4c35/html5/thumbnails/22.jpg)
Emarald Mall (Big Bazar Building)Mavoor Road, Kozhikode,Kerala, India.Ph: + 91 – 495 40 25 550
NC Complex, Near Bus StandMukkam, Kozhikode,Kerala, India.Ph: + 91 – 495 40 25 550
Cafit Square,Hilite Business Park,Near Pantheerankavu,Kozhikode
Start up VillageEranakulam,Kerala, India.Email: [email protected]
Contact Us