From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail203.messagelabs.com (mail203.messagelabs.com [216.82.254.243]) by kanga.kvack.org (Postfix) with ESMTP id BFD456007BA for ; Tue, 5 Jan 2010 03:18:57 -0500 (EST) Subject: Re: [RFC][PATCH 6/8] mm: handle_speculative_fault() From: Peter Zijlstra In-Reply-To: References: <20100104182429.833180340@chello.nl> <20100104182813.753545361@chello.nl> <20100105092559.1de8b613.kamezawa.hiroyu@jp.fujitsu.com> <28c262361001042029w4b95f226lf54a3ed6a4291a3b@mail.gmail.com> <20100105134357.4bfb4951.kamezawa.hiroyu@jp.fujitsu.com> Content-Type: text/plain; charset="UTF-8" Date: Tue, 05 Jan 2010 09:18:16 +0100 Message-ID: <1262679496.2400.14.camel@laptop> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: owner-linux-mm@kvack.org To: Linus Torvalds Cc: KAMEZAWA Hiroyuki , Minchan Kim , "Paul E. McKenney" , "linux-kernel@vger.kernel.org" , "linux-mm@kvack.org" , cl@linux-foundation.org, "hugh.dickins" , Nick Piggin , Ingo Molnar List-ID: On Mon, 2010-01-04 at 21:10 -0800, Linus Torvalds wrote: > Sounds doable. But it also sounds way more expensive than the current VM > fault handling, which is pretty close to optimal for single-threaded > cases.. That RCU lookup might be cheap, but just the refcount is generally > going to be as expensive as a lock. Right, that refcount adds two atomic ops, the only grace it has is that its in the vma as opposed to the mm, but there are plenty workloads that concentrate on a single vma, in which case you get an equally contended cacheline as with the mmap_sem. I was trying to avoid having to have that refcount, but then sorta forgot about the actual fault handlers also poking at the vma :/ -- 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