[Haskell-cafe] Re: FFI and heap memory usage limit

Marcin Kosiba marcin.kosiba at gmail.com
Sun Jun 28 06:59:01 EDT 2009


On Friday 26 June 2009, Simon Marlow wrote:
> Maybe bzlib allocates using malloc()?  That would not be tracked by
> GHC's memory management, but could cause OOM.

probably, because it's a binding to a C library. I'm really busy right now, 
but I'll try and create a small program to repro this error.

> Another problem is that if you ask for a large amount of memory in one
> go, the request is usually honoured immediately, and then we GC shortly
> afterward.  If this is the problem for you, please submit a ticket and
> I'll see whether it can be changed.  You could work around it by calling
> System.Mem.performGC just before allocating the memory.

I've already worked around the problem.
-- 
Marcin Kosiba
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part.
Url : http://www.haskell.org/pipermail/haskell-cafe/attachments/20090628/1bff0edc/attachment.bin


More information about the Haskell-Cafe mailing list