Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

[WIP] bpo-33608: Factor out a private, per-interpreter _Py_AddPendingCall().#9334

Closed
ericsnowcurrently wants to merge 18 commits into
python:masterpython/cpython:masterfrom
ericsnowcurrently:pending-calls-freshericsnowcurrently/cpython:pending-calls-freshCopy head branch name to clipboard
Closed

[WIP] bpo-33608: Factor out a private, per-interpreter _Py_AddPendingCall().#9334
ericsnowcurrently wants to merge 18 commits into
python:masterpython/cpython:masterfrom
ericsnowcurrently:pending-calls-freshericsnowcurrently/cpython:pending-calls-freshCopy head branch name to clipboard

Conversation

@ericsnowcurrently

@ericsnowcurrently ericsnowcurrently commented Sep 15, 2018

Copy link
Copy Markdown
Member

This is part of the work to improve isolation between subinterpreters. We need a way for one interpreter to ask another interpreter to do small low-level tasks, like safely decref an object owned by the other interpreter. The existing Py_AddPendingCall() (part of the public C-API) is specific to the main interpreter, so we factor out a private per-interpreter _Py_AddPendingCall(). This involves moving the global "pending calls" state to PyInterpreterState.

As part of this change, we start tracking if each interpreter is "active" or finalizing. "Active" means that the interpreter is currently running the eval loop. We also start tracking the per-interpreter "active" thread ID rather than the global "main" thread ID.

https://bugs.python.org/issue33608

@ericsnowcurrently ericsnowcurrently changed the title bpo-33608: Factor out a private, per-interpreter _Py_AddPendingCall(). [WIP] bpo-33608: Factor out a private, per-interpreter _Py_AddPendingCall(). Sep 15, 2018
@ericsnowcurrently

Copy link
Copy Markdown
Member Author

Superceded by gh-11617

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.