[Haskell-cafe] Haskell version of ray tracer code is much slower than the original ML

Philip Armstrong phil at kantaka.co.uk
Thu Jun 21 08:45:04 EDT 2007


On Thu, Jun 21, 2007 at 04:23:37PM +0400, Bulat Ziganshin wrote:
>Thursday, June 21, 2007, 3:36:27 PM, you wrote:
>> revision used Float and it was slower than the current one. Making the
>> datatypes strict also makes no difference.
>
>don't forget to use either -funpack-strict-fields or {#- UNPACK -#} pragma

ahem:

  http://www.kantaka.co.uk/cgi-bin/darcsweb.cgi?r=ray;a=headblob;f=/Makefile

(Assuming you mean -funbox-strict-fields; -funpack-strict-fields
doesn't appear in the ghc 6.6.1 makefile as far as I can see.)

As I said, I've tried the obvious things & they didn't make any
difference. Now I could go sprinkling $!, ! and seq around like
confetti but that seems like giving up really.

Phil

-- 
http://www.kantaka.co.uk/ .oOo. public key: http://www.kantaka.co.uk/gpg.txt


More information about the Haskell-Cafe mailing list