Benchmarking GHC

Duncan Coutts duncan.coutts at worc.ox.ac.uk
Thu Oct 19 14:10:38 EDT 2006


On Thu, 2006-10-19 at 21:10 +0400, Bulat Ziganshin wrote:

> btw, writing this message i thought that
> -fconvert-strings-to-ByteStrings option will give a significant boost
> to many programs without rewriting them :)

This kind of data refinement has a side condition on the strictness of
the function. You need to know that your list function is strict in the
spine and elements before it can be swapped to a version that operates
on packed strings. If it's merely strict in the spine then one could
switch to lazy arrays. There's also the possibility to use lists that
are strict in the elements.

It'd be an interesting topic to research, to see if this strictness
analysis and transformation could be done automatically, and indeed if
it is properly meaning preserving.

Duncan



More information about the Glasgow-haskell-users mailing list