[pypy-dev] connecting multiple interpreters (was: Re: change of strategy for the py3k branch?)
Michael Foord
fuzzyman at gmail.com
Mon Jun 4 16:26:15 CEST 2012
On 4 June 2012 14:33, Armin Rigo <arigo at tunes.org> wrote:
> Hi Martijn, hi Holger,
>
> On 6/1/12, Martijn Faassen <faassen at startifact.com> wrote:
> > Concerning performance overhead of proxies, lifecycle issues would be
> > tricky
>
> If, hypothetically speaking, there is someone interested in writing a
> PyPy solution where both a Python2 and a Python3 interpreter are
> running in the same process, then you gain the advantage of having
> only one GC to run both. At least it transparently solves the issues
> of lifetime and reference cycles. (You also have for free only one
> JIT, which can do cross-language optimizations like inlining a Python2
> function into a Python3 context or vice-versa). I see these two
> points as benefits that you don't have in any multi-process solution.
>
> It would require some work on the PyPy side, and I'm not aware of
> anybody ready to invest time in that, but it shouldn't be particularly
> hard (once PyPy's Python3 interpreter is ready, and once people agree
> about which API to use to do cross-language calls.)
>
>
>
Having multiple interpreter instances within a single process allows for
lots of interesting possibilities. IronPython permits this and it was used
by Resolver One - just one of the reasons (along with the GIL) that it
would have been much harder to write Resolver One in CPython than in
IronPython (although .NET was chosen as a platform before Python was chosen
as an implementation language).
Allowing Python 2 and Python 3 to live within the same process would be
very interesting.
All the best,
Michael Foord
> A bientôt,
>
> Armin.
> _______________________________________________
> pypy-dev mailing list
> pypy-dev at python.org
> http://mail.python.org/mailman/listinfo/pypy-dev
>
--
http://www.voidspace.org.uk/
May you do good and not evil
May you find forgiveness for yourself and forgive others
May you share freely, never taking more than you give.
-- the sqlite blessing http://www.sqlite.org/different.html
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/pypy-dev/attachments/20120604/c6cf39f8/attachment.html>
More information about the pypy-dev
mailing list