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

GH-128682: Account for escapes in DECREF_INPUTS #129953

Merged

Conversation

markshannon
Copy link
Member

@markshannon markshannon commented Feb 10, 2025

This is the final PR (apart from potential bug fixes) for #128682.
It:

  • Handles DECREF_INPUTS by either:
    • setting the on-stack references to NULL before closing them, or
    • where more efficient, setting the stack pointer before each reference is closed
  • Changes many uses of DECREF_INPUTS to PyStackRef_CLOSE where there was only one input.
  • Adds asserts that the stack pointer is spilled at key points outside of the interpreter.

@iritkatriel
Copy link
Member

Some tests are failing.

@markshannon markshannon added the 🔨 test-with-refleak-buildbots Test PR w/ refleak buildbots; report in status section label Feb 12, 2025
@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by @markshannon for commit 76001f7 🤖

Results will be shown at:

https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F30617%2Fmerge

If you want to schedule another build, you need to add the 🔨 test-with-refleak-buildbots label again.

@bedevere-bot bedevere-bot removed the 🔨 test-with-refleak-buildbots Test PR w/ refleak buildbots; report in status section label Feb 12, 2025
@markshannon
Copy link
Member Author

Latest benchmarking results show a 0.2% slowdown

@markshannon markshannon merged commit 72f5665 into python:main Feb 12, 2025
70 checks passed
@markshannon markshannon deleted the account-for-escapes-in-decref-inputs branch February 27, 2025 11:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants