PHP v. Perl v. Python ... Questions ...
Joe Stump
joe at digg.com
Mon Jan 7 18:06:21 UTC 2008
Has anyone benchmarked Gearman's speed when running no-op tasks? I'm
seeing absolutely bizarre things on Linux (2.6.12). I've set up
workers and clients in Python, Perl and PHP and get odd behavior from
all of them (though I'm most interested in getting my PHP code fixed
at this point).
The test setup is 1 gearmand, 1 job that just returns true and a
client that runs that task 25 times in a taskset. PHP and Python both
run these tasksets in the 40ms range. Python is more stable sticking
pretty true at about 41ms per run. PHP is a bit more unstable with
values ranging from 15ms to 63ms (though the average is around 40ms).
Perl is even more bizarre in that it ranges from 0.6ms to 39ms. What
would account for these tasks running in 0.6ms?
An example test run for each is below ...
--Joe
Python:
0.0419089794159
0.0421991348267
0.0101318359375
0.0425651073456
0.041759967804
0.0417029857635
0.0421628952026
0.00922393798828
0.00925397872925
0.0469858646393
PHP:
T: 0.0181191
T: 0.0159421
T: 0.0288019
T: 0.0472040
T: 0.0555351
T: 0.0635679
T: 0.0452640
T: 0.0448749
T: 0.0447688
T: 0.0443289
Perl:
0.000616
0.0401
0.040389
0.040349
0.039609
0.040174
0.000623
0.040178
0.039257
0.03987
More information about the Gearman
mailing list