Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Help latest MSVC 1932 (v143, VS2022) to optimize PyObject_Free() #94841

Closed
neonene opened this issue Jul 14, 2022 · 1 comment
Closed

Help latest MSVC 1932 (v143, VS2022) to optimize PyObject_Free() #94841

neonene opened this issue Jul 14, 2022 · 1 comment
Labels
performance Performance or resource usage type-bug An unexpected behavior, bug, or error

Comments

@neonene
Copy link
Contributor

neonene commented Jul 14, 2022

There is a report that python.org 3.11 Windows release has slowed down on micro benchmarks:

faster-cpython/ideas#420

One reason is that PyObject_Free() is not well optimized by the latest MSVC (ver.1932 in v143 tool set), which is likely to be used for the next 3.10 official as well.

This issue has been reported to the MSVC team. However, their tools would not be fixed urgently.

Linked PRs

@gvanrossum
Copy link
Member

Thank you so much for this one-line fix giving 20% perf improvement (in some cases)!

nascheme pushed a commit to nascheme/cpython that referenced this issue Jul 14, 2022
…Free() (pythonGH-94842)

Co-authored-by: Neil Schemenauer <[email protected]>
(cherry picked from commit d0850aa170580b494beda030a94fb04254e4acbc)

Co-authored-by: neonene <[email protected]>
nascheme added a commit that referenced this issue Jul 15, 2022
…GH-94842)

Need to define ALWAYS_INLINE macro for 3.10.

Co-authored-by: neonene <[email protected]>
brandtbucher added a commit to brandtbucher/cpython that referenced this issue May 12, 2023
brandtbucher added a commit to brandtbucher/cpython that referenced this issue May 12, 2023
(cherry picked from commit a10b026)

Co-authored-by: Brandt Bucher <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
performance Performance or resource usage type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

No branches or pull requests

3 participants