summaryrefslogtreecommitdiffstats
path: root/Include/cpython
diff options
context:
space:
mode:
authorEric Snow <ericsnowcurrently@gmail.com>2023-10-02 20:12:12 (GMT)
committerGitHub <noreply@github.com>2023-10-02 20:12:12 (GMT)
commit1dd9dee45d2591b4e701039d1673282380696849 (patch)
tree14199e2d03ef74ca575d64552676d4797d792d9c /Include/cpython
parenta040a32ea2f13f16172394d3e3e3f80f47f25a68 (diff)
downloadcpython-1dd9dee45d2591b4e701039d1673282380696849.zip
cpython-1dd9dee45d2591b4e701039d1673282380696849.tar.gz
cpython-1dd9dee45d2591b4e701039d1673282380696849.tar.bz2
gh-105716: Support Background Threads in Subinterpreters Consistently (gh-109921)
The existence of background threads running on a subinterpreter was preventing interpreters from getting properly destroyed, as well as impacting the ability to run the interpreter again. It also affected how we wait for non-daemon threads to finish. We add PyInterpreterState.threads.main, with some internal C-API functions.
Diffstat (limited to 'Include/cpython')
-rw-r--r--Include/cpython/pystate.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/Include/cpython/pystate.h b/Include/cpython/pystate.h
index 5e184d0..7e4c57e 100644
--- a/Include/cpython/pystate.h
+++ b/Include/cpython/pystate.h
@@ -211,6 +211,7 @@ struct _ts {
* if it is NULL. */
PyAPI_FUNC(PyThreadState *) _PyThreadState_UncheckedGet(void);
+
// Disable tracing and profiling.
PyAPI_FUNC(void) PyThreadState_EnterTracing(PyThreadState *tstate);