| delorie.com/archives/browse.cgi | search |
| X-Authentication-Warning: | delorie.com: mail set sender to djgpp-bounces using -f |
| From: | "Alex Vinokur" <alexvn AT foot DOT com> |
| Newsgroups: | comp.os.msdos.djgpp |
| Subject: | Re: Microsoft clock() |
| Date: | Thu, 8 Jul 2004 18:06:47 +0300 |
| Lines: | 29 |
| Message-ID: | <2l568cF8mbjfU1@uni-berlin.de> |
| References: | <2l4majF8iuhdU1 AT uni-berlin DOT de> <127e01c464de$b95ca3b0$0600000a AT broadpark DOT no> |
| X-Trace: | news.uni-berlin.de Gd2OcHlx4JzlVQ5x5KfGagLbrC0YU3yIwCxEOoUtXkf2jKiMc= |
| X-Priority: | 3 |
| X-MSMail-Priority: | Normal |
| X-Newsreader: | Microsoft Outlook Express 6.00.2800.1409 |
| X-MimeOLE: | Produced By Microsoft MimeOLE V6.00.2800.1409 |
| To: | djgpp AT delorie DOT com |
| DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
| Reply-To: | djgpp AT delorie DOT com |
"Gisle Vanem" <giva AT bgnett DOT no> wrote in message news:127e01c464de$b95ca3b0$0600000a AT broadpark DOT no...
[snip]
>
> No surprise here either since MSVCRT defines clock() behaviour
> different from CygWin (or Posix). MSDN says:
>
> .. The amount of time that has elapsed since the start of the
> calling process is not necessarily equal to the actual amount of
> processor time that that process has used.
>
> I.e. clock() gives you the wall-clock.
[snip]
It seems that there is no difference between
diff_time and double(diff_clock)/CLOCKS_PER_SEC, where
* diff_time = end_time - start_time,
* diff_clock = end_clock - start_clock.
So, why do we need clock() on Microsoft? Only because of resolution?
--
Alex Vinokur
http://mathforum.org/library/view/10978.html
http://sourceforge.net/users/alexvn
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |