LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (http://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   user time, system time, real time .. reg (http://www.linuxquestions.org/questions/linux-newbie-8/user-time-system-time-real-time-reg-873635/)

chaitanyajun12 04-07-2011 01:54 PM

user time, system time, real time .. reg
 
1. how sum of system time and user time can be greater than real time ?
2. Even though my program is not waiting for any I/O the real time is smaller than system time as shown


root@chaitu:/home/chaitu/Desktop/Chk# time ./new

real 0m0.001s
user 0m0.000s
sys 0m0.004s

Awaiting a reply.

szboardstretcher 04-07-2011 02:08 PM

I think thats because the computer is faster than real time - 'Wall Clock Time'

For example.

Real time might be 1 minute.

But the computer can do 600 minutes of work in 1 minute. Its been a long time since I've studied this, so please correct me if I am mistaken.

chaitanyajun12 04-07-2011 02:20 PM

thanks for ur reply..
the things which I know regarding this are:

real time is the actual elapsed time(from beginning to end of the program)
user time includes time needed for executing user defined code.
System time for executing system calls(kernel time).

but I am confused as to how system time can be greater than real time. even i am not clear with it.

just waiting for someone to answer.

Chaitanya.

MTK358 04-07-2011 08:30 PM

Quote:

Originally Posted by szboardstretcher (Post 4317293)
But the computer can do 600 minutes of work in 1 minute. Its been a long time since I've studied this, so please correct me if I am mistaken.

I don't understand. What's a "minute of work", anyway? How can a computer do in 1/600 of a minute what it could do in a minute?

chaitanyajun12 04-08-2011 12:18 AM

This thing would be of great help for me.
Someone can please explain it.


--
Chaitanya


All times are GMT -5. The time now is 03:42 AM.