Brian Kearns <[email protected]> added the comment:

Sure, but it's nothing like the factor you talked about. Also, the 'boost' is 
not always positive:

15338900.77 runs/sec, built-in, size = 10, 50000000 runs
7145017.92 runs/sec, with reduce, size = 10, 50000000 runs

2966616.18 runs/sec, built-in, size = 100, 5000000 runs
3396951.23 runs/sec, with reduce, size = 100, 5000000 runs

344860.12 runs/sec, built-in, size = 1000, 500000 runs
563466.53 runs/sec, with reduce, size = 1000, 500000 runs

There may be a remaining optimization to make for min/max, but I'm not even 
sure 
it is justifiably a bug; we're currently 5-6x CPython for builtin min/max. I'd 
say this is an example of a specific optimization for PyPy useful when calling 
min/max on very long lists (which possibly, though maybe not, could be made 
obsolete with later optimizations in PyPy).

________________________________________
PyPy bug tracker <[email protected]>
<https://bugs.pypy.org/issue1414>
________________________________________
_______________________________________________
pypy-issue mailing list
[email protected]
http://mail.python.org/mailman/listinfo/pypy-issue

Reply via email to