PyPy 1.0: JIT compilers for free and more

Kay Schluehr kay.schluehr at gmx.net
Wed Mar 28 18:41:11 CEST 2007


On Mar 28, 4:34 pm, Paul Rubin <http://phr...@NOSPAM.invalid> wrote:
> "Kay Schluehr" <kay.schlu... at gmx.net> writes:
> > A somewhat unrelated question. With Py3K Python gets optional type
> > annotations. Are you already architecting an annotation handler that
> > can process these annotations? This feature is somewhat competitive to
> > all the complicated type inference and jitting you have been worked
> > out so I don't know how it fits well into the current PyPy
> > architecture?
>
> What's the nature of the conflict between annotations and inference?
> Haskell for example has both.

There is no conflict in Haskell because Haskell has a type system by
default. But Python has none and so one had to define RPython, a
subset of Python *viewed* as static enough to be translatable to C
( RPython is of course as polymorphic as any other Python code and can
be fed with arbitrary types. Only the context makes it special ).
RPython is an approximation to Python on which static type inference
is feasible. RPython is yet defined heuristically and this heuristics
might be changed when RPython can be defined by the power of a type
system defined *formally*. So it might be just a matter of reason to
define a typesystem for interpreter/jit level Python code.




More information about the Python-list mailing list