Oleg Iarygin <o...@arhadthedev.net> added the comment:
Actually, you're right. For now, PyErr_Occurred is a GIL lock plus a memory access. While the access is cheap because of a L1 cache hit, the GIL takes its toll in a hot path. So I'm closing the PR until GIL removal is done so no performance penalty will be imposed. I could use _PyErr_Occurred because "Currently Argument Clinic is considered internal-only for CPython", but it requires extra modifications of the clinic that is undesirable. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue47128> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com