heapsort shootout rewrite
Stephen Weeks
MLton@sourcelight.com
Wed, 20 Jun 2001 09:35:06 -0700
> I don't see more than 10% either way, but the code is more readable. Here is
> the way I would write it (noopt.sml) and then a tweak to avoid fetching array
> elements more than once (opt.sml). The latter only seemed to buy 3% for the
> 80,000 element case, so it really isn't worth any thing.
Here are the times that I see for the original submission and your two optimized
versions, on both the released MLton version and our internal version.
20000906 internal
original 11.2 5.1
noopt 9.9 5.0
opt 7.8 4.9
Based on this, I think I'll submit noopt. The real moral is we need to get the
release out :-)