A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2009-October/093162.html below:

[Python-Dev] time.clock() on windows

[Python-Dev] time.clock() on windows [Python-Dev] time.clock() on windowsAntoine Pitrou solipsis at pitrou.net
Thu Oct 22 11:09:34 CEST 2009
Robert Collins <robertc <at> robertcollins.net> writes:
> 
> Could you offset it by the system time on the first call?

Two problems:
- the two measurements are not done simultaneously, so the result *still* does
not guarantee you have the same time reference in all processes (but gives you
the illusion you do, which is perhaps worse)
- adding a precise measure to an imprecise measure doesn't make the result
precise, but imprecise (or, rather, precise but inexact); in other words, if the
system time only gives a 0.01 second resolution, adding a high-resolution timer
only gives you an illusion of accuracy

Therefore it seems a very bad solution. The only way, AFAICT, to do this right
is for Windows to provide a high-resolution system time. It sounds astonishing
that this doesn't exist.

Regards

Antoine.


More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4