Darren Reed wrote:
What I'd like to be able to do is include functions such as
rw_enter in fbt scripting. The problem I'm faced with is
that functions such as these appear to not be present in
fbt, only rw_enter_sleep...

I glanced over at lockstat but rw-acquired is on the wrong
side of the lock for me.

What I'm trying to do is provoke a race condition and
the easiest way that I could think of would be to force
the thread to sleep as its about to enter the protected
section of code.

   I am not sure you could force a thread to sleep from the DTrace script.

   Did you consider using the chill() action ? [You could put a probe
either in the caller of the rw_enter function or in rw_enter_sleep and have it
   spin on the cpu for few milliseconds using chill()]
In my experiments i have found that the chill() action does widen the race windows.

Pramod

Is there any chance of there being RFE-able work here
to provide an fbt or other probe pre-lock on the "leading"
edge of functions such as rw_enter?

Darren

_______________________________________________
dtrace-discuss mailing list
[email protected]

_______________________________________________
dtrace-discuss mailing list
[email protected]

Reply via email to