News for hackers. Stuff that matters.
Re:Let's Build a Simple Interpreter, Part 1 (2015) by chrisseaton on Monday September 12, 2016 @06:12AM (#12478427)
Or V8? V8 doesn't have an interpreter (it is now getting one), but is perhaps the major example of a JIT most people would know.

Saying you need an interpreter is clearly a silly definition of a JIT.

Re:Let's Build a Simple Interpreter, Part 1 (2015) by exDM69 on Monday September 12, 2016 @06:21AM (#12478462)
V8 is definitely a JIT. It might not have an interpreter in the classical meaning of the word, but it does incrementally compile more as type information becomes available.

It compiles some code, executes it and control returns back to either interpreted code or the framework that decides what to compile next. It's a JIT, because it can't be done ahead of time.

Just doing the final stage of code generation at runtime/startup (like, say, PNaCL does) would not qualify. You could as well generate code for all target architectures ahead of time, but it might be more practical to leave that to the client.

Feel free to disagree with my definition, but I like to draw a distinction between just compiling code at runtime and a JIT, that compiles/optimizes code as it becomes possible.

Re:Let's Build a Simple Interpreter, Part 1 (2015) by chrisseaton on Monday September 12, 2016 @07:59AM (#12478931)
> I like to draw a distinction between just compiling code at runtime and [something else] that compiles/optimizes code as it becomes possible

I agree with that, but I call the first thing a JIT, and the second thing a dynamic compiler. There's a PhD someone wrote about the difference but I can't find it now.

Re:Let's Build a Simple Interpreter, Part 1 (2015) by exDM69 on Monday September 12, 2016 @10:14AM (#12479813)
I guess we can agree that the term is somewhat ill defined but the distinction exists :)