On Wed, Feb 2, 2011 at 6:29 PM, Fredrik Johansson < fredrik.johans...@gmail.com> wrote:
> On Thu, Feb 3, 2011 at 12:10 AM, Amaury Forgeot d'Arc > <amaur...@gmail.com> wrote: > > 2011/2/3 Fredrik Johansson <fredrik.johans...@gmail.com>: > >> Indeed (that user was me, and it was nice to see the problem fixed so > >> quickly!). There is one incompatibility left between CPython and PyPy > >> that breaks some functions in mpmath. In CPython, round() and > >> functions in the math module accept (and convert) inputs of any custom > >> type with a __float__ method, whereas they trigger a TypeError in PyPy > >> (1.4). > > > > It seems corrected today; the script below indeed fails with pypy-1.4. > > Ah, that's nice. Does round() work as well? > > >> On win32, PyPy 1.4 is about 40% slower than CPython 2.6 for running > >> the entire set of tests. This is probably mostly due to the slowness > >> of longs in PyPy. However, much of the regular floating point code > >> seems to be slower in PyPy as well. > > > > The standard operations, or the math module? > > It seems that every function in the math module releases the GIL. > > This may explain some slowness. > > I have only looked at some quick macro level timings. Generally a lot > of overhead for function calls and type checking is involved (although > I would hope that PyPy can kill precisely some of that eventually). > > Fredrik > _______________________________________________ > pypy-dev@codespeak.net > http://codespeak.net/mailman/listinfo/pypy-dev > If you have any benchmarks where we are slower that don't involve longs that'd be great, since for float operations we really should be able to beat up on CPython. Alex -- "I disapprove of what you say, but I will defend to the death your right to say it." -- Evelyn Beatrice Hall (summarizing Voltaire) "The people's good is the highest law." -- Cicero
_______________________________________________ pypy-dev@codespeak.net http://codespeak.net/mailman/listinfo/pypy-dev