This is the mail archive of the systemtap@sources.redhat.com 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: What is a tapset?


Hi -


On Fri, Jul 08, 2005 at 12:35:39PM -0700, Jim Keniston wrote:
> [...]
> The HPF procures whatever needed values can't be obtained directly by
> translator-emitted code.  For example, for a probed function such as
> sys_read(), the HPF might pass back the filename associated with the fd
> arg (i.e., $fd).  But the HPF relies on the translator to generate the
> appropriate code to procure and pass in the value of $fd.

There is an interesting (type) safety issue in passing target
variables (or indeed, a script-side variable) to a C function.  At
some point, the translator will want to treat them all as numbers or
strings.  One might imagine casting pointers to numbers, but of course
casting them back to pointers within the C code is dangerous.  That
code may have no practical way of verifying the validity of these
incoming "pointers" at all.


> [...]
> - I've never been comfortable with the requirement that you can specify
> a handler prologue only if you also specify an alias.  Seems like we
> could get past this by using a different keyword (e.g., "export" instead
> of "probe") when you're specifying a handler prologue instead of a
> handler.

I thought joining the two concepts made some sense.  If prologues were
a separately declared widget without a distinct name, then the user
would not have a marker in the script source that tells apart the case
where a prologue is being pulled in vs. one where one's not.


> One last thing... Frank and Vara seem to agree that a tapset does
> NOT include any predefined handlers (e.g., "canned" tracing code).
> Is there a general consensus on this?

Is there a design for "predefined handlers", i.e., rough syntax for
declaration and use, and an outline of its behavior?


- FChE


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