stephane eranian wrote:
> 2009/10/29 黃崇智 <[email protected]>:
>> 2009/10/29 stephane eranian <[email protected]>
>>> On Tue, Oct 27, 2009 at 3:48 AM, 黃崇智 <[email protected]> wrote:
>>>>> hi,
>>>>> I want to ask :
>>>>> Can I get the timestamps at the beginning of the programs in sampling
>>>>> mode?
>>> No, you can't. One thing to know is that the timestamp is using
>>> sched_clock()
>>> in the kernel. I am sure there is a syscall to get to the same timing
>>> source.
>>>
>>> hi, stephane
>>> can I use the syscall sched_clock() at user space ?
>>>
> No. Try using getimeofday() and convert everything to nanoseconds.

clock_gettime() might be a better choice, but you have to link with -lrt to get 
the function.

Regards,

- Corey

Corey Ashford
Software Engineer
IBM Linux Technology Center, Linux Toolchain
Beaverton, OR
503-578-3507
[email protected]


------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
perfmon2-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/perfmon2-devel

Reply via email to