From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30020 invoked by alias); 3 Sep 2010 14:06:09 -0000 Received: (qmail 29936 invoked by uid 22791); 3 Sep 2010 14:06:07 -0000 X-SWARE-Spam-Status: No, hits=-5.6 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,SPF_HELO_PASS,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 03 Sep 2010 14:06:02 +0000 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o83E5wtC019527 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 3 Sep 2010 10:05:58 -0400 Received: from fche.csb (vpn-8-23.rdu.redhat.com [10.11.8.23]) by int-mx01.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o83E5vTe018264; Fri, 3 Sep 2010 10:05:57 -0400 Received: by fche.csb (Postfix, from userid 2569) id 104F1580F4; Fri, 3 Sep 2010 10:05:56 -0400 (EDT) To: Steven Cc: Hui Zhu , "gdb@sourceware.org" , linux-kernel@vger.kernel.org, Michael Snyder , Marc Khouzam , Thiago Jung Bauermann Subject: Re: Linux Kernel GDB tracepoint module 2010-8-30 release References: <1283504768.2100.43.camel@steven> From: fche@redhat.com (Frank Ch. Eigler) Date: Fri, 03 Sep 2010 14:06:00 -0000 In-Reply-To: <1283504768.2100.43.camel@steven> (mqyoung@gmail.com's message of "Fri, 03 Sep 2010 17:06:08 +0800") Message-ID: User-Agent: Gnus/5.1008 (Gnus v5.10.8) Emacs/21.4 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2010-09/txt/msg00013.txt.bz2 Steven writes: > [...] > (gdb) trace vfs_readdir > Tracepoint 3 at 0xc1175690: file fs/readdir.c, line 23. > (gdb) actions > Enter actions for tracepoint 3, one per line. > End with a line saying just "end". > > collect jiffies_64 > > collect *file > > end By the way, the systemtap equivalent would be: #! /usr/bin/stap -g probe kernel.function("vfs_readdir") { println(%{ jiffies_64 %}) println($file$) } > 2) I can not collect local variable, despite I rebuild the kernel with > -O0 optimization option. what is the problem? Many thanks > ------------------------------------------------------------------- > (gdb) trace fs/readdir.c:29 > Tracepoint 2 at 0xc11756ca: file fs/readdir.c, line 29. > (gdb) actions > Enter actions for tracepoint 2, one per line. > End with a line saying just "end". > > collect res > > end #! /usr/bin/stap probe kernel.statement("*@fs/readdir.c:29") { println($res) } - FChE