RE: [Haskell-cafe] +RTS -M800M
On 16 December 2005 10:05, Joel Reymont wrote:
I'm trying to restrict GHC to 800Mb of heap at runtime by passing in +RTS -M800M, the machine has 1Gb of memory and top shows free physical memory dropping below 175Mb. I suppose I'm missing something obvious or paying attention to the wrong statistics, Unix has a good VM manager after all. Are my runtime options correct, though?
-M800m should do more or less the right thing, but it is possible for GHC to exceed this figure by a small percentage. Rather than considering the "worst case" requirements for the next GC, GHC uses a more "average case" estimate, which sometimes ends up being wrong, but in most cases results in better utilisation of the available memory. Cheers, Simon
"Simon Marlow" <simonmar@microsoft.com> writes:
On 16 December 2005 10:05, Joel Reymont wrote:
I'm trying to restrict GHC to 800Mb of heap at runtime by passing in +RTS -M800M, the machine has 1Gb of memory and top shows free physical memory dropping below 175Mb.
-M800m should do more or less the right thing, but it is possible for GHC to exceed this figure by a small percentage.
Is there any chance there is a bug in recent GHCs (or perhaps Linux?) affecting this? I'm fairly sure I've lately seen Haskell programs consuming significantly larger amounts of memory than they should be allowed to, and I can try to isolate a test case if it is of interest. -k -- If I haven't seen further, it is by standing in the footprints of giants
On Sat, Dec 17, 2005 at 10:56:58PM +0100, Ketil Malde wrote:
Is there any chance there is a bug in recent GHCs (or perhaps Linux?) affecting this? I'm fairly sure I've lately seen Haskell programs consuming significantly larger amounts of memory than they should be allowed to, and I can try to isolate a test case if it is of interest.
It can surely happen when you interface to foreign libraries that allocate memory on their own - outside of GHC's heap. Best regards Tomasz -- I am searching for a programmer who is good at least in some of [Haskell, ML, C++, Linux, FreeBSD, math] for work in Warsaw, Poland
participants (3)
-
Ketil Malde -
Simon Marlow -
Tomasz Zielonka