This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
Re: new feature and discussion: filtering on pids
On Tue, 2005-09-06 at 13:36 -0500, James Dickens wrote:
> >
> > probe kernel.function("sys_open") {
> > if (target() == pid())
> > log (execname()." opens ".user_string($filename))
> > }
> >
> how do you deal with a multithread app that doesn't use CLONE_PID?
> wouldn't the test fail since each thread has a seperate pid?
They have the same parent so change it to read
if (target() == ppid()) or maybe it should be
if (target() == pid() || target() == ppid())
This could also be done automatically.
Martin