Hi Kevin, Here is another link about writing extensions for PyPy.
http://doc.pypy.org/en/latest/extending.html John On Tue, Mar 25, 2014 at 9:48 PM, John Camara <[email protected]>wrote: > Hi Kevin, > > More up to date information can be found on the FAQ page > > > http://doc.pypy.org/en/latest/faq.html#do-cpython-extension-modules-work-with-pypy > > The best approach for PyPy is either use a pure Python module if possible > or use a cffi wrapped extension instead of an extension that uses the > CPython CAPI. Often CPython CAPI extensions are wrapping some c library. > Creating a cffi wrapper for the library is actually much simpler than > writing a CPython CAPI wrapper. Quite a few CPython CAPI extensions have > already been wrapped for cffi so make sure to search for one before > creating your own wrapper. If you need to create a wrapper, refer to the > cffi documentation at > > http://cffi.readthedocs.org/en/release-0.8/ > > Extensions wrapped with cffi are compatible with both CPython and PyPy. > On CPython the performance is similar to what you would get if you used > ctypes. How every, under PyPy, the performance is much closer to a native > C call plus the overhead for releasing and acquiring the gil. > > John >
_______________________________________________ pypy-dev mailing list [email protected] https://mail.python.org/mailman/listinfo/pypy-dev
