[Haskell-cafe] Performance: MD5

Don Stewart dons at galois.com
Sun May 18 05:17:16 EDT 2008


andrewcoppin:
> Bulat Ziganshin wrote:
> >if you need maximum efficiency,
> >drop all this high-level code and map md5.c to haskell as it was done
> >in Don's blog
> >  
> 
> Wait... you're telling me to give up? To not even try??
> 
> So all that bravado about Haskell enabling higher-level optimisations to 
> produce a result faster than C is actually complete nonesense?

What optimisations were operating in your md5 implementation that you
could expect it do match the C version?

> What an awesome "community" this language has behind it... I'm not sure 
> why I bother.

Andrew, take the time to understand what you're code actually does when
you write it. If you want to write code that matches some heavily
optimised md5 in C (did you look at the C implementation?) then your
Haskell will need to compile down to similar data and control structures.

Does it?

So, as Bulat says, explain why your code should have similar performance
to the C version. It would be much more useful than complaining about
the community who patiently help you day in and out.

-- Don


More information about the Haskell-Cafe mailing list