Re:Let's Remove the Global Interpreter Lock
by zepolen on Tuesday August 15, 2017 @06:42AM
(#15016976)
Could you post the code for that fib program I couldn't find it anywhere.
[ Parent
| on HN ]
Re:Let's Remove the Global Interpreter Lock
by alfanerd on Tuesday August 15, 2017 @05:08PM
(#15022600)
It is in the Gilectomy branch of Larry Hastings github project. (https://github.com/larryhastings/gilectomy)
I also pasted the fib test to pastebin: https://pastebin.com/Ryyb2K7V
Re:Let's Remove the Global Interpreter Lock
by zepolen on Saturday August 19, 2017 @10:37AM
(#15053603)
Ah so just the naive recursive fibonacci on 8 threads with no data sharing between them.
Interestingly doing the same on Cpython using the multiprocessing module was ~2x slower than jython/threads. More interestingly pypy with multiprocessing was ~5x faster than jython/threads.
$ time jython fib.py 40
real 1m11.247s
user 6m14.130s
sys 0m3.012s
$ time python fib.py 40
real 2m4.067s
user 11m46.103s
sys 0m2.352s
$ time pypy fib.py 40
real 0m21.040s
user 1m51.461s
sys 0m1.892s