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 the "CFrame" struct as it is no longer needed for performance. #108035

Closed
markshannon opened this issue Aug 16, 2023 · 1 comment
Closed
Labels
performance Performance or resource usage

Comments

@markshannon
Copy link
Member

markshannon commented Aug 16, 2023

In 3.11 we added a "CFrame" struct that sits on the C stack. This struct held a pointer to the current frame, and a "use_tracing" field.
Since we needed to check this field on every bytecode dispatch, it was very hot and needed to be on the C stack for performance.

With PEP 669, that field is gone and there is no need for the "CFrame" any more. We should remove it and revert to the keeping a pointer to the current frame in the thread state.

Linked PRs

@carljm
Copy link
Member

carljm commented Aug 17, 2023

This looks done?

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

No branches or pull requests

2 participants