maciej.wos at gmail.com
Sun Feb 13 17:59:13 CET 2011
I was battling a similar (the same?) issue recently. The problem might
indeed be caused by excessive sharing. There's a good example in GHC's
trac . Try compiling your code with -O2 and -fno-full-laziness.
There is also an issue with full-laziness and recursive overloaded
functions . Again, compiling with -fno-full-laziness should help.
Alternatively, if you're using ghc-7.0.1, try switching to HEAD.
On Sat, Feb 12, 2011 at 7:30 PM, Andrew Coppin
<andrewcoppin at btinternet.com> wrote:
> I have a small program that fills a file with random numbers. If I compile
> it without optimisation, it runs in constant space. And yet, if I supply -O2
> (or even just -O1), for large output files the program gobbles large amounts
> of RAM.
> Is this a known bug? (GHC 6.10.x)
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
More information about the Haskell-Cafe