[issue41299] Python3 threading.Event().wait time is twice as large as Python27

Ryan Hileman report at bugs.python.org
Sun Jun 6 19:58:51 EDT 2021


Ryan Hileman <lunixbochs at gmail.com> added the comment:

Ok, I filed a PR for this. I used pytime's interface to avoid duplicating the QueryPerformanceFrequency() code.

I found a StackOverflow answer that says QueryPerformance functions will only fail if you pass in an unaligned pointer: https://stackoverflow.com/a/27258700

Per that, I used Py_FatalError to catch this case, as there is probably something wrong with the compiler at that point, and the other recovery options would be likely to result in incorrect program behavior (e.g. dead lock).

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue41299>
_______________________________________


More information about the Python-bugs-list mailing list