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

fix ints_to_bytes performance #1761

Merged
merged 4 commits into from
Aug 24, 2023
Merged

Conversation

mike-hunhoff
Copy link
Collaborator

Apparently int.to_bytes is horribly inefficient.

Before changes

        7   13.215    1.888   13.620    1.946 helpers.py:60(get_block_bytes)

After changes:

        7    0.000    0.000    0.044    0.006 helpers.py:58(get_block_bytes)

This PR also contains small API changes to the Ghidra helper functions.

@mike-hunhoff mike-hunhoff added enhancement New feature or request ghidra Related to Ghidra integration gsoc Work related to Google Summer of Code project. labels Aug 24, 2023
Copy link
Collaborator

@colton-gabertan colton-gabertan left a comment

Choose a reason for hiding this comment

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

Awesome refactoring & performance update. I'm sure that dramatically reduces runtime! Thanks @mike-hunhoff

@colton-gabertan colton-gabertan merged commit 448b122 into backend-ghidra Aug 24, 2023
17 checks passed
@colton-gabertan colton-gabertan deleted the fix/ints_to_bytes branch August 24, 2023 23:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request ghidra Related to Ghidra integration gsoc Work related to Google Summer of Code project.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants