Time Libraries Rough Draft

Simon Marlow simonmar at microsoft.com
Thu Feb 10 06:23:31 EST 2005

On 10 February 2005 11:14, Ketil Malde wrote:

>>   * getting the current "CPU time"
> Isn't this very system dependent?  And isn't times(2) a better choice
> than clock(3)?  How do these behave in the presence of leap seconds?
> I.e. if I clock() a computation, do I get the same result as
> the difference of gettimeofday()s before and after times CPU
> utilization, or do I get the correct times, and the consequential a
> leap-second offset compared to gettimeofday?
> I'm not able to find any information on this; I assume these functions
> deal in (non-linear) POSIX time, since you want them in the same
> module?
> (I would put everyting to do with performance meausrements in a
> different module.  Although, I guess if we only target POSIX systems,
> this is all right.  The consensus seems to be to wed time to POSIX.)

There is already System.CPUTime, BTW.  Ashley: are you proposing to
replace this?


More information about the Libraries mailing list