Cannon Performance Notes - ethereum-optimism/optimistic-specs GitHub Wiki
on the Cannon wiki
This page now livesThese are some notes taken from conversations with geohot about where Cannon's time is spent.
- Go runtime initialize: about 11M instructions. These could be folded into
golden.json
to exclude them from the trace (i.e. take the initial memory snapshot after initialization of the Go runtime) - Cannon uses about 5-10M of instructions to process a transaction.
- 40% of Cannon's time is spent doing Keccak.
- Hence we could reduce the size of the trace by almost 40% by replacing Keccak calls by a custom MIPS opcode.
- 20% is spent in ECDSA calculations
Execution speed figures:
- the unicorn configuration runs at 10MHz (i.e. 10M instructions per second) (~1 sec per tx)
- the evm configuration runs at around 100KHz (~2 min per tx)
- the chain configuration runs at around 1KHz (~3 hrs per tx)
Check the Cannon Overview for information on the mipsevm configurations.