Re: [RFC PATCH] ipc, mqueue: lazy call kern_mount_data in new namespaces

From: Andrew Morton
Date: Tue Nov 28 2017 - 16:53:22 EST


On Mon, 27 Nov 2017 13:55:50 +0100 Giuseppe Scrivano <gscrivan@xxxxxxxxxx> wrote:

> kern_mount_data is a relatively expensive operation when creating a
> new IPC namespace, so delay the mount until its first usage when not
> creating the the global namespace.
>
> On my machine, the time for creating 1000 new IPC namespaces dropped
> from ~8s to ~2s.

OK, but this simply moves the expense so it happens later on. Why is
that better?