> [This note supersedes my previous one. 
>  The previous version of this note contained junk
>  in the transcript at the end that didn't belong.]
> 
> I'm trying to play around with GHC's memo function,
> but am encountering segmentation faults whenever 
> I try to get a heap profile of a simple program 
> that uses memo, as indicated in the following 
> transcript: 
> 
>   [fturbak@lefkas test]$ GHCMemoCyclist 2 10 
>   01
>   [fturbak@lefkas test]$ GHCMemoCyclist 2 100
>   01
>   [fturbak@lefkas test]$ GHCMemoCyclist 2 10 +RTS -hC
>   01
>   Segmentation fault
>   [fturbak@lefkas test]$ GHCMemoCyclist 2 100 +RTS -hC
>   Segmentation fault

Thanks for the report, and sorry for the delay in getting back to you.
This is indeed a bug in 4.08.2, which I've fixed in the CVS sources
(both 4.08 branch and the HEAD).  Unfortunately there's no workaround,
except to get the latest sources and upgrade the RTS.

> --------------------------------------------------------------
> -----------------
> -- (2) Contents of Makefile
> 
> # Note: I am using ghc-4.08 and gcc version 2.95 for these tests. 
> HC      = 
> /home/lumberjacks/deforest/ghc-4.08/fptools-newgcc-build/bin/g
> hc-4.08 -lHSutil_p -lHSlang_p -lHSconcurrent_p

BTW, better to use "-package util -package lang -package concurrent"
than to name the libraries explicitly.

> HC_OPTS = -v -O 
> -i.:/home/lumberjacks/deforest/ghc-4.08/fptools-newgcc-build/g
hc/lib/std:/home/lumberjacks/deforest/ghc->
4.08/fptools-newgcc-build/hslibs/util:/home/lumberjacks/defore
> st/ghc-4.08/fptools-newgcc-build/hslibs/concurrent:/home/lumbe
> rjacks/deforest/ghc-4.08/fptools-newgcc-build/hslibs/lang 
> -prof -auto-all

If you use the package options, you shouldn't need the explicit -i<path>
flags.

Cheers,
        Simon

_______________________________________________
Glasgow-haskell-bugs mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs

Reply via email to