chore: move cryptography code into crypto folder#2750
Closed
kevaundray wants to merge 20 commits intobluealloy:mainfrom
Closed
chore: move cryptography code into crypto folder#2750kevaundray wants to merge 20 commits intobluealloy:mainfrom
crypto folder#2750kevaundray wants to merge 20 commits intobluealloy:mainfrom
Conversation
crypto foldercrypto folder
CodSpeed Performance ReportMerging #2750 will not alter performanceComparing Summary
Benchmarks breakdown
|
kevaundray
commented
Jul 21, 2025
Contributor
Author
|
Pulled out of #2706 |
kevaundray
commented
Jul 21, 2025
| }); | ||
|
|
||
| // Benchmark just the compression function with different round counts | ||
| group.bench_function("blake2/compress_12_rounds", |b| { |
Contributor
Author
There was a problem hiding this comment.
I think it might make sense to benchmark precompiles and the underlying cryptography separately -- we do still benchmark 12 rounds via the run method so we don't lose much here
Member
There was a problem hiding this comment.
hm precompiles is a crypto with a gas calculation.
kevaundray
commented
Jul 21, 2025
| //! For more details check modules for each precompile. | ||
| use crate::PrecompileWithAddress; | ||
|
|
||
| cfg_if::cfg_if! { |
Contributor
Author
There was a problem hiding this comment.
precompile/evm specific code no longer has the cfg_if code -- these were mainly being used to switch between different cryptography libraries. This now lives inside of crypto folder
Contributor
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR moves all of the core cryptography into a folder called
crypto.2705 made the pure cryptography functions not reliant on revm/evm specific types or functionality, so this is mainly moving code around.