4 ms·
the Ruby 2.7 benchmarks [0] seem to shows that Ruby is slightly faster than Python 3, or at least fairly competitive. Though things like Python 3 going from 18
by fouc 6y ago
the Ruby 2.7 benchmarks [0] seem to shows that Ruby is slightly faster than Python 3, or at least fairly competitive.
Though things like Python 3 going from 18.45 seconds to 2.67 seconds on the regex-redux test [1][2] tends to make me question the validity/usefulness of these benchmarks. (inasmuch - how much of it is testing language performance vs bypassing it?)
[0] https://web.archive.org/web/20200301005643/https://benchmarksgame-team.pages.debian.net/benchmarksgame/fastest/yarv-python3.html https://web.archive.org/web/20200301005643/https://benchmark...
[1] https://web.archive.org/web/20191225153009/https://benchmarksgame-team.pages.debian.net/benchmarksgame/performance/regexredux.html https://web.archive.org/web/20191225153009/https://benchmark...
[2] https://web.archive.org/web/20200604134902/https://benchmarksgame-team.pages.debian.net/benchmarksgame/performance/regexredux.html https://web.archive.org/web/20200604134902/https://benchmark...
- p_l 6y agoRuby version of regex-redux uses built-in regex support, and I'm not even sure if it uses it the most performant way. Significant portion of the Python test case is FFI code to directly link PCRE bypassing even normal Python extension support. I guess I should augment some of the SBCL benchmarks with custom assembly then...
- igouy 6y ago> …SBCL benchmarks with custom assembly then… How could that possibly effect the performance of the Ruby regex-redux? :-) "Wanted — Ruby PCRE2 regex-redux program" https://salsa.debian.org/benchmarksgame-team/benchmarksgame/-/issues/374 https://salsa.debian.org/benchmarksgame-team/benchmarksgame/...
- eregon 6y agoI've also found that the Computer Language Benchmarks Game benchmarks tend to be less and less representative of real workloads, due to what the benchmarks do and to the philosophy of "write it to make it fast, not idiomatic, and parallelize things that would typically not be parallelized". Just taking a look at the benchmark code makes it clear it's very far from idiomatic Ruby code.
- igouy 6y agoI think it's unfortunate that you've chosen to make such vague disparaging comments. Here are 37 Ruby programs — https://benchmarksgame-team.pages.debian.net/benchmarksgame/measurements/yarv.html https://benchmarksgame-team.pages.debian.net/benchmarksgame/... Presumbly you can show us 2 lists: which of them are your idea of "idiomatic" and which are not ? Merry Christmas.
- igouy 6y ago> …the philosophy of… Actual quotation — 'You will probably come across people saying that the programs are not idiomatic ("enough"). So read the description and write your own idiomatic program, without programming tricks.' https://salsa.debian.org/benchmarksgame-team/benchmarksgame/-/blob/master/CONTRIBUTING.md#style-guide https://salsa.debian.org/benchmarksgame-team/benchmarksgame/...
- igouy 6y ago> Python 3 going from 18.45 seconds to 2.67 seconds on the regex-redux You do realize those are different programs, don't you? You do realize that both those Python programs are shown in the current measurements, don't you? https://benchmarksgame-team.pages.debian.net/benchmarksgame/performance/regexredux.html https://benchmarksgame-team.pages.debian.net/benchmarksgame/... But if you really want to show us the old Q6600 measurements so many people have complained about, the latest version is here: https://benchmarksgame-team.pages.debian.net/benchmarksgame/q6600/performance/regexredux.html https://benchmarksgame-team.pages.debian.net/benchmarksgame/...