Gautam Gopalakrishnan wrote:
>> I'm afraid your question is not good enough to give good enough answer
> 
> Doh!
> 
>> Are you talking about userland or kernel?
> 
> I am talking about a userland application which does database queries.
> To simplify, let's say main() calls A(). Sometimes A takes too long to
> return, so I want to know what parameters were passed (maybe the query
> is too broad or inefficient). If I run a DTrace script at this point,
> the pid$1::A:entry fbt provider will not be triggered and
> pid$1::A:return will be too late (because the problem does not exist
> anymore). If A() is a small function, then I could put a probe on every
> instruction but in this case it is complex and calls many other functions.

there is a standard technique of "set a flag when you enter a function,
reset it when you leave; then, while the flag is set, trace *every* function"
that can help at answering questions like this.  It's got to be example 3 in
nearly every DTrace presentation.
_______________________________________________
dtrace-discuss mailing list
[email protected]

Reply via email to