Listing probe alias resolution failures
patm@pdx.edu
patm@pdx.edu
Wed May 16 16:58:00 GMT 2007
Quoting David Smith <dsmith@redhat.com>:
> patm@pdx.edu wrote:
>> I was thinking the java program is pretty obscure, so here is a
>> much simpler way to determine some of the probe aliases that are
>> failing, in this case lets look at syscalls.stp:
>>
>> $ grep syscall.*= /usr/share/systemtap/tapset/syscalls.stp | \
>> awk '{ print $1 " " $2 "{}" }' | \
>> stap -p2 -u -
>>
>> And either a list of failed probe alias resolutions will be printed
>> to stderr, or a list of probe aliases, variables, and functions
>> will be printed out to stdout.
>>
>
> On my FC6.93 system, here are the errors the above outputs:
>
> semantic error: no match for probe point while resolving probe point
> syscall.compat_getitimer
> semantic error: no match for probe point while resolving probe point
> syscall.compat_getitimer.return
> semantic error: no match for probe point while resolving probe point
> syscall.get_mempolicy
> semantic error: no match for probe point while resolving probe point
> syscall.get_mempolicy.return
> semantic error: no match for probe point while resolving probe point
> syscall.mbind
> semantic error: no match for probe point while resolving probe point
> syscall.mbind.return
> semantic error: no match for probe point while resolving probe point
> syscall.mmap
> semantic error: no match for probe point while resolving probe point
> syscall.mmap.return
>
> Let's look at the first one for a sec. The system call
> "compat_getitimer" doesn't exist on my x86 FC6.93 system. It does
> exist on a x86_64 RHEL4 system I have access to.
>
> So, how does this hurt me? The below 2 stap commands still work:
>
> # stap -p2 -u -e 'probe syscall.* {}'
> # stap -p2 -u -e 'probe syscall.*getitimer {}'
>
> The only thing that doesn't work is:
>
> # stap -p2 -u -e 'probe syscall.compat_getitimer {}'
>
> So, the only error I get is when I explicitly list the system call that
> doesn't exist on my current arch and kernel. I could see where if you
> were writing a script targeting either multiple architectures or
> multiple kernel versions that might bother you. However, the solution
> is easy - make that probe optional:
>
> # stap -p2 -u -e 'probe syscall.compat_getitimer ? { }'
Very nice, I had no idea that you could do this to a probe alias. But,
and I don't know if this is intended or not, it still fails on certain
errors:
$ stap -p2 -u -e 'probe vm.mmap ? { }'
semantic error: failed to retrieve location attribute for local 'addr'
(dieoffset: 0xb84881): identifier '$addr' at
/usr/local/share/systemtap/tapset/memory.stp:118:15
semantic error: failed to retrieve location attribute for local 'addr'
(dieoffset: 0x78276d): identifier '$addr' at
/usr/local/share/systemtap/tapset/memory.stp:118:15
semantic error: failed to retrieve location attribute for local 'addr'
(dieoffset: 0x780d54): identifier '$addr' at
/usr/local/share/systemtap/tapset/memory.stp:118:15
semantic error: failed to retrieve location attribute for local 'addr'
(dieoffset: 0x780bc4): identifier '$addr' at
/usr/local/share/systemtap/tapset/memory.stp:118:15
semantic error: failed to retrieve location attribute for local 'addr'
(dieoffset: 0x6b504d): identifier '$addr' at
/usr/local/share/systemtap/tapset/memory.stp:118:15
semantic error: failed to retrieve location attribute for local 'len'
(dieoffset: 0xb8487c): identifier '$len' at
/usr/local/share/systemtap/tapset/memory.stp:119:14
semantic error: failed to retrieve location attribute for local 'len'
(dieoffset: 0x782768): identifier '$len' at
/usr/local/share/systemtap/tapset/memory.stp:119:14
semantic error: not accessible at this address: identifier '$len' at
/usr/local/share/systemtap/tapset/memory.stp:119:14
semantic error: failed to retrieve location attribute for local 'len'
(dieoffset: 0x780bbf): identifier '$len' at
/usr/local/share/systemtap/tapset/memory.stp:119:14
semantic error: probe_1527 with unresolved type for identifier
'address' at /usr/local/share/systemtap/tapset/memory.stp:118:5
semantic error: probe_1528 with unresolved type for identifier
'address' at /usr/local/share/systemtap/tapset/memory.stp:118:5
semantic error: probe_1528 with unresolved type for identifier
'length' at /usr/local/share/systemtap/tapset/memory.stp:119:5
semantic error: probe_1529 with unresolved type for identifier
'address' at /usr/local/share/systemtap/tapset/memory.stp:118:5
semantic error: probe_1529 with unresolved type for identifier
'length' at /usr/local/share/systemtap/tapset/memory.stp:119:5
semantic error: probe_1530 with unresolved type for identifier
'address' at /usr/local/share/systemtap/tapset/memory.stp:118:5
semantic error: probe_1530 with unresolved type for identifier
'length' at /usr/local/share/systemtap/tapset/memory.stp:119:5
semantic error: probe_1531 with unresolved type for identifier
'address' at /usr/local/share/systemtap/tapset/memory.stp:118:5
semantic error: probe_1531 with unresolved type for identifier
'length' at /usr/local/share/systemtap/tapset/memory.stp:119:5
Pass 2: analysis failed. Try again with more '-v' (verbose) options.
More information about the Systemtap
mailing list