This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
Re: Question about line number probing
"Nathan A. Debardeleben" <ndebard@lanl.gov> writes:
> [...] But can I do something with 'arg2' in a SystemTap script? Can
> I do something like:
>
> probe("foo.c:1234") {
> printf("arg2 = %d\n", arg2);
> }
This is what statement probes are for. The gods of compiler optimizations
willing, try
probe kernel.statement("*@foo.c:1234") {
printf("arg2 = %d\n", $arg2);
}
- FChE