Re: max-heap setting for 64-bit applications

"Wesley W. Terpstra" <[email protected]>
Newsgroups gmane.comp.lang.ml.mlton.devel
Message-ID <[email protected]>
On Mon, Dec 14, 2009 at 6:53 PM, Matthew Fluet <[email protected]> wrote:
> I was thinking about the 32-bit case, in which case fragmenting the 4G
> VM isn't terribly difficult.

Ok, then let me address your original comment again:
> But, the Windows specific mremap could still fail --- note that the
> growHeap function demands significant growth from mremap.  If that
> fails, then it attempts the alloc/copy, but allowing for an alloc of a
> heap down to the minimum size.

This sounds like a bad idea, then. The problem applies equally to all
platforms (even linux).

So, to be clear, we're talking about this situation:
memory is available for the minimum size
that memory is NOT large enough to accommodate "significant growth"
the memory region contains the current mapping

Under this case, AFAICT, every system fails to grow the heap, though
it should succeed. Both windows and linux would've been fine if the GC
had attempted to use mremap backed off to a lower value.

I submit that this is a bug which should be fixed.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.