-
-
Notifications
You must be signed in to change notification settings - Fork 33.2k
Closed as not planned
Labels
interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)type-featureA feature request or enhancementA feature request or enhancement
Description
Feature or enhancement
Proposal:
As @brandtbucher mentioned elsewhere, _PyCode_ConstantKey
is getting to be quite large, subtle and error-prone. The unique key that PyMarshal_WriteToString
creates would serve the same purpose and would replace the logic with something core and well-tested.
In addition to correctness, it should also be tested for any performance impact. It's possible it's moot since _PyCode_ConstantKey
already allocates a bunch of objects, but we should confirm.
intern_constants
also does mostly the same thing in a free-threaded build and maybe could take a similar approach to also remove a bunch of code that is hard to keep in-sync with everything else.
Has this already been discussed elsewhere?
No response given
Links to previous discussion of this feature:
No response
tomasr8
Metadata
Metadata
Assignees
Labels
interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)type-featureA feature request or enhancementA feature request or enhancement