Re: [PATCH v2] NOMMU: fix malloc performance by adding uninitialized flag

From: Paul Mundt
Date: Tue Oct 13 2009 - 09:06:01 EST


On Tue, Oct 13, 2009 at 07:20:21AM -0400, Mike Frysinger wrote:
> From: Jie Zhang <jie.zhang@xxxxxxxxxx>
>
> The NOMMU code currently clears all anonymous mmapped memory. While this
> is what we want in the default case, all memory allocation from userspace
> under NOMMU has to go through this interface, including malloc() which is
> allowed to return uninitialized memory. This can easily be a significant
> performance penalty. So for constrained embedded systems were security is
> irrelevant, allow people to avoid clearing memory unnecessarily.
>
> This also alters the ELF-FDPIC binfmt such that it obtains uninitialised
> memory for the brk and stack region.
>
> Signed-off-by: Jie Zhang <jie.zhang@xxxxxxxxxx>
> Signed-off-by: Robin Getz <rgetz@xxxxxxxxxx>
> Signed-off-by: Mike Frysinger <vapier@xxxxxxxxxx>
> Signed-off-by: David Howells <dhowells@xxxxxxxxxx>

Acked-by: Paul Mundt <lethal@xxxxxxxxxxxx>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/