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 serhiy.storchaka
Recipients berker.peksag, erlendaasland, serhiy.storchaka
Date 2021-02-21.10:03:35
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1613901815.83.0.983153067745.issue43267@roundup.psfhosted.org>
In-reply-to
Content
PyLong_Check is two memory reads, bits operation, and comparison with 0. And one non-inlined function call when limited API is used. PyLong_CheckExact is only one memory read and comparison.

I am not sure that the difference is significant enough to justify the optimization. I would require evidences that this optimization is significant if it would be proposed now. But the code is already written in such form, and I am not sure that it is worth to spend our time to change it.
History
Date User Action Args
2021-02-21 10:03:35serhiy.storchakasetrecipients: + serhiy.storchaka, berker.peksag, erlendaasland
2021-02-21 10:03:35serhiy.storchakasetmessageid: <1613901815.83.0.983153067745.issue43267@roundup.psfhosted.org>
2021-02-21 10:03:35serhiy.storchakalinkissue43267 messages
2021-02-21 10:03:35serhiy.storchakacreate