GHC vs. GCC on raw vector addition

Bulat Ziganshin bulatz at
Wed Jan 18 09:08:05 EST 2006

Hello Sven,

Wednesday, January 18, 2006, 3:33:40 PM, you wrote:

SMH> and gets a runtime for the GHC-compiled binary that's about 10x as long
SMH> as for GCC. Simon M. tells me this should be much better. Here are the

attached version is only 5 times slower :)  please note that

1) unsafeRead/Write indexes from 0 and don't checks bounds (just C-like :)
2) generating random values takes about 1.5-2 seconds by itself.
Haskell's RNG is very different from C's one

Best regards,
 Bulat                            mailto:bulatz at
-------------- next part --------------
A non-text attachment was scrubbed...
Name: new.hs
Type: application/octet-stream
Size: 1182 bytes
Desc: not available
Url :

More information about the Glasgow-haskell-users mailing list