On Apr 11, 2008, at 1:29 PM, Lisandro Dalcin wrote: > Hi all, perhaps you remember my name from some previous posts (By > Brian Granger) about automatic mem management.
Hi. I have to say I thought your idea of using Strings as refocounted buffers was particularly clever :). > I started to experiment with Cython for (re)implementing mpi4py, a > Python port to MPI[1/2] spec following the API of the standard C++ > bindings for MPI-2. However, I'll to this by only accessing the C > bindings of MPI as defined in MPI-1 and MPI-2. > > In about 4 nights, I was able to wrap a significant portion of MPI > specs, maintaining backwards compatibility with the former mpi4py code > (a mix of pyure Python hand-written C extension). To be honest, I > believed that Cython was just another approach, now I believe Cython > is THE approach. Thanks. That's how I feel too (not that I'm bias or anything... :-). > As it seems the development of Cython is very, very fast (thanks for > that!), I'll do in everyday work following the HG repo 'cython-devel'. Be aware that cython-devel is occasionally unstable, but I usually try and keep it relatively clean. > At some point, I'll try to dive in the Cython internals in order to be > able to fix possible problems. Perhaps at some point I'll ask for > commit permisions. Sure. Also, mercurial is a distributed revision control system, so you don't even need commit permissions to do development. > And then, a small gcc (-Wall -pedantic) warning > > MPI.c: In function __Pyx_UnpackItem: > MPI.c:36454: warning: ISO C90 does not support the `z' printf > length modifier > > Of course, Python2.5 uses '%zd' everywere for printing Py_ssize_t. > Does any one know is this can be worked around ? At first, it's seems > to me that there is no way. I'm not sure, but I bet it's some compiler flag or compiler version issue. Are you using the same compiler you used to compile Python? If it is a compiler version issue, I believe most (all?) instances of % zd are surrounded by ifdef statements anyway, which could be modified to check the compiler as well as python version number. - Robert _______________________________________________ Cython-dev mailing list [email protected] http://codespeak.net/mailman/listinfo/cython-dev
