Is Unladen Swallow dead?
nagle at animats.com
Fri Nov 19 04:57:44 CET 2010
On 11/18/2010 5:35 PM, Mark Wooding wrote:
> John Nagle<nagle at animats.com> writes:
>> Python is defined by what a naive interpreter with late binding
>> and dynamic name lookups, like CPython, can easily implement. Simply
>> emulating the semantics of CPython with generated code doesn't help
>> all that much.
>> Because you can "monkey patch" Python objects from outside the
>> class, a local compiler, like a JIT, can't turn name lookups into hard
>> bindings. Nor can it make reliable decisions about the types of
> But it /can/ make guesses. A dynamic runtime doesn't have to predict
> everything right in advance; it only has to predict most things sort of
> well enough, and fix up the things it got wrong before anyone notices.
> For example, A Python compiler could inline a function call if it makes
> a note to recompile the calling function if the called function is
> modified. Most functions aren't redefined, so this is probably a pretty
> good guess.
>> That adds a sizable performance penalty. Short of global program
>> analysis, the compiler can't tell when code for the hard cases needs
>> to be generated.
> The right approach is to guess that things are going to be done the easy
> way, and then detect when the guess is wrong.
easy. See this talk on JaegerMonkey:
of the installed base.
The Unladen Swallow people had plans to go in that direction, but they
underestimated the size of the job.
More information about the Python-list