From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15996 invoked by alias); 16 May 2007 18:54:20 -0000 Received: (qmail 15986 invoked by uid 22791); 16 May 2007 18:54:19 -0000 X-Spam-Status: No, hits=-0.0 required=5.0 tests=AWL,BAYES_05,DK_POLICY_SIGNSOME,NO_REAL_NAME X-Spam-Check-By: sourceware.org Received: from hati.oit.pdx.edu (HELO hati.oit.pdx.edu) (131.252.120.59) by sourceware.org (qpsmtpd/0.31) with ESMTP; Wed, 16 May 2007 18:54:16 +0000 Received: from lora.oit.pdx.edu (lora.oit.pdx.edu [131.252.120.15]) by hati.oit.pdx.edu (8.13.3+/8.13.1) with ESMTP id l4GIsBwk025393 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT); Wed, 16 May 2007 11:54:11 -0700 Received: from lora.oit.pdx.edu (localhost.localdomain [127.0.0.1]) by lora.oit.pdx.edu (8.13.3+/8.13.1) with ESMTP id l4GIsB5r025766; Wed, 16 May 2007 11:54:11 -0700 X-Authentication-Warning: lora.oit.pdx.edu: Host localhost.localdomain [127.0.0.1] claimed to be lora.oit.pdx.edu Received: (from sec@localhost) by lora.oit.pdx.edu (8.13.3+/8.13.1) id l4GIsA4p025763; Wed, 16 May 2007 11:54:10 -0700 Received: from bi01p1.co.us.ibm.com (bi01p1.co.us.ibm.com [32.97.110.142]) by webmail.pdx.edu (Horde MIME library) with HTTP; Wed, 16 May 2007 11:54:10 -0700 Message-ID: <20070516115410.ho1papvomcggscgs@webmail.pdx.edu> Date: Wed, 16 May 2007 18:54:00 -0000 From: patm@pdx.edu To: David Smith Cc: systemtap@sources.redhat.com Subject: Re: Listing probe alias resolution failures References: <20070515141427.d90m5pfzj4w0owok@webmail.pdx.edu> <464A2714.6040108@redhat.com> <20070515152054.po84o8zlx5yos8sw@webmail.pdx.edu> <464B1122.9090907@redhat.com> <20070516095817.4iq72cr8lpz448oo@webmail.pdx.edu> <464B3DFC.60506@redhat.com> In-Reply-To: <464B3DFC.60506@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; DelSp="Yes"; format="flowed" Content-Disposition: inline Content-Transfer-Encoding: quoted-printable User-Agent: Internet Messaging Program (IMP) H3 (4.1.3) 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: 2007-q2/txt/msg00316.txt.bz2 Quoting David Smith : > patm@pdx.edu wrote: >> Quoting David Smith : >>> The only thing that doesn't work is: >>> >>> # stap -p2 -u -e 'probe syscall.compat_getitimer {}' >>> >>> So, the only error I get is when I explicitly list the system call that >>> doesn't exist on my current arch and kernel. I could see where if you >>> were writing a script targeting either multiple architectures or >>> multiple kernel versions that might bother you. However, the solution >>> is easy - make that probe optional: >>> >>> # stap -p2 -u -e 'probe syscall.compat_getitimer ? { }' >> >> Very nice, I had no idea that you could do this to a probe alias.=20=20= =20 >> But, and I don't know if this is intended or not, it still fails on=20=20 >> certain errors: >> >> $ stap -p2 -u -e 'probe vm.mmap ? { }' >> semantic error: failed to retrieve location attribute for local=20=20=20 >> 'addr' (dieoffset: 0xb84881): identifier '$addr' at > > Hmm. > > Here I've got good news and bad news. The good news is that if you > take away the '-u', then your example works (since the optimizer > removes references to the variables that aren't read). > > The bad news is that if you reference the local variable version of the > function's parameters in your optional probe, it errors out, like this: > > # stap -p2 -e 'probe vm.mmap ? { printf("%p %d\n", address, length) }' > semantic error: failed to retrieve location attribute for local 'addr' > (dieoffset: 0xbf6524): identifier '$addr' at > /usr/local/share/systemtap/tapset/memory.stp:118:15 > ... > > Here it seems like we should be able to discard the probe before trying > to look up its parameters. > > Could you file a bugzilla on this so we don't forget to look at this? I'll file a bug later today. Also, I have found some probes that don't=20=20 seem to behave correctly when used with that conditional (?) : $ stap -p2 -u -e 'probe syscall.compat_sys_times {}' ...mismatch...cannot resolve probe point syscall.compat_sys_times $ stap -p2 -u -e 'probe syscall.compat_sys_times? {}' ...mismatch...cannot resolve probe point syscall.compat_sys_times Mostly syscall probes, especially syscall.compat_* , and=20=20 signal.handle_stop is another example.