I'm attempting to integrate my rpython interpreter with libgmp, and I'm a
bit confused in how to call the library from my rpython code. it seems we
have three ways?

rlib.libffi (deprecated?)
rlib.jit_libffi
rlib.clibffi

Which of these is prefered for a from-scratch rpython interpreter? In
addition, I've looked at the code for each of these and it's not terribly
clear how to go about something like this (in psudeocode):

mpz = malloc(sizeof(size_t) * 3)
__gmpz_init_set_si(mpz, (signed long)val)

the struct passed around in mpz can be opaque to the interpreter as it will
only ever be access via gmp functions.

Thanks for the help,

Timothy Baldridge
_______________________________________________
pypy-dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-dev

Reply via email to