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 corona10, miss-islington, pablogsal, petr.viktorin, phsilva, rhettinger, serhiy.storchaka, shihai1991, vstinner
Date 2021-04-13.20:53:45
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1618347226.03.0.907724980369.issue40137@roundup.psfhosted.org>
In-reply-to
Content
I wrote PR 25393 to micro-optimize _PyType_GetModuleByDef(). It reduces the overhead from +5.7 ns to +3.4 ns (-2.3 ns).

Well, I didn't check in depth if _PyType_GetModuleByDef() is the only change in functools.lru_cache() from Python 3.9 to master.

Compare master to Python 3.9:

Mean +- std dev: [py39] 37.5 ns +- 1.0 ns -> [master] 43.2 ns +- 0.7 ns: 1.15x slower

Compare PR 25393 to Python 3.9:

Mean +- std dev: [py39] 37.5 ns +- 1.0 ns -> [inline] 40.9 ns +- 1.0 ns: 1.09x slower

Compare PR 25393 to master:

Mean +- std dev: [master] 43.2 ns +- 0.7 ns -> [inline] 40.9 ns +- 1.0 ns: 1.05x faster
History
Date User Action Args
2021-04-13 20:53:46vstinnersetrecipients: + vstinner, rhettinger, phsilva, petr.viktorin, serhiy.storchaka, corona10, pablogsal, miss-islington, shihai1991
2021-04-13 20:53:46vstinnersetmessageid: <1618347226.03.0.907724980369.issue40137@roundup.psfhosted.org>
2021-04-13 20:53:46vstinnerlinkissue40137 messages
2021-04-13 20:53:45vstinnercreate