Regex benchmarks in Rust, Scala, D and F#

Andrei Alexandrescu via Digitalmars-d digitalmars-d at puremagic.com
Tue Jan 5 10:20:07 PST 2016


On 01/05/2016 01:13 PM, Martin DraĊĦar via Digitalmars-d wrote:
> Dne 5.1.2016 v 19:09 deadalnix via Digitalmars-d napsal(a):
>> On Tuesday, 5 January 2016 at 17:52:39 UTC, Karthikeyan wrote:
>>> Hi,
>>>
>>> Came across this post in rust-lang subreddit about the regex
>>> benchamrks. Scala surprisingly outperforms D. LDC also gives a good
>>> advantage for efficiency of D.
>>>
>>> http://vaskir.blogspot.ru/2015/09/regular-expressions-rust-vs-f.html
>>
>> I'm willing to bet the bad result D has come from the use of DMD.
>>
>> Honestly, pushing DMD as the reference implementation cost us quite a
>> lot on the PR side of things. D appears to be slower that it really is.
>
> To be fair, they have results for DMD and LDC:
>
> regex - 10.6 s (DMD), 7.8 s (LDC)
> ctRegex! - 6.9 s (DMD), 6.6 s (LDC)
>
> Although no information about compiler switches.

The benchmark measures a mixture of times, not only regex time. Could 
somebody tweak the benchmark and figure what the individual timings are 
(I/O vs. regex vs. the pipeline vs. appending)?  -- Andrei



More information about the Digitalmars-d mailing list