Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753738Ab0AZXee (ORCPT ); Tue, 26 Jan 2010 18:34:34 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753610Ab0AZXed (ORCPT ); Tue, 26 Jan 2010 18:34:33 -0500 Received: from mx1.redhat.com ([209.132.183.28]:2792 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752060Ab0AZXec (ORCPT ); Tue, 26 Jan 2010 18:34:32 -0500 Date: Wed, 27 Jan 2010 00:32:42 +0100 From: Oleg Nesterov To: Andi Kleen Cc: Linus Torvalds , tromey@redhat.com, Stephen Rothwell , Kyle Moffett , Peter Zijlstra , Peter Zijlstra , Fr??d??ric Weisbecker , Steven Rostedt , LKML , Arnaldo Carvalho de Melo , "Frank Ch. Eigler" , linux-next@vger.kernel.org, "H. Peter Anvin" , utrace-devel@redhat.com, Thomas Gleixner Subject: Re: linux-next: add utrace tree Message-ID: <20100126233242.GA25575@redhat.com> References: <877hr4g49l.fsf@basil.nowhere.org> <20100126210232.GF6567@basil.fritz.box> <20100126215349.GB19146@redhat.com> <20100126220301.GG6567@basil.fritz.box> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20100126220301.GG6567@basil.fritz.box> User-Agent: Mutt/1.5.18 (2008-05-17) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1220 Lines: 30 On 01/26, Andi Kleen wrote: > > > Simple example. Try to debug/strace strace ot gdb itself. Not trivial, > > you can't attach to strace's tracees. Recently I spent 2 days trying to > > understand why strace -f hangs. I was able to attach to strace, but > > I wasn't able to see what its tracees do. > > But what would the semantics be inside the tracees even if you could? In this particular case, all I need was something like "gdb -p" to attach to the tracee, see the backtrace and detach. > > And, it was not possible to even trace strace until it hangs, with > > ptrace the tracee (strace) must stop to report the event and this > > shadowed the race. > > "Shadowing the race" was the second surname of strace I thought anyways @) > Basically if you care about races never use strace in the first place. Yes. And utrace doesn't require the tracee to be stopped to report the event ;) Yes, yes, utrace can't "fix" strace in this sense automatically, but still. Oleg. -- 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/