Over time Hotspot and the JIT will convert the interpreted code into native code using profiling information.
随着时间的流逝,Hotspot和JIT会根据收集的信息将解释型代码转化为本机代码。
But performing a task with interpreted code and performing it with compiled code can take significantly different amounts of time.
但是使用解释后的代码执行任务和使用编译后的代码执行任务在时间上有巨大的差异。
Let's say you're going to time 200,000 iterations through a loop, and the compiled code is 10 times faster than the interpreted code.
假设您正在通过循环计时200,000次迭代,编译代码比解释代码快10倍。
an interpreted language is often easier to debug, because you can still see your raw code there, but it's not always as fast.
解释语言调试起来很容易,因为你可以看到最原始的代码,但是这种语言不够快。
What that basically says is the following: in an interpreted language, you take what's called the source code, the thing you write, it may go through a simple checker but it basically goes to the interpreter, that thing inside the machine that's going to control the flow of going through each one of the instructions, and give you an output.
也就说,如果是解释语言的话:,你要写一些叫做,源码的东西,你写的东西会经过一个简单的过滤器,然后解释器会处理你的源码,解释器会产生一个,逐条读取你的源码的,控制流,然后返回一个输出结果。
应用推荐