uprobes: keep thread blocked after the handler returns

Jim Keniston jkenisto@us.ibm.com
Thu Aug 2 23:07:00 GMT 2007


On Thu, 2007-08-02 at 14:19 -0700, Roland McGrath wrote:
> > Why not just prevent the handler from returning until you want the 
> > thread to unblock? The handler could sleep on something trigger from 
> > user space.
> 
> That is a no-no for a utrace callback.  It prevents other tracing
> facilities from doing anything useful.

Yeah, you're pretty adamant about that in Documentation/utrace.txt, but
I always wondered why.  Using gdb, I can stop a traced app and keep it
stopped all weekend.  If nobody else is using the app, why should
anybody care?

Sure, utrace allows multiple facilities to trace the same app, and we
may see circumstances where multiple users skew each others' results by
tracing the same app with blocking handlers.  That doesn't seem like a
very good reason for preventing utrace handlers from doing useful stuff
that can't be accomplished without blocking.

Jim



More information about the Systemtap mailing list