This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
Re: [Patch]Fix the bug of missing definition of argstr and retstr
Frank Ch. Eigler wrote:
Cai Fei <caifei@cn.fujitsu.com> writes:
[...]
After adding definition of pid and argstr for syscall getpgid, I
checked the tapset
for other syscalls. The same problems of missing definition of argstr
and retstr exist.
There is generally no need to create variables that simply carry empty
strings. The translator will do that automatically if necessary.
My probe definition is :
probe syscall.getpid {
log(sprint(argstr))
}
I used it for tracing syscall getpid, and the following error occured:
Pass 1: parsed user script and 54 library script(s) in
397usr/2sys/399real ms.
semantic error: probe_1526 with unresolved type for identifier 'argstr'
at getpid.stp:2:13
......
But it works well if I change it to
probe syscall.getpid {
log(sprintf("%s\n", argstr))
}
So I think it's better to add all these argstr definitions.
kernel.function("sys_getegid")
{
name = "getegid"
+ argstr = ""
}
The only substantial effect of this is to prevent a probe based on
this alias from using "argstr" as a *numeric* variable.
- FChE
--
A new email address of FJWAN is launched from Apr.1 2007.
The updated address is: caifei@cn.fujitsu.com
--------------------------------------------------
Cai Fei
Development Dept.I
Nanjing Fujitsu Nanda Software Tech. Co., Ltd.(FNST)
caifei@cn.fujitsu.com (å7551-5875)
--------------------------------------------------