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

Update revm #2

Merged
merged 3 commits into from
Aug 30, 2022
Merged

Update revm #2

merged 3 commits into from
Aug 30, 2022

Conversation

rakita
Copy link
Contributor

@rakita rakita commented Aug 29, 2022

Sorry for the intrusion but this is a interesting benchmark that you have made, it primarily tests and compares initialization part of sputnik and revm.

I didn't spend a lot of time on looking at that part in the start, mostly did optimization on the execution (interpreter) loop, but after tinkering some things on revm/forks (bluealloy/revm#191) branch and adding one more optimization in revm/precomp (bluealloy/revm@d851763) I am getting a lot better times:

execute_contract_method_success_from_rust_evm (1.0s) ...       9_363.419 ns/iter (0.986 R²)
execute_contract_method_reverted_from_rust_evm (1.0s) ...       7_522.533 ns/iter (1.000 R²)
execute_contract_method_success_from_revm (1.0s) ...       2_408.113 ns/iter (1.000 R²)
execute_contract_method_reverted_from_revm (1.0s) ...       2_156.431 ns/iter (1.000 R²)

It would be interesting to see how does it compare on executing heavy contracts, I would expect around x2 speedup but i didn't do the testing :) this is good candidate https://github.com/karalabe/snailtracer

@rakita
Copy link
Contributor Author

rakita commented Aug 29, 2022

Oh, on snailtracer it is like x5 speedup:

execute_contract_method_success_from_rust_evm (1.8s) ... 261_880_154.000 ns/iter (0.984 R²)
execute_contract_method_success_from_revm (1.1s) ...  49_709_496.686 ns/iter (1.000 R²)

branch: https://github.com/rakita/rust-evm-bench/tree/snailtracer

@cassc
Copy link
Owner

cassc commented Aug 30, 2022

Thanks @rakita! The performance improvement is very impressive!

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