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

Cache Keccak Hashes per SignedTx #2544

Merged
merged 9 commits into from
Oct 9, 2023
Merged

Cache Keccak Hashes per SignedTx #2544

merged 9 commits into from
Oct 9, 2023

Conversation

prasannavl
Copy link
Member

Summary

  • Cache tx hash computation, as the pipeline computes hash multiple times and Keccak hashes make for the most expensive computation in the current pipeline.

Implications

  • Storage

    • Database reindex required
    • Database reindex optional
    • Database reindex not required
    • None
  • Consensus

    • Network upgrade required
    • Includes backward compatible changes
    • Includes consensus workarounds
    • Includes consensus refactors
    • None

@prasannavl prasannavl changed the title Pvl/cache tx hash Cache Keccak Hashes per SignedTx Oct 9, 2023
Copy link
Collaborator

@Jouzo Jouzo left a comment

Choose a reason for hiding this comment

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

Missed the pipeline where we never use the hash(). Reverted the lazy changes

lib/ain-evm/src/transaction/mod.rs Show resolved Hide resolved
lib/ain-evm/src/transaction/mod.rs Show resolved Hide resolved
lib/ain-evm/src/transaction/mod.rs Show resolved Hide resolved
@prasannavl prasannavl merged commit cbdaa1e into master Oct 9, 2023
11 of 13 checks passed
@prasannavl prasannavl deleted the pvl/cache-tx-hash branch October 9, 2023 11:29
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.

3 participants