[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200619113945.15ff3b15@carbon>
Date: Fri, 19 Jun 2020 11:39:45 +0200
From: Jesper Dangaard Brouer <brouer@...hat.com>
To: Roman Gushchin <guro@...com>
Cc: Vlastimil Babka <vbabka@...e.cz>,
Shakeel Butt <shakeelb@...gle.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Christoph Lameter <cl@...ux.com>,
Johannes Weiner <hannes@...xchg.org>,
Michal Hocko <mhocko@...nel.org>,
Linux MM <linux-mm@...ck.org>,
Kernel Team <kernel-team@...com>,
LKML <linux-kernel@...r.kernel.org>,
Mel Gorman <mgorman@...hsingularity.net>, brouer@...hat.com,
Larry Woodman <lwoodman@...hat.com>
Subject: Re: [PATCH v6 00/19] The new cgroup slab memory controller
On Thu, 18 Jun 2020 18:27:12 -0700
Roman Gushchin <guro@...com> wrote:
> Theoretically speaking it should get worse (especially for non-root allocations),
> but if the difference is not big, it still should be better, because there is
> a big expected win from memory savings/smaller working set/less fragmentation etc.
>
> The only thing I'm slightly worried is what's the effect on root allocations
> if we're sharing slab caches between root- and non-root allocations. Because if
> someone depends so much on the allocation speed, memcg-based accounting can be
> ignored anyway. For most users the cost of allocation is negligible.
> That's why the patch which merges root- and memcg slab caches is put on top
> and can be reverted if somebody will complain.
In general I like this work for saving memory, but you also have to be
aware of the negative consequences of sharing slab caches. At Red Hat
we have experienced very hard to find kernel bugs, that point to memory
corruption at a completely wrong kernel code, because other kernel code
were corrupting the shared slab cache. (Hint a workaround is to enable
SLUB debugging to disable this sharing).
--
Best regards,
Jesper Dangaard Brouer
MSc.CS, Principal Kernel Engineer at Red Hat
LinkedIn: http://www.linkedin.com/in/brouer
Powered by blists - more mailing lists