Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Just In Time compiler

 
chander shivdasani
Ranch Hand
Posts: 206
Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I have this confusion with Java Compiling and Interpreting process.

Java code is compiled and is converted into bytecode
Then this bytecode is interpreted using interpreters.

My question is, where does JIT comes into picture in this scenario. How does the JIT process differ from the standard interpreters shipped with JVM?
Any links, or references to resources will be appreciated.

Thanks,
Chander
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24211
35
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
JVMs haven't operated as pure interpreters in many years. From your description, take out "intepreted by interpreters" and put in "dynamically compiled into native machine code" instead. A just-in-time compiler does the final step of compilation -- machine code generation -- right before execution ("just in time to be executed"), inside the running virtual machine. Sun's HotSpot JVM goes one further by analyzing the code and concentrating on compiling and optimizing the performance-critical parts.
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
And it's *really* good. I wish Smalltalk VMs had gotten the same love (we're getting there!)
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic