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

Improve implementation of HPy_(Type | Is | GetItem_i) in CPython ABI mode. #471

Merged
merged 3 commits into from
Jan 30, 2024

Conversation

fangerer
Copy link
Contributor

Some time ago, I've mentioned that the call overhead in the implementation of HPy_Type was crucial (in CPython ABI mode) for the NumPy/HPy demo. The same applies to HPy_Is. Therefore, I'm essentially inlining the implementation into the appropriate API functions.
I also did a little improvement in HPy_GetItem_i to avoid unnecessary allocation of long objects.

Copy link
Contributor

@hodgestar hodgestar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me.

@fangerer fangerer merged commit ef1eef1 into master Jan 30, 2024
38 checks passed
@fangerer fangerer deleted the fa/cpy_impl_improvements branch January 30, 2024 07:26
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

Successfully merging this pull request may close these issues.

2 participants