This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
Re: Using kernel global variables
- From: fche at redhat dot com (Frank Ch. Eigler)
- To: Mike Mason <mmlnx at us dot ibm dot com>
- Cc: David Wilder <dwilder at us dot ibm dot com>, SystemTAP <systemtap at sources dot redhat dot com>
- Date: 06 Aug 2007 13:49:17 -0400
- Subject: Re: Using kernel global variables
- References: <46B35E2C.6000907@us.ibm.com> <46B60DC8.3060702@us.ibm.com>
Mike Mason <mmlnx@us.ibm.com> writes:
> I believe the variable must be within the *scope* of the probed
> function. The function doesn't necessarily have to use the variable
> for it to be within scope. A global defined in the same file as the
> function is automatically within scope.
Or even *declared* in the same compilation unit - that should work too.
> I don't think exported symbols are within a function's scope from
> SystemTap's perspective [...]
We could change things to search for globals in other compilation
units too - exported ones first, static ones next (with the obvious
risk of name collisions).
- FChE