On Tue, 16 Oct 2007, micke wrote:

> Hi, thanks, the DTRACE_SCHED(sleep) is exactly where I want to capture the 
> time. Haven't had the time to read throw the dtrace book yet, but is it 
> possible to extract this value? in kernel-space? also in user-space?

In userspace, the simplest way to see these events would be:

        dtrace -n "sched:::sleep {}"

To hook this into a program of your own, libdtrace could be used, with a 
small consumer the style of truss or lockstat, see sources of these 
programs.

I don't know if there is a way to create DTrace "kernel consumers". If you 
need synchronous notification/action, then the DTrace consumer mechanism 
isn't appropriate anyway, as DTrace will buffer the events for you and 
deliver 'when asked' (i.e. when the consumer reads the dtrace device).

FrankH.





>
>
> This message posted from opensolaris.org
> _______________________________________________
> opensolaris-code mailing list
> [email protected]
> http://mail.opensolaris.org/mailman/listinfo/opensolaris-code
>
_______________________________________________
opensolaris-code mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/opensolaris-code

Reply via email to