-
-
Notifications
You must be signed in to change notification settings - Fork 31.9k
#127648 introduced a ~12% performance regression in python_startup_no_site
benchmark
#132952
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
Comments
cc @srittau. I suppose this is because |
Yes, that's the gist of it. I'm surprised by the size of the regression -- I think that's a testament to how close to the lower limit Python startup already is. |
It looks like we need |
That's a huge difference in startup time.
This sounds worthwhile to me, independent from this regression. Importing a Python-only module will most likely always incur a fairly large performance penalty. We could also implement the pseudo-protocols in C if that helps with performance. Finally, we could go back to the original plan to move the protocols to |
@mdboom For my understanding: This is only for the |
I think this regresssion is primarily from adding the |
If we want to speed this up further, I think this is the most promising parts are these:
For This is not really part of this issue since it's not a regression, but leaving this here in case there's interest in speeding up startup further. |
Bug report
Bug description:
Plotting the Faster CPython team's weekly benchmarks, there is an obvious discontinuity in the python_startup_no_site benchmark:
This is between these two commits:
2025-03-03 0.98 b3c18bf
2025-03-08 0.85 a3990df
Bisecting over this range, it's reproducible that the first bad commit is c6dd2348ca.
CPython versions tested on:
CPython main branch
Operating systems tested on:
Linux
Linked PRs
The text was updated successfully, but these errors were encountered: