• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

confusing about JVM.

 
Mandar Khire
Ranch Hand
Posts: 569
Android Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I read following links
List of Java virtual machines.
HotSpot.
Da Vinci Machine.

I get question if we compile our program using hotspot (which is primary jvm), after that try to execute in pc which contain other jvm, then our program runs?
What is necessary of these many jvms?
 
Gulsum Ramazanoglu
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Mandar, as far as I understand, JVMs are kind of interpreters taking the compiled Java program(which named, "bytecode") and making it run on an operating system, BY INTERPRETING it.. to be able to interpret, it takes the code and converts it to another code that, THAT operating system understands and run.. to be able to do that, it has to be prepared for THAT specific operating system... so every JVM (which is actually a little program) must be written to run on a specific operating system.. In better words, they are designed to work in this way...
Thats what I understand..
A very useful link is this... Please take a look..
 
Campbell Ritchie
Sheriff
Pie
Posts: 49793
69
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You don't use HotSpot (not "hotspot") to compile a program, but to execute it. The bytecode is identical for all operating systems, so different JVMs can execute it.

Gulsum, Alan Moore has already pointed out the link you quoted is an out of date book: in this thread.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic