This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author vstinner
Recipients benjamin.peterson, jerome.hamm, vstinner
Date 2020-04-04.19:35:49
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1586028949.65.0.056795132209.issue40174@roundup.psfhosted.org>
In-reply-to
Content
Python has a long history (30 years). time.time() had multiple implementations. When I added time.monotonic() in Python 3.3, it was optional. I changed that in Python 3.5: time.monotonic() is now always available.
https://docs.python.org/dev/library/time.html#time.monotonic

time.monotonic() has multiple implementations:

* Windows: GetTickCount64()
* macOS (Darwin): mach_absolute_time()
* HP-UX: gethrtime()
* Solaris: clock_gettime(CLOCK_HIGHRES)
* Otherwise: clock_gettime(CLOCK_MONOTONIC)

So far (since Python 3.5), no one complained about build error on any platform. It looks safe in practice to expect clock_gettime() to be available.

I suggest to close this issue, and only change the code is Python fails to build on a specific platform.

By the way, glibc 2.31 release notes: "We plan to remove the obsolete function ftime, and the header <sys/timeb.h>, in a future version of glibc."
History
Date User Action Args
2020-04-04 19:35:49vstinnersetrecipients: + vstinner, benjamin.peterson, jerome.hamm
2020-04-04 19:35:49vstinnersetmessageid: <1586028949.65.0.056795132209.issue40174@roundup.psfhosted.org>
2020-04-04 19:35:49vstinnerlinkissue40174 messages
2020-04-04 19:35:49vstinnercreate