Skip to content

Commit

Permalink
fix: lists precompiles (#317)
Browse files Browse the repository at this point in the history
# Description

Fixes #316

Mentions supported precompiled contracts

## Linked Issues

#316 

## Additional context
  • Loading branch information
uF4No authored Feb 3, 2025
1 parent fc8a63b commit 001bfcb
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions content/20.zksync-protocol/70.differences/40.pre-compiles.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,17 @@ title: Precompiles
description:
---

Some EVM cryptographic precompiles (notably pairings and RSA) aren't currently available. However, pairing is
prioritized to allow deployment of both ZK chains and protocols like Aztec/Dark Forest without modifications.

Ethereum cryptographic primitives like `ecrecover`, `keccak256`, `sha256`, `ecadd` and `ecmul` are supported as precompiles.
Some EVM cryptographic precompiles (notably RSA / `modExp`) aren't currently available.
However other cryptographic primitives like `ecrecover`, `keccak256`, `sha256`, `ecadd` and `ecmul` are supported as precompiles.
No actions are required from your side as all the calls to the precompiles are done by the compilers under the hood.

It's important to be aware that the gas costs and behaviors of these precompiles when invoked via delegatecall may differ from those on Ethereum.

## Available precompiles

| Address | Name | Description |
|---------|------|-------------|
| `0x06` | ecAdd | Point addition (ADD) on the elliptic curve 'alt_bn128' |
| `0x07` | ecMul | Scalar multiplication (MUL) on the elliptic curve 'alt_bn128' |
| `0x08` | ecParing | Bilinear function on groups on the elliptic curve 'alt_bn128' |
| `0x100` | p256Verify | Performs signature verifications in the secp256r1 elliptic curve ([RIP7212](https://github.com/ethereum/RIPs/blob/master/RIPS/rip-7212.md)) |

0 comments on commit 001bfcb

Please sign in to comment.