[Pyrex] Can pyrex codes call python objects/methods such as String, re, datetime, os diretively

Andreas Kostyrka andreas at kostyrka.org
Mon Jul 2 23:16:44 UTC 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Well, my experience shows that if one knows the exact Python types
returned, one can gain visible speedups (if not drastic) by using the
specifiy Python type functions, instead of the more generic ones that
Pyrex would generate.

Andreas

Greg Ewing wrote:
> liangxing wrote:
>> My case is retrieveling all record items from a Oracle Database, 
>> within a loop execution. By calling cursor.fetchmany() multi-times, 
>> I found it is quite slow.
> 
> Since the Oracle interface is probably returning an
> ordinary Python list of tuples, there's not much you
> can do to speed it up.
> 
> To get a substantial gain using Pyrex, you would
> need to bypass the Python interface and use whatever
> C interface Oracle provides directly.
> 
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGiYdcHJdudm4KnO0RAqoJAJ0XriwTPeYvQPgSyYFbhm7TIcPEnACfUEgc
L/TVm2cPsNH6PBviZwq88/4=
=kSTP
-----END PGP SIGNATURE-----



More information about the Pyrex mailing list