3 ms·
I would love to see benchmarks against ruby 1.9.2. Perl always had comparable speed to ruby 1.8.6 with lower memory consumption and cpu usage. Now hopefully it'
by chuhnk 15y ago
I would love to see benchmarks against ruby 1.9.2. Perl always had comparable speed to ruby 1.8.6 with lower memory consumption and cpu usage. Now hopefully it'll be equivalent to ruby 1.9.2.
- old-gregg 15y agoNot following you here, how can speed of one language be the same as another's, but "with lower cpu usage"?
- draegtun 15y agoIf you check (historically) the benchmarks on http://shootout.alioth.debian.org/ http://shootout.alioth.debian.org/ then: * perl5 was always a 2-4 times faster than than ruby 1.8 * perl5 & ruby 1.9 are comparable usually swapping places on different "Which programming languages are fastest?" benchmarks * When taking in above speed benchmarks, memory used & code-used then perl5 just nudges in front of ruby 1.9. See "Which programming language is best?"
- igouy 15y agoHow did you check (historically) ?
- ojosilva 15y agoHere are some quick, unsophisticated benchmarks of a "Hello World" test web server. I ran it in our dev server (Centos 5.3 i386). Ran with ab -t 30 a few times and chose the fastest of the batch. Perl 5.14, Dancer 1.3040, HTTP::Server::PSGI: Requests per second: 856.48 [#/sec] (mean) Memory after tests: 11296 (VSZ) 7632 (RSS) Ruby 1.9.2, Sinatra 1.2.6, WEBRick 1.3.1: Requests per second: 402.72 [#/sec] (mean) Memory after tests: 20612 (VSZ) 10628 (RSS) I know. This is not, by any means, serious language benchmarks (ie. Sinatra, WEBRick, Dancer are interfering), but they give me a rough idea of how things can perform side-by-side for a given setup. I'm also a fan of running quick string management tests to roughly benchmark interpreters at a given servers, since most of our codebase do a lot of string manip. Here's a 1MB mem alloc + cat test: Ruby 1.9.2: $ time ruby -e 'x=""; (1..999999).each { x << "a" }' real 0m0.313s user 0m0.277s sys 0m0.026s Perl 5.14: $ time perl -E '$x.="a" for 1..999999' real 0m0.167s user 0m0.139s sys 0m0.020s As I said, this is completely unscientific. There are much better ways of benchmarking languages out there.
- igouy 15y agohttp://shootout.alioth.debian.org/u32q/benchmark.php?test=all&lang=perl&lang2=yarv http://shootout.alioth.debian.org/u32q/benchmark.php?test=al...