Re: [python-committers] CFFI is slow

2016-03-05 Thread Terry Reedy
On 3/5/2016 4:31 AM, Larry Hastings wrote: 2. How important is this speed difference? I believe Pygame originally used SWIG or something similar to wrap the underlying C SDL library. When a ctypes version was tried, it was much slower, so slow that they stayed with the original wrapping. I

Re: [python-committers] CFFI is slow

2016-03-05 Thread Antoine Pitrou
Le 05/03/2016 10:31, Larry Hastings a écrit : > > I always feel a little funny when people talk about performance in > Python. Not that I believe performant Python isn't possible or > desirable--just that, if you're writing your code in Python, you've > already implicitly conceded that performan

Re: [python-committers] CFFI is slow

2016-03-05 Thread Stefan Krah
Larry Hastings hastings.org> writes: > 2. How important is this speed difference?  I suppose the answer, > as always, is "it depends".  It depends on how often you call the > C library, and how long you spend in the routine when you get > there.  Certainly a benchmark for l

Re: [python-committers] CFFI is slow

2016-03-05 Thread Larry Hastings
I guess I have two responses to that. 1. I don't know what it is about cffi that makes it slow. Perhaps it could be improved? If it got a lot of traction, maybe it'd get more eyes looking at it? 2. How important is this speed difference? I suppose the answer, as always, is "it depends".

Re: [python-committers] CFFI is slow (was: Re: Redoing the C API?)

2016-03-05 Thread Stefan Krah
Stefan Krah bytereef.org> writes: > We're talking about a slowdown of at least an order of magnitude here: > > https://mail.python.org/pipermail/python-dev/2013-December/130772.html > > I think people who don't need the C-API can use PyPy. Or, of course, use CPython with Numba, which handles