[pypy-dev] pypy for typed languages?

Geoffrey Irving irving at naml.us
Fri Mar 13 01:57:21 CET 2009


I've come to the conclusion that JIT compilation is essential to avoid
abstract penalties even for typed languages.  The one sentence summary
is that the C++ inline keyword is exactly the opposite of what you
want: in a JIT language you can have a "flatten" function that
recursively inlines everything that a function calls (including

Thus, I'm curious about whether pypy could be practically applied to a
typed front end language, say with the following basic set of

1. Packed storage such as C structs and arrays.
2. A Hindley Milner polymorphic type system with type classes.

In particular, what restrictions does pypy impose on storage layout?
For example, would it be able to handle dynamically-typed homogeneous
lists, represented as a single pointer to a type object and an array
of structs required to be of that type?

Also, if pypy can target LLVM, how do you imagine the two JIT systems
cooperating (if at all)?


More information about the Pypy-dev mailing list