This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: BZ#2421 - removing duplicate probe handlers


On Wednesday, August 02, 2006 2:14 PM, David Smith wrote:
> On Tue, 2006-08-01 at 18:49 -0400, Frank Ch. Eigler wrote:
> The bugzilla references the case we should be optimizing for -
> something like this:
> 
> probe kernel.function("sys_read"), kernel.function("sys_write")
> {
>         log("here")
> }
> 
> In addition, I realized that there are cases where we don't want to
> merge probes even if they are identical (but we could use your idea
> above of reusing the code bodies).  Such as this:
> 
> probe begin { log("here") }
> probe begin { log("here") }
> 
> If we merge those 2 probes into 1, we're only going to get 1 output
> line instead of 2.

I'm a little worried about how you're merging -- this 'begin' example
should generate a single probe body which is "triggered" twice at the
beginning of execution.  If that creates only one output, then you're
breaking semantics.

Consider a similar kprobe case:

probe kernel.function("sys_read"), kernel.function("sys_read")
{
	log("here")
}

How many times will this log for each sys_read?  The correct answer
should be two...

Josh


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]