From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3900 invoked by alias); 15 Mar 2011 19:46:39 -0000 Received: (qmail 3865 invoked by uid 22791); 15 Mar 2011 19:46:38 -0000 X-SWARE-Spam-Status: No, hits=-3.2 required=5.0 tests=AWL,BAYES_00,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from casper.infradead.org (HELO casper.infradead.org) (85.118.1.10) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 15 Mar 2011 19:46:30 +0000 Received: from j77219.upc-j.chello.nl ([24.132.77.219] helo=dyad.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.72 #1 (Red Hat Linux)) id 1PzaCJ-0003Kl-IS for systemtap@sources.redhat.com; Tue, 15 Mar 2011 19:46:27 +0000 Received: by dyad.programming.kicks-ass.net (Postfix, from userid 65534) id DF73924259; Tue, 15 Mar 2011 20:51:34 +0100 (CET) Received: from [IPv6:::1] (dyad [192.168.0.60]) by dyad.programming.kicks-ass.net (Postfix) with ESMTP id 6DBAA2424A; Tue, 15 Mar 2011 20:51:31 +0100 (CET) Subject: Re: [PATCH v2 2.6.38-rc8-tip 4/20] 4: uprobes: Adding and remove a uprobe in a rb tree. From: Peter Zijlstra To: Thomas Gleixner Cc: Srikar Dronamraju , Ingo Molnar , Steven Rostedt , Linux-mm , Arnaldo Carvalho de Melo , Linus Torvalds , Masami Hiramatsu , Christoph Hellwig , Ananth N Mavinakayanahalli , Andi Kleen , Oleg Nesterov , Andrew Morton , Jim Keniston , Roland McGrath , SystemTap , LKML , "Paul E. McKenney" In-Reply-To: References: <20110314133403.27435.7901.sendpatchset@localhost6.localdomain6> <20110314133444.27435.50684.sendpatchset@localhost6.localdomain6> <20110315173041.GB24254@linux.vnet.ibm.com> Content-Type: text/plain; charset="UTF-8" Date: Tue, 15 Mar 2011 19:46:00 -0000 Message-ID: <1300218499.2250.12.camel@laptop> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Mailing-List: contact systemtap-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: systemtap-owner@sourceware.org X-SW-Source: 2011-q1/txt/msg00436.txt.bz2 On Tue, 2011-03-15 at 20:22 +0100, Thomas Gleixner wrote: > I am not sure if its a good idea to walk the tree > > as and when the tree is changing either because of a insertion or > > deletion of a probe. > > I know that you cannot walk the tree lockless except you would use > some rcu based container for your probes. You can in fact combine a seqlock, rb-trees and RCU to do lockless walks. https://lkml.org/lkml/2010/10/20/160 and https://lkml.org/lkml/2010/10/20/437 But doing that would be an optimization best done once we get all this working nicely.