FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

bpo-37205: time.perf_counter() and time.monotonic() are system-wide by vstinner · Pull Request #23284 · python/cpython · GitHub

/ cpython Public

bpo-37205: time.perf_counter() and time.monotonic() are system-wide - #23284

Merged
vstinner merged 1 commit into
python:masterfrom
vstinner:clock_system_wide
Nov 16, 2020
Merged

vstinner merged 1 commit into
python:masterfrom
vstinner:clock_system_wide

Conversation

vstinner commented Nov 14, 2020
edited by bedevere-bot
Loading

Copy link
Copy Markdown
Member

time.perf_counter() on Windows and time.monotonic() on macOS are now
system-wide. Previously, they used an offset computed at startup to
reduce the precision loss caused by the float type. Use
time.perf_counter_ns() and time.monotonic_ns() added in Python 3.7 to
avoid this precision loss.

https://bugs.python.org/issue37205

time.perf_counter() on Windows and time.monotonic() on macOS are now
system-wide. Previously, they used an offset computed at startup to
reduce the precision loss caused by the float type. Use
time.perf_counter_ns() and time.monotonic_ns() added in Python 3.7 to
avoid this precision loss.
vstinner merged commit 3df5c68 into python:master Nov 16, 2020
vstinner deleted the clock_system_wide branch November 16, 2020 12:21
adorilson pushed a commit to adorilson/cpython that referenced this pull request Mar 13, 2021
…ythonGH-23284)

time.perf_counter() on Windows and time.monotonic() on macOS are now
system-wide. Previously, they used an offset computed at startup to
reduce the precision loss caused by the float type. Use
time.perf_counter_ns() and time.monotonic_ns() added in Python 3.7 to
avoid this precision loss.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants


Back | FazBrowse Home | New Git URL