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

perf: Removed .clone() in ExecutionHandler::call, and reusing output buffer… #1512

Merged
merged 1 commit into from
Jun 11, 2024

Conversation

impactdni2
Copy link
Contributor

Reduces allocations in a two places.

  1. In ExecutionHandler::call(), drops a .clone() on the inputs (allocated cloned Bytes)
  2. In Interpreter::insert_call_outcome, re-uses the passed in call_outcome.result.output rather than cloning the Bytes into a the new location

All the tests pass as far as I can tell, but I'm getting a bit lower in the stack than I'm super comfortable in, so would love an extra set of eyes to tell me if I'm missing something.

Copy link
Member

@rakita rakita left a comment

Choose a reason for hiding this comment

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

lgtm

@rakita rakita merged commit 0768ec6 into bluealloy:main Jun 11, 2024
25 checks passed
This was referenced Jun 11, 2024
@github-actions github-actions bot mentioned this pull request Jun 19, 2024
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.

None yet

2 participants