Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Linux - Kernel This forum is for all discussion relating to the Linux kernel.


  Search this Thread
Old 10-07-2007, 01:09 PM   #1
LQ Newbie
Registered: Oct 2007
Posts: 1

Rep: Reputation: 0
how to measure execution time in kernel space?

i have registered a handler, in a kernel module, to deal with some incomming ethernet packages of a specific type .. is it possible to measure the execution of that handler in cpu clock ticks or any other microsecond precise clocking scheme?
Old 10-08-2007, 10:01 PM   #2
Registered: Oct 2005
Distribution: FC3,Debian
Posts: 127

Rep: Reputation: 15
Use clock defined in time.h as clock_t clock(void) to get clock time. To get time in seconds divide it by CLOCKS_PER_SEC.

If you want more details, such as user time,system time etc. Use times() defined in times.h


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
How To Measure Disk Space carlosinfl Linux - General 6 08-17-2007 02:30 PM
LXer: Measure Time in Linux with Time Base LXer Syndicated Linux News 0 04-11-2007 06:46 AM
Measure the accept queueing time! appforce Linux - Networking 0 01-26-2006 01:37 PM
accurately measure time rasselin Programming 1 09-05-2003 05:18 PM
how to accurately measure processing time rasselin Programming 3 09-01-2003 11:45 AM > Forums > Linux Forums > Linux - Software > Linux - Kernel

All times are GMT -5. The time now is 05:22 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration