Re: question on timing results

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




--- Matthew Miller <mattdm@xxxxxxxxxx> wrote:

> On Wed, Jun 08, 2005 at 06:40:34AM -0700, Globe Trotter wrote:
> > utilization. Unless I misunderstood the documentation, clock() provides
> > the processor time and so the difference between clock() at the beginning
> > of the call to an algorithm and the end would provide me with the CPU time
> > elapsed. However, if for some reason the processor was running at 75% or
> > whatever, my reported time would be affected, and hence there would not
> > really be a fair comparison. Does anyone have any ideas/suggestions as to
> > how I may settle this issue?
> 
> clock() returns an approximation of the CPU time used by the actual process,
> so while load from other programs is a factor (particularly since it'll make
> your program wait for IO, etc.) it should do basically what you want.
> 

Oh, really! This really does help: thanks! 

Best wishes!


		
__________________________________ 
Discover Yahoo! 
Use Yahoo! to plan a weekend, have fun online and more. Check it out! 
http://discover.yahoo.com/


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux