broker5 at seznam.cz
2008-Aug-06 16:39 UTC
[dtrace-discuss] pid provider gives wrong output
Hi, Having such dtrace scipt: #pragma D option flowindent pid$target:::entry, pid$target:::return { } and such c program: void main() { int data[100]; memmove(&data[5],&data[6],50); printf("end\n"); } Everytime I call memmove I get strange "return from function" record from memcpy call -this record does not have its "entering function" part so I get something like this (also note strange indentation): 1 -> memmove 1 <- memmove 1 <- memcpy Is this a bug or am I missing something ? Thanks J.
Searching for ''memmove memcpy dtrace'' turned up Chad''s excellent blog post on the subject: http://cmynhier.blogspot.com/2007/04/memmove-memcpy-and-dtrace.html That should answer your question. Adam On Wed, Aug 06, 2008 at 06:39:45PM +0200, broker5 at seznam.cz wrote:> Hi, > > Having such dtrace scipt: > > #pragma D option flowindent > > pid$target:::entry, > pid$target:::return > { > } > > and such c program: > > void main() > { > int data[100]; > memmove(&data[5],&data[6],50); > printf("end\n"); > } > > Everytime I call memmove I get strange "return from function" record from memcpy call -this record does not have its "entering function" part so I get something like this (also note strange indentation): > > 1 -> memmove > 1 <- memmove > 1 <- memcpy > > > Is this a bug or am I missing something ? > > Thanks J. > _______________________________________________ > dtrace-discuss mailing list > dtrace-discuss at opensolaris.org-- Adam Leventhal, Fishworks http://blogs.sun.com/ahl
broker5 at seznam.cz
2008-Aug-06 17:30 UTC
[dtrace-discuss] pid provider gives wrong output
Yes, it does :-) Many thanks> Searching for ''memmove memcpy dtrace'' turned up Chad''s excellent blog post > on the subject: > > http://cmynhier.blogspot.com/2007/04/memmove-memcpy-and-dtrace.html > > That should answer your question. > > Adam > > On Wed, Aug 06, 2008 at 06:39:45PM +0200, broker5 at seznam.cz wrote: > > Hi, > > > > Having such dtrace scipt: > > > > #pragma D option flowindent > > > > pid$target:::entry, > > pid$target:::return > > { > > } > > > > and such c program: > > > > void main() > > { > > int data[100]; > > memmove(&data[5],&data[6],50); > > printf("end\n"); > > } > > > > Everytime I call memmove I get strange "return from function" record from > memcpy call -this record does not have its "entering function" part so I get > something like this (also note strange indentation): > > > > 1 -> memmove > > 1 <- memmove > > 1 <- memcpy > > > > > > Is this a bug or am I missing something ? > > > > Thanks J. > > _______________________________________________ > > dtrace-discuss mailing list > > dtrace-discuss at opensolaris.org > > -- > Adam Leventhal, Fishworks http://blogs.sun.com/ahl > > >
broker5 at seznam.cz
2008-Aug-07 13:50 UTC
[dtrace-discuss] pid provider gives wrong output
Hi Adam, when talking about wrong pid provider output do you think you could take a look at my old thread here: http://mail.opensolaris.org/pipermail/dtrace-discuss/2008-April/006027.html I know Bryan answered but I still think there is problem or bug. Note that if I remove flowindent option and use my own printing (like printf("<- %s\n",probefunc)) everything is working fine, so I think there is some bug in flowindent. Also I asked friend to verify it on his box to see where the problem is local for my box and he is experiencing same problems. Thanks Jcob> ------------ P?vodn? zpr?va ------------ > Od: Adam Leventhal <ahl at eng.sun.com> > P?edm?t: Re: [dtrace-discuss] pid provider gives wrong output > Datum: 06.8.2008 19:26:22 > ---------------------------------------- > Searching for ''memmove memcpy dtrace'' turned up Chad''s excellent blog post > on the subject: > > http://cmynhier.blogspot.com/2007/04/memmove-memcpy-and-dtrace.html > > That should answer your question. > > Adam > > On Wed, Aug 06, 2008 at 06:39:45PM +0200, broker5 at seznam.cz wrote: > > Hi, > > > > Having such dtrace scipt: > > > > #pragma D option flowindent > > > > pid$target:::entry, > > pid$target:::return > > { > > } > > > > and such c program: > > > > void main() > > { > > int data[100]; > > memmove(&data[5],&data[6],50); > > printf("end\n"); > > } > > > > Everytime I call memmove I get strange "return from function" record from > memcpy call -this record does not have its "entering function" part so I get > something like this (also note strange indentation): > > > > 1 -> memmove > > 1 <- memmove > > 1 <- memcpy > > > > > > Is this a bug or am I missing something ? > > > > Thanks J. > > _______________________________________________ > > dtrace-discuss mailing list > > dtrace-discuss at opensolaris.org > > -- > Adam Leventhal, Fishworks http://blogs.sun.com/ahl > > >