Simon Wittber wrote:
On 6/30/06, René <[EMAIL PROTECTED]> wrote:
In general ctypes bindings are slightly slower than C ones.
Pypy 0.9, just released
(http://codespeak.net/pypy/dist/pypy/doc/extcompiler.html)
has a new extension compiler.
From the page:
Modules can be based on ctypes. This is the case in the
pypy/module/readline and pypy/module/_demo examples: they use ctypes
to access functions in external C libraries. When translated to C, the
calls in these examples become static, regular C function calls
This means, ultimately, the ctypes overhead can be removed completely.
Hooray for Pypy!
Looks like that's a big "ultimately". Currently modules must be written
in RPython/RCtypes, with each interpreter-level function wrapping
application-level objects explicitly. RCtypes doesn't yet support
floats, unions or dynamically sized arrays, so I imagine it will be a
long time before something like SDL is pypyable. It will happen one
day, I'm sure, but not in the foreseeable future.
Alex.