This is the mail archive of the
systemtap@sourceware.org
mailing list for the systemtap project.
RE: Pointer chain paranoia
- From: "Stone, Joshua I" <joshua dot i dot stone at intel dot com>
- To: "Mike Mason" <mmlnx at us dot ibm dot com>
- Cc: <systemtap at sources dot redhat dot com>
- Date: Tue, 14 Nov 2006 13:21:21 -0800
- Subject: RE: Pointer chain paranoia
On Tuesday, November 14, 2006 1:12 PM, Mike Mason wrote:
> Are pointer chain references in the regular stap language (not
> embedded C) always safe? In other words, if I use something of the
> form $ptr1->ptr2->ptr3->var, does stap automatically convert that to
> the needed deref() macros? I looked at the resulting module code and
> I think it does, but want to be sure.
Yes, dereferencing in the script language is guaranteed safe. If you
find a case where it's not protecting the access, that's a bug.
We really should hold tapsets to the same standard -- unprotected
dereferencing should be treated as a bug. (Some will be dependent on
bug #3079 though...)
Josh