Skip to content

Add mcl (and possibly constantine) backends for alt_bn128 precompiles #2713

Open
@arnetheduck

Description

@arnetheduck

One of the largest bottlenecks during syncing post eip-1108 are the bncurve precompiles - nim-bncurve can no longer keep up.

As an alternative, we could switch to mcl which is a classic battletested option that is fast. Getting to this point requires first creating an mcl wrapper similar to nim-secp256k1 and then adding a selection layer similar to how nim-ssz-serialization can switch between multiple sha256 instances.

Worth exploring is also constantine, though this should be added only once we have an mcl backend, so that we can run comparative analysis.

nim-bncurve should be kept as a pure-nim fallback option.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions