Skip to content

Stateful precompile support in Anvil #11210

@karlb

Description

@karlb

Component

Anvil

Describe the feature you would like

revm's EVM object makes it easy to add stateful precompile by passing a PrecompileProvider to EVM::new. But Anvil uses a PrecompilesMap, which does not support state access. This makes it non-trivial to add stateful precompiles to Anvil.

Additional context

According to the previous discussion in #7703 , @mattsse + @fgimenez have the most context on stateful precompiles.

I created a draft PR that shows how I added the stateful transfer precompile used by the Celo blockchain and the problems I ran into while doing that.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Status

    Backlog

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions