From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S262237AbUKQMDh (ORCPT ); Wed, 17 Nov 2004 07:03:37 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S262265AbUKQMDh (ORCPT ); Wed, 17 Nov 2004 07:03:37 -0500 Received: from mx1.redhat.com ([66.187.233.31]:49617 "EHLO mx1.redhat.com") by vger.kernel.org with ESMTP id S262237AbUKQMDf (ORCPT ); Wed, 17 Nov 2004 07:03:35 -0500 From: David Howells In-Reply-To: References: <2315.1100630906@redhat.com> <20041116182841.4ff7f2e5.akpm@osdl.org> To: Linus Torvalds Cc: Andrew Morton , hch@infradead.org, linux-kernel@vger.kernel.org Subject: Re: [RFC] Making compound pages mandatory User-Agent: EMH/1.14.1 SEMI/1.14.5 (Awara-Onsen) FLIM/1.14.5 (Demachiyanagi) APEL/10.6 Emacs/21.3 (i386-redhat-linux-gnu) MULE/5.0 (SAKAKI) MIME-Version: 1.0 (generated by SEMI 1.14.5 - "Awara-Onsen") Content-Type: text/plain; charset=US-ASCII Date: Wed, 17 Nov 2004 12:03:22 +0000 Message-ID: <17923.1100693002@redhat.com> Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org > > So I'd suggest that we make compound pages conditional on a new > > CONFIG_COMPOUND_PAGE and make that equal to HUGETLB_PAGE || !MMU. > > That sounds sane, and seems easily done in init/Kconfig. David? That looks reasonable, I think. Would you object to some more micro-optimisations: (1) Allow struct page to be marked __attribute__((align(sizeof(long)*2))) on archs that want it. On frv for instance this would allow the use of double-register load/store instructions when accessing certain adjacent pairs of members (such as page->lru.next and page->lru.prev). I think the frv compiler will emit these when it knows it won't cause a misalignment exception (8-byte accesses must be 8-byte aligned). (2) Allow put_page() to be provided by the arch if desired. This would allow me to do a better job of testing page flags and mucking around with the refcount by writing it in assembly. This is sort of prerequisite on (1) and the fact that accesses to page->_count are atomic and so are inline asm anyway. > [ There's too damn many Davids around. DavidH? Mr Howells? Dude? ] I generally refer to all other Davids as Dave, apart from David Woodhouse who should be referred to as "Fish":-P DavidH would be okay. David