6 ms·
Out of curiosity I ran the same test on a linux laptop with the Ryzen 7 PRO 6850U CPU. python 3.10: 60s python 3.11: 46s pypy 3.9.12: 6s Looks li
by CalebJohn 4y ago
Out of curiosity I ran the same test on a linux laptop with the Ryzen 7 PRO 6850U CPU.
python 3.10: 60s
python 3.11: 46s
pypy 3.9.12: 6s
Looks like pypy performs comparatively better on x86_64
- nerdponx 4y agoI think PyPy runs under Rosetta on M1, so the overhead is probably from that.
- llimllib 4y agoI don't think so; they released ARM support a while ago: https://doc.pypy.org/en/latest/release-2.1.0.html https://doc.pypy.org/en/latest/release-2.1.0.html (I could be wrong) edit: oh, huh I think you're right that it's running here on rosetta: $ file installs/python/pypy3.9-7.3.9/bin/pypy installs/python/pypy3.9-7.3.9/bin/pypy: Mach-O 64-bit executable x86_64 Wonder if there's a way to run a native version? edit 2: there are nightlies here: https://buildbot.pypy.org/nightly/py3.9/ https://buildbot.pypy.org/nightly/py3.9/ Running the latest, a native binary gives more than 2x speedup: # first you have to allow all the unsigned binaries to run $ xattr -dr com.apple.quarantine pypy-c-jit-106295-5dd3b18303e2-macos_arm64/bin/* # then we get 3.5s: $ time pypy-c-jit-106295-5dd3b18303e2-macos_arm64/bin/pypy nbody.py 10000000 -0.169075164 -0.169077842 real 0m3.522s user 0m3.468s sys 0m0.045s pypy continues to impress!
- llimllib 4y agomakes sense I guess, it's had a lot more development time I'm sure. Thanks!
- deleted 4y ago[deleted]