| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
…3912) his involves moving tp_dict, tp_bases, and tp_mro to PyInterpreterState, in the same way we did for tp_subclasses. Those three fields are effectively const for builtin static types (unlike tp_subclasses). In theory we only need to make their values immortal, along with their contents. However, that isn't such a simple proposition. (See gh-103823.) In the meantime the simplest solution is to move the fields into the interpreter. One alternative is to statically allocate the values, but that's its own can of worms.
|
This PR is stale because it has been open for 30 days with no activity. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
We do two things here: immortalize the builtin structseq types, and immortalize tp_dict, tp_bases, and tp_mro for builtin types. This is necessary for a per-interpreter GIL.
Note that we could also take the approach to immortalization that no immortal object should ever be freed, even if allocated dynamically. That's something we'll sort out as soon as we can. In the meantime, the change here takes care of isolation concerns.