-
Notifications
You must be signed in to change notification settings - Fork 589
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
Benchmark against other EVMs #7
Comments
This will be very useful, thank you lightclient! On my laptop, I am getting around 210-220ms, didn't expect to be that big. Will need to spin perf to see if I can see something. |
It is a little bit faster now, I am getting around ~110-120ms. The memory and stack that I got from sputnik were not optimized, and signed operations could probably be done better. |
and now it is more in the range of ~85-95ms |
~75-80ms now, on my laptop. |
This is where the story becomes interesting. and evmone is really great. I added few more optimization: static gas are precalculated in gas_block and applied when needed and added some other small tweaks but still div is big performance hit. It seems that there is a big difference if I am running windows or linux. windows is usually faster by ~8-10ms, I am still unsure what part of code is responsible for that. All measurements above are done in windows. For measurement bellow, they only differ by switching div and sdiv opcodes. here For Parity u256 div I am getting around ~68-72ms on win and ~77-80ms on linux and graph looks like: while with zkp_u256 I got a boost and was getting around ~58-61ms on windows and on linux ~67-68ms zkp u256 that uses Parity_u256 should probably just switch to u128 and will probably gain some better performance. evmone uses an optimized version that seems even faster than embedded running on: Intel(R) Core(TM) i7-10750H CPU @ 2.60GHz flamegraphs as svg if somebody wants to look in detail: I feel like there is a lot of small improvements that can be done to optimize things, but we will see how big of an impact they will have. |
switching parity u256 same output was got with just using parity u256 |
~56-58ms on windows with improved parity u256. test is found in |
My test was called only once per execution, and I would execute it multiple times to get range of timing. I changed that and introduced loop, so now the execution test is called 50times. So after a few iterations, i am getting a better time than windows
And I am getting close to evmone:
|
after binding
And flamegraph with that change looks like this (zipped svg file: flamegraph.zip): I will not merge I feel like this is okay to close, revm got very close to evmone and timings looks good. There is probably some optimization that can be done on Host part, evmone uses MockedHost for testing while revm has only standard host impl and mock Database ( you can see from flamegraph sload takes a lot of time), but i will leave this for later. It was fun ride. |
Is there any clear documentation comparing the performance of REVM with other EVMs, especially parity EVM which is also based on Rust? |
If you found one, please forward it to me. |
Thanks, more info: |
* fix error count of sload opcode * format code --------- Co-authored-by: anonymousGiga <cryptonymGong@gmail.com>
* many fix and more assert * fix default
It would be cool to benchmark against other EVM implementations, especially
evmone
which AFAIK is currently the fastest EVM interpreter.This would probably be a good benchmark for arithmetic: ethereum/evmone#320
The text was updated successfully, but these errors were encountered: