Skip to content

Comment on The HipHop Virtual Machine

Comments

So, a couple of questions:

a. Does the HHVM JIT do anything that LuaJIT doesn't? I assume you are familiar with LuaJIT, as it is mentioned in the paper - and from a quick scan, the only two things I didn't recognize from LuaJIT were the refcount optimizations (not required by Lua GC) and guard relaxation.

b. Is HHIR tied to Php, or is it usable as a general purpose JIT backend? LuaJIT's IR is, (unfortunately for other languages) tied very strongly to Lua semantics.

Thanks for an interesting read!

It's a shame. As far as I can tell, the only proven multi-language JIT for FOSS platforms is still the JVM? (and Mono maybe?)

Despite a lot of that's gone in to Parrot, PyPy, v8, etc, none of these VMs seem to have really taken off beyond the language they were intended for. Somewhat more sad is that pretty much all de-facto default runtimes for popular dynamic languages (except Javascript) are still interpreters... the cost of being portable.

I wouldn't say the JVM is a proven multi-language JIT, FOSS or not.

It works for multiple languages that go the extra mile - e.g. Jython pays very dearly in performance because of the object model mismatch between Python and Java. And I haven't looked closely recently, but when Clojure first came out, the impedance mismatch between Clojure's persistent data structures and Java's mutable ones also had a ridiculous performance cost.

Mono is perhaps more deserving of that title, especially together with IKVM, (so, everything JVM), F#, IronPython and Boo. But note that everything is still shackled to the underlying object model.

But if anything, LLVM is the only proven multi-language JIT for FOSS platforms; it's method-at-a-time, which is great for staticly typed languages (whether those types are declared upfront or inferred), not so much for extremely dynamic languages.

Scala is pretty widely used. JRuby seems to do quite well as well.

Future times should be interesting as well. I'd be interested to know if the work on value types in the JVM would be useful for Clojure.

The JVM is multi-language only because the languages were specifically designed and/or modified to run on it.

What about Guile?

Does anyone use Guile for anything other than Scheme? I thought all of the other languages were pretty much just half-baked proofs of concept (like Parrot, for that matter).

As a POC I wrote a rudimentary PHP-to-Lua converter to test this [1] (very limited in features). It performed very well.

1 - https://github.com/cretz/meh

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.