This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: clock and timing.



This has nothing to do with gcc. On many systems clock()'s resolution
is only 1/100 of a second. This means that clock() is incremented
every  10,000/CLOCKS_PER_SEC  seconds.



"Tom Davids" <opentest@angelfire.com>@gcc.gnu.org on 22-10-2001 06:14:31

> I've just coded up this small program

> [ deleted a program that uses clock() ]
>
> The CLOCKS_PER_SEC is 1000000,
> When I run the program I get the either
> total = 10000
> total = 20000
> or
> total = 0.




Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]