Live data from Hacker News

PyPy v5.8 released

morepypy.blogspot.com

41–50 of 74 posts

Re: PyPy v5.8 released

#41
Any word on the "single codebase" aspect of supporting both major Python versions? I remember suggesting it years ago at a time when the team wanted to do Mercurial backporting instead. What changed their mind?

That looks like it could fix the lag on CPython releases, so it's a big feature.

Re: PyPy v5.8 released

#42
post #25

Earlier quoted context omitted.

in short - funding. If we can find someone who wants fast numpy AND fast python under the same hood, we can combine the approaches of cpyext and numpypy and make it fast. The project is just too big to do on spare time. I've been trying to find some funding for that for quite a while, but I haven't been able to find any sizable backer just yet. Cheers, Maciej Fijalkowski

Maciej, how much would that require, ballpark? I think this is something there would be massive support for. My company would support it

How much does it cost to pay a knowledgeable engineer for a few years? Probably the better part of a million dollars, at least.

Re: PyPy v5.8 released

#43

Earlier quoted context omitted.

Maciej, how much would that require, ballpark? I think this is something there would be massive support for. My company would support it

How much does it cost to pay a knowledgeable engineer for a few years? Probably the better part of a million dollars, at least.

Is your name Maciej?

Re: PyPy v5.8 released

#44
post #8

Earlier quoted context omitted.

>comparable to some compiled languages Given that python programs usually run an order of magnitude slower than compiled languages even a 2x performance increase doesn't put it in the "comparable" range from my experience. Not bashing python - I use it regularly - but for computational stuff it's a hog unless you're just passing stuff to C libs - like I have a resource build pipeline that does some blender 3D model t…

Blender Python lib by default is not optimized much. It has nothing to do with Python as a language. Use numpy for matrices. If you have to implement an algo with a hot inner loop, use cython or numba. I've never seen 100x difference in Python-C++ rewrite if Python was optimized already. Here is a good article about some of the options: https://rare-technologies.com/word2vec-in-python-part-two-op...

The one time I saw 100x increase in performance in Python-to-C (which was done through Cython) was in code that worked with strings calculating a machine-learning related distance between two strings. The code was doing a lot of accessing particular positions in the strings, which in pure python resulted in slow retrieval of every character (lots of .__getitem__ calls), which were optimized to having 2 predefined empty arrays (in heap, not stack, and their corresponding counters of valid items) and then walking the strings and storing the "hot" values in them.

So it was a very specific case where we could get that 100x speedup at work.

Re: PyPy v5.8 released

#45

Coming from someone who uses python but doesn't really follow alternative compilers, PyPy sounds great. What are some of the downsides, if any? Are you sacrificing library compatibility for faster core+standard libs?

In addition to the missing libraries, which has gotten a lot better in the last few years, it crashes a bit more.

I have a syslog proxy that has one huge incoming stream like 50k msgs/second. CPU Could not keep up with CPython but PyPy runs fine and crashes on some low level JIT assertion every so often. I have it setup to use PyPy on the high volume instances and CPython on the low volume instances.

Re: PyPy v5.8 released

#46

Coming from someone who uses python but doesn't really follow alternative compilers, PyPy sounds great. What are some of the downsides, if any? Are you sacrificing library compatibility for faster core+standard libs?

In addition to the missing libraries, which has gotten a lot better in the last few years, it crashes a bit more.

I have a syslog proxy that has one huge incoming stream like 50k msgs/second. CPU Could not keep up with CPython but PyPy runs fine and crashes on some low leve JIT assertion. I have it setup to use PyPy on the high volume instances and CPython on the low volume instances.

Re: PyPy v5.8 released

#47

Coming from someone who uses python but doesn't really follow alternative compilers, PyPy sounds great. What are some of the downsides, if any? Are you sacrificing library compatibility for faster core+standard libs?

In addition to being incompatible with (some) third-party libraries, pypy tends to use significantly more memory than cpython. It's also slower than cpython for scripts that don't run long enough to warm up the JIT, so you probably wouldn't want to use it by default. (Disclaimer: I'm basing this on experience with older versions of pypy and haven't verified it recently)

He memory thing is still an issue. I had to go thru. Lot of tuning on max GC size to keep it runnable for long times. Too low and it is slow and too high and it kills the box.

Re: PyPy v5.8 released

#49

I have a question and then a general vent 1. Does anyone know the latest update on NumPyPy? PyPy for me is just not a usable proposition because I heavily use Numpy (and Scipy et al). So I am forced to use slow Python + fast Numpy or slow Numpy + fast Python. Very saddening. The C-Extension is just so off the pace, NumPyPy was meant to solve that quandry. And I know some smart Alec will trot out the usual 'downshift…

- Statement: "Python 3 is getting slower" (tense: present continuous).

- Proof: a benchmark based on Python 3.3 (Python 3.3 was released in 2012).

Re: PyPy v5.8 released

#50

I have a question and then a general vent 1. Does anyone know the latest update on NumPyPy? PyPy for me is just not a usable proposition because I heavily use Numpy (and Scipy et al). So I am forced to use slow Python + fast Numpy or slow Numpy + fast Python. Very saddening. The C-Extension is just so off the pace, NumPyPy was meant to solve that quandry. And I know some smart Alec will trot out the usual 'downshift…

What are you currently using to solve that problem? I've ran into that problem too, and had to use C-extensions to make my code faster, which isn't ideal.
Post reply on HN