[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] linux-user: Reserve space for brk
From: |
Alex Bennée |
Subject: |
Re: [PATCH] linux-user: Reserve space for brk |
Date: |
Mon, 20 Jan 2020 13:46:07 +0000 |
User-agent: |
mu4e 1.3.6; emacs 28.0.50 |
Warner Losh <address@hidden> writes:
> On Fri, Jan 17, 2020 at 4:03 PM Richard Henderson <
> address@hidden> wrote:
>
>> With bad luck, we can wind up with no space at all for brk,
>> which will generally cause the guest malloc to fail.
>>
> ...
>
>> The choice of 16MB is somewhat arbitrary. It's enough for libc
>> to get going, but without being so large that 32-bit guests or
>> 32-bit hosts are in danger of running out of virtual address space.
>> It is expected that libc will be able to fall back to mmap arenas
>> after the limited brk space is exhausted.
>>
>
> The biggest abuser of brk() is emacs, so according to one old wag
> this should be 80MB. Eighty Megabytes And Continuously Swapping.
Is this related to the dumper that it uses? I guess the new dumper
system isn't a problem as I was able to run emacs -nw -q on the buster
image without problem.
--
Alex Bennée