首页 > 试题广场 >

Why is ajust-in-time compiler

[问答题]
Why is  ajust-in-time compiler useful for executing Java programs?
推荐
Java is an interpreted language.This means that the JVM interprets the bytecode instructions one at a time.Typically,most interpreted environments are slower than running native binaries,for the interpretation process requires converting each instruction into native machine code.A just-in-time (JIT) compiler compiles the bytecode for a method into native machine code the first time the method is encountered.This means that the Java program is essentially running as a native application (of course,the conversion process of the JIT takes time as well but not as much as bytecode interpretation.)Furthermore,the JIT ***s compiled code so that it may be reused the next time the method is encountered.A Java program that is run by a JIT rather than a traditional interpreter typically runs much faster.
发表于 2018-05-05 21:24:47 回复(0)