From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail190.messagelabs.com (mail190.messagelabs.com [216.82.249.51]) by kanga.kvack.org (Postfix) with ESMTP id 2DAF86B01E3 for ; Thu, 22 Apr 2010 04:30:32 -0400 (EDT) Message-ID: <4BCED815.90704@kernel.org> Date: Wed, 21 Apr 2010 12:48:53 +0200 From: Tejun Heo MIME-Version: 1.0 Subject: Re: [PATCH 2/6] change alloc function in pcpu_alloc_pages References: <4BC6CB30.7030308@kernel.org> <4BC6E581.1000604@kernel.org> <4BC6FBC8.9090204@kernel.org> <1271606079.2100.159.camel@barrios-desktop> <4BCCD8BD.1020307@kernel.org> <20100420150522.GG19264@csn.ul.ie> In-Reply-To: <20100420150522.GG19264@csn.ul.ie> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Sender: owner-linux-mm@kvack.org To: Mel Gorman Cc: Christoph Lameter , Minchan Kim , Andrew Morton , KAMEZAWA Hiroyuki , Bob Liu , linux-kernel@vger.kernel.org, linux-mm@kvack.org List-ID: Hello, On 04/20/2010 05:05 PM, Mel Gorman wrote: > alloc_pages_exact_node() avoids a branch in a hot path that is checking for > something the caller already knows. That's the reason it exists. Yeah sure but Minchan is trying to tidy up the API by converting alloc_pages_node() users to use alloc_pages_exact_node(), at which point, the distinction becomes pretty useless. Wouldn't just making alloc_pages_node() do what alloc_pages_exact_node() does now and converting all its users be simpler? IIRC, the currently planned transformation looks like the following. alloc_pages() -> alloc_pages_any_node() alloc_pages_node() -> basically gonna be obsoleted by _exact_node alloc_pages_exact_node() -> gonna be used by most NUMA aware allocs So, let's just make sure no one calls alloc_pages_node() w/ -1 nid, kill alloc_pages_node() and rename alloc_pages_exact_node() to alloc_pages_node(). Thanks. -- tejun -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org