fastSort benchmarking (was Re: Work done so far)
torhu
no at spam.invalid
Mon Jan 21 09:05:49 PST 2008
Matti Niemenmaa wrote:
> This is still pretty impressive. Results from a sort benchmark (and the
> benchmark itself, which requires Tango) are attached. Your code is quite short
> but still knocks the socks off the built-in sort.
Did you have look at Andrei's new sort template in std.algorithm? It
was added in 2.008. I don't know if he plans to optimize it further or
not. It can be used like this:
import std.algorithm, std.functional;
sort!(less)(array); // predicate function from std.functional
sort!("a < b")(array); // comparison inlined by string mixin
More information about the Digitalmars-d
mailing list