mratsim / constantine

Constantine: modular, high-performance, zero-dependency cryptography stack for proof systems and blockchain protocols.
Other
272 stars 38 forks source link

C API for EVM precompiles #382

Closed Vindaar closed 1 month ago

Vindaar commented 1 month ago

This is based on and continues from #381. It now also adds a C API for the EVM precompiles module.

One example is added that generally checks the API works and it includes a test case from:

https://github.com/mratsim/constantine/blob/master/tests/protocol_ethereum_evm_precompiles/eip-2537/map_fp2_to_G2_bls.json

which passes as expected.

Vindaar commented 1 month ago

Rebased the code onto current master. Should hopefully be fine to merge now.