[pypy-dev] Questions on the pypy+numpy project
cournape at gmail.com
Mon Oct 17 19:47:14 CEST 2011
On Mon, Oct 17, 2011 at 6:22 PM, Alex Gaynor <alex.gaynor at gmail.com> wrote:
> Why can't you have scipy and friends without a C-API? Presumabley it's all
> code that either manipulates an array or calls into an existing lib to
> manipulate an array. Why can't you write pure python code to manipulate
> arrays and then call into other libs via ctypes and friends?
Sorry, I was not very clear: with scipy *as of today*, you can't make
it work without supporting the numpy C API. What I meant by hiding is
that once a code uses numpy C API and the python C API only through
cython, it becomes much easier to support both CPython and pypy at
least in principle (and the code is more maintainable).
But scipy is basically pure python code + lots of pure fortran/C code
+ wrappers around it. Having something that automatically wraps
C/fortran for pypy is something that seems reasonable for pypy people
to do and would narrow the gap.
More information about the pypy-dev