Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753966AbaKDNsx (ORCPT ); Tue, 4 Nov 2014 08:48:53 -0500 Received: from gum.cmpxchg.org ([85.214.110.215]:58289 "EHLO gum.cmpxchg.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753412AbaKDNsv (ORCPT ); Tue, 4 Nov 2014 08:48:51 -0500 Date: Tue, 4 Nov 2014 08:48:41 -0500 From: Johannes Weiner To: Michal Hocko Cc: David Miller , kirill@shutemov.name, akpm@linux-foundation.org, vdavydov@parallels.com, tj@kernel.org, linux-mm@kvack.org, cgroups@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [patch 1/3] mm: embed the memcg pointer directly into struct page Message-ID: <20141104134841.GB18441@phnom.home.cmpxchg.org> References: <20141103210607.GA24091@node.dhcp.inet.fi> <20141103213628.GA11428@phnom.home.cmpxchg.org> <20141103215206.GB24091@node.dhcp.inet.fi> <20141103.165807.2039166055692354811.davem@davemloft.net> <20141103223626.GA12006@phnom.home.cmpxchg.org> <20141104130652.GC22207@dhcp22.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20141104130652.GC22207@dhcp22.suse.cz> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Nov 04, 2014 at 02:06:52PM +0100, Michal Hocko wrote: > The code size grows (~1.5k) most probably due to struct page pointer > arithmetic (but I haven't checked that) but the data section shrinks > for SLAB. So we have additional 1.6k for SLUB. I guess this is > acceptable. > > text data bss dec hex filename > 8427489 887684 3186688 12501861 bec365 mmotm/vmlinux.slab > 8429060 883588 3186688 12499336 beb988 page_cgroup/vmlinux.slab > > 8438894 883428 3186688 12509010 bedf52 mmotm/vmlinux.slub > 8440529 883428 3186688 12510645 bee5b5 page_cgroup/vmlinux.slub That's unexpected. It's not much, but how could the object size grow at all when that much code is removed and we replace the lookups with simple struct member accesses? Are you positive these are the right object files, in the right order? > So to me it sounds like the savings for 64b are worth minor inconvenience > for 32b which is clearly on decline and I would definitely not encourage > people to use PAE kernels with a lot of memory where the difference > might matter. For the most x86 32b deployments (laptops with 4G) the > difference shouldn't be noticeable. I am not familiar with other archs > so the situation might be different there. On 32 bit, the overhead is 0.098% of memory, so 4MB on a 4G machine. This should be acceptable, even for the three people that run on the cutting edge of 3.18-based PAE distribution kernels. :-) > This should probably go into the changelog, I guess. Which part? -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/