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

py: Wrap call with fb_alloc. #115

Closed

Conversation

kwagyeman
Copy link
Member

@kwagyeman kwagyeman commented Oct 17, 2023

This wraps fb_alloc around all functions/methods being called... so, it's not necessary to protect context anywhere else.

That said, it probably doesn't make sense to do this. fb_alloc_mark does a bunch of stuff and would slow down function calls. It's sensible probably just to keep wrapping image processing functions manually.

Anyway, just made the PR to show the code. Probably should close it.

@iabdalkader
Copy link
Member

fb_alloc_mark does a bunch of stuff and would slow down function calls. It's sensible probably just to keep wrapping image processing functions manually.

You're right maybe we can optimize those functions to lower the overhead ?

Note this PR will not be merged either way, if we do add this feature it's not going to be added like this, I started by asking if we can add hooks, if we can, then I will push it upstream, cherry-pick it back here, and those hooks will be set in Makefiles.

@kwagyeman
Copy link
Member Author

Cool

@kwagyeman kwagyeman closed this Oct 18, 2023
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