Re: Q: behaviour of mlockall(MCL_FUTURE) and VM_GROWSDOWN segments
Manfred Spraul (firstname.lastname@example.org)
Sat, 12 Jan 2002 17:07:42 +0100
Andi Kleen wrote:
> For the stack they can get minor faults anyways when they allocate new
> stack space below ESP. There is no good way to fix that from the kernel; the
> application has to preallocate its memory on stack. I think it's reasonable
> if it does the same for holes on the stack.
Ok, everyone agrees that mlockall() should not grow VM_GROWSDOWN
segments to their maximum size.
Should the page fault handler fill the hole created by
void * grow_stack(void)
data = '0';
The principle of least surprise would mean filling holes, but OTHO sane
apps would use memset(data,0,sizeof(data)).
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to email@example.com
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/