X Tutup
The Wayback Machine - https://web.archive.org/web/20241008073244/https://github.com/python/cpython/issues/122160
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove BUILD_CONST_KEY_MAP opcode #122160

Closed
markshannon opened this issue Jul 23, 2024 · 0 comments
Closed

Remove BUILD_CONST_KEY_MAP opcode #122160

markshannon opened this issue Jul 23, 2024 · 0 comments

Comments

@markshannon
Copy link
Member

markshannon commented Jul 23, 2024

According to our stats the BUILD_CONST_KEY_MAP represents fewer than 1 in 20_000 instructions executed.

Presumably it is more common in startup code, but it has no real value there either.
For run once code, turning the keys into a constant merely moves the cost of building the keys from the interpreter to unmarshalling.

Linked PRs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant
X Tutup