lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Stephen Kellett wrote:
> Wouldn't you be better off sitting ontop of a JITing runtime that already 
> supports that? The most obvious candidate being the .Net runtime because 
> that is widespread, seems to be better than the Java one and with Mono for 
> Linux and the DLR for the Web (Windows/Mac/Linux) runs pretty much 
> everywhere.

Nope. Both the CLR and the JVM are designed and optimized for
their primary languages (C# and Java). The impedance mismatch is
too high for efficient execution of any language with different
semantics (in particular most dynamic languages). Neither the
data model nor the code model is at the right abstraction level.
Performance suffers (badly).

It seems the UNCOL lesson has not been learned. Contrary to the
claims that this was due to the immature compiler technology 50
years ago, I claim this approach is flawed by its inherent
complexity. Later attempts (ANDF, Parrot (*)) and their meager
accomplishments backup my point.

What has been proven to work is to design the intermediate layer
either for the source language or the destination language (i.e.
the machine code). Preferably to both. Reducing the degrees of
freedom results in better performance. Trying to solve everything
in one go results in disaster.

    6 years of development, ambitious goals, lots of talented
    developers, 22 MB source, 13 MB binary ... and it's around
    150x-200x slower than a 100 KB VM plus a 30 KB JIT compiler?
    Sad. Very sad.

> Microsoft seem to be pretty keen on helping people move languages to the 
> DLR (IronPython and IronRuby come to mind). The IronPython package ships 
> with source so that you can see how to put a language ontop of the DLR.

The name is just a clever marketing ploy. It's a plain C# library
with some overly complex object wrappers and some helpers for
emitting code at runtime. I remain unimpressed.

Adding complexity and then hoping "the compiler", "a JITting VM"
or "Moore's Law" will magically reduce all of it to nothing is