Go4Expert

Go4Expert (http://www.go4expert.com/)
-   C (http://www.go4expert.com/forums/c/)
-   -   how to find the compilation time at C???? (http://www.go4expert.com/forums/compilation-time-c-t20611/)

vignesh1988i 6Jan2010 20:46

how to find the compilation time at C????
 
how to find out the time complexity or compilation time in a C program?????? help me out :):thinking:

karthigayan 19Feb2010 17:10

Re: how to find the compilation time at C????
 
If you need compilation time of the C program you can use the time command in linux environment .

time cc testing.c

But inside a program we can only get the run time by some of the time calculations.We can not get the compilation time.

vignesh1988i 19Feb2010 18:08

Re: how to find the compilation time at C????
 
oh... ok .ok :) i just need the time in milli or microseconds..... . whether ur command willl dispaly in this format?????? :)

karthigayan 20Feb2010 08:52

Re: how to find the compilation time at C????
 
time will give its output in seconds and micro seconds . It will give three kind of times real,user,system.Here the real time the execution time.user and system time depends on the kernal.

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

The code which I execute took lesser than 0 second.Which means in a few milli seconds .


All times are GMT +5.5. The time now is 04:39.