Faster sort?
tsbockman via Digitalmars-d
digitalmars-d at puremagic.com
Thu Apr 7 02:01:14 PDT 2016
On Thursday, 7 April 2016 at 08:23:09 UTC, John Colvin wrote:
> But it definitely can eliminate an unused result. My
> prediction: you took an array and sorted it, then did nothing
> with the result, so it rightly concluded that there was no
> point doing the sort. In any given case the compiler could be
> removing some or all of the work.
>
> Laborious approach that defeats the optimisations you don't
> want while keeping the ones you do:
It's easier to just output the result in some form. I typically
calculate and display a checksum of some sort.
More information about the Digitalmars-d
mailing list