3

Possible Duplicate:
What are bytecodes and how does the JVM handle them

How exactly does the JVM interpret byte codes when it is purely interpreting (rather than JITing or something in betweem)?

One approach that comes to mind is to have a native function for each byte code that takes the JVM state as an argument. A look-up table could be used to get the function pointer given the byte code, and then the function is called. Is that what it does, or is there something more efficient in the pure interpretation case?

Community
  • 1
  • 1
devx
  • 287
  • 1
  • 13
  • If you really want to know you can read the source. How it does it not terribly important because it is only done for code which hasn't run many times. – Peter Lawrey Sep 05 '12 at 16:10
  • 2
    visit [this link](http://stackoverflow.com/questions/2203248/what-are-bytecodes-and-how-does-the-jvm-handle-them). Your question is very well answered here. – Jeevan Patil Sep 05 '12 at 16:16

0 Answers0