This repository was archived by the owner on Feb 13, 2025. It is now read-only.
forked from python/cpython
-
Notifications
You must be signed in to change notification settings - Fork 61
Consolidate stateful C globals under a single struct (bpo-30860) #152
Labels
Milestone
Comments
akruis
pushed a commit
that referenced
this issue
Oct 14, 2018
Preparations: - use meaningful variable names - remove dead code - move the stackless addition to PyThreadState to the end of the struct - remove redundant declarations from stackless_structs.h
akruis
pushed a commit
that referenced
this issue
Oct 14, 2018
Add legitimate globals to ignored-globals.txt. All other Stackless globals should be moved to runtime or interpreter state.
akruis
pushed a commit
that referenced
this issue
Oct 14, 2018
It was only used during module initialization.
akruis
pushed a commit
that referenced
this issue
Oct 14, 2018
…nd interpreter state Add struct _stackless_runtime_state to _PyRuntimeState and PyStacklessInterpreterState to PyInterpreterState. For now both structs are empty. I'll move Stackless globals into them.
akruis
pushed a commit
that referenced
this issue
Oct 14, 2018
Add sub-struct transfer to _PyRuntime.st.
akruis
pushed a commit
that referenced
this issue
Oct 14, 2018
…erpreterState The variable holds a complex callable object, which must not be shared between different interpreters.
I just merged pull request #153, but the task is not yet completed.
|
akruis
pushed a commit
that referenced
this issue
Oct 17, 2018
Removed globals: - slp_initial_tstate - channel_hook - slp_error_handler - _slp_schedule_fasthook - _slp_schedule_hook - slp_cstack_chain - mem_bomb Additionally I optimized the ordering of the fields of PyStacklessState and PyStacklessInterpreterState to avoid padding.
akruis
pushed a commit
that referenced
this issue
Oct 17, 2018
Move slp_enable_softswitch to PyStacklessInterpreterState. Move slp_try_stackless, cstack_cache and cstack_cachecount to struct _stackless_runtime_state.
Finally I consolidated all stateful C globals of Stackless into runtime- or interpreter state. Moved to
Moved to struct
As a consequence I had to change internal API: the |
akruis
pushed a commit
that referenced
this issue
Nov 11, 2018
The commit used a C11 feature. Unfortunately only clang emits a warning.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
bpo-30860 consolidates global variables unter the _PyRuntime struct. We should do the same for Stackless globals. See https://bugs.python.org/issue30860 for details.
The text was updated successfully, but these errors were encountered: