Open
Description
Component
Other (please describe)
Describe the feature you would like
Every time we make a call using Executor
we create a new Evm
. This creates the context, handlers, and instruction table, which then also have to be cleaned up after the call is done.
This is relatively inexpensive in a normal test/fuzz test which consumes hundreds of thousands of gas. However, for very short calls which consume very little gas, like in invariants, the time spent in Evm initialization and destruction is often most of the time spent in that entire call (>50%).
We can avoid this by caching the evm / instruction table / handlers. There are currently a few complications, including missing Clone
, Send
and Sync
for some of these types.
Additional context
No response