[pypy-dev] offtopic, ontopic, ...
mark florisson
markflorisson88 at gmail.com
Tue Feb 14 16:26:14 CET 2012
On 14 February 2012 15:12, Armin Rigo <arigo at tunes.org> wrote:
> Hi Stefan,
>
> On Tue, Feb 14, 2012 at 14:12, Stefan Behnel <stefan_ml at behnel.de> wrote:
>> Hmm, if that is so, how would you ever want to make PyPy bidirectionally
>> interface with anything at all? How does ctypes even work in PyPy?
>
> I believe you are not understanding my point. Obviously ctypes works
> in PyPy, and not, I believe, in a particularly "lucky" way at all. It
> works by not being written as C code at all, but as (Python and)
> RPython code. The difference of levels between C and RPython is
> essential in PyPy. I just gave tons of examples of why it is so. I
> know it's not a perfect solution for everybody; but we think that
> writing C code (or generating it straight from something else) is not
> the most flexible way to develop software. You may not agree with
> that, and you're free too; but consider that we would be unlikely to
> have a JIT in PyPy at all without the approach we took, so we think
> there is some merit in it.
>
> Note that I'm pushing so much for a Cython that would emit Python code
> instead of C --- but that's mostly for performance reasons on top of
> PyPy. The alternative, which is quicker and only slightly more
> hackish, is to complete the C API of cpyext in PyPy until it works
> well enough. Don't come complaining "it's slow", though. It *is*
> going to be slow.
>
Insofar as that is feasible all the way through (and not just python +
a nicer way to call C functions), that would be great. However, any
attempt in this direction will be very involved, whereas I think
people would be quite happy already to see anything work completely.
Getting all features to work is at least a lot more important than any
performance issues (assuming it won't be horrendously slow :).
> A bientôt,
>
> Armin.
> _______________________________________________
> pypy-dev mailing list
> pypy-dev at python.org
> http://mail.python.org/mailman/listinfo/pypy-dev
More information about the pypy-dev
mailing list