Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Update generated Prover FRI GPU setup-data keys from branch afo/faster-compressor #3479

Open
wants to merge 6 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build-proof-fri-gpu-compressor-gar.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
- name: Download FFLONK key and setup data
run: |
gsutil -m rsync -r gs://matterlabs-setup-data-us/${{ inputs.setup_keys_id }} docker/proof-fri-gpu-compressor-gar
gsutil -m cp -r gs://matterlabs-setup-keys-us/setup-keys/setup_fflonk_compact.key docker/proof-fri-gpu-compressor-gar
gsutil -m cp -r gs://matterlabs-setup-keys-us/setup-keys/setup_compact.key docker/proof-fri-gpu-compressor-gar

- name: Login to us-central1 GAR
run: |
Expand Down
67 changes: 30 additions & 37 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 8 additions & 7 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -228,18 +228,19 @@ tokio-stream = "0.1.16"
# We *always* pin the latest version of protocol to disallow accidental changes in the execution logic.
# However, for the historical version of protocol crates, we have lax requirements. Otherwise,
# Bumping a crypto dependency like `boojum` would require us to republish all the historical packages.
circuit_encodings = "=0.150.19"
circuit_sequencer_api = "=0.150.19"
circuit_definitions = "=0.150.19"
crypto_codegen = { package = "zksync_solidity_vk_codegen",version = "=0.30.12" }
kzg = { package = "zksync_kzg", version = "=0.150.19" }
circuit_encodings = {path = "../../zksync-protocol/crates/circuit_encodings"}
circuit_sequencer_api = {path = "../../zksync-protocol/crates/circuit_sequencer_api"}
circuit_definitions = {path = "../../zksync-protocol/crates/circuit_definitions"}
crypto_codegen = { package = "zksync_solidity_vk_codegen",path = "../../zksync-crypto/crates/codegen" }
kzg = { package = "zksync_kzg", path = "../../zksync-protocol/crates/kzg" }
zk_evm = { version = "=0.133.0" }
zk_evm_1_3_1 = { package = "zk_evm", version = "0.131.0-rc.2" }
zk_evm_1_3_3 = { package = "zk_evm", version = "0.133" }
zk_evm_1_4_0 = { package = "zk_evm", version = "0.140" }
zk_evm_1_4_1 = { package = "zk_evm", version = "0.141" }
zk_evm_1_5_0 = { package = "zk_evm", version = "=0.150.19" }
fflonk = "=0.30.12"
zk_evm_1_5_0 = { package = "zk_evm", path = "../../zksync-protocol/crates/zk_evm" }
fflonk = {path = "../../zksync-crypto/crates/fflonk"}
bellman = {package = "zksync_bellman", path = "../../zksync-crypto/crates/bellman"}

# New VM; pinned to a specific commit because of instability
zksync_vm2 = { git = "https://github.com/matter-labs/vm2.git", rev = "457d8a7eea9093af9440662e33e598c13ba41633" }
Expand Down
1 change: 1 addition & 0 deletions core/lib/prover_interface/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ zksync_types.workspace = true
# We can use the newest api to send proofs to L1.
circuit_definitions.workspace = true
fflonk.workspace = true
bellman.workspace = true
circuit_sequencer_api.workspace = true

serde.workspace = true
Expand Down
8 changes: 5 additions & 3 deletions core/lib/prover_interface/src/outputs.rs
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
use core::fmt;

use bellman::plonk::better_better_cs::proof::Proof as PlonkProof;
use circuit_definitions::{
boojum::pairing::bn256::Bn256,
circuit_definitions::aux_layer::ZkSyncSnarkWrapperCircuitNoLookupCustomGate,
circuit_definitions::aux_layer::{
ZkSyncSnarkWrapperCircuit, ZkSyncSnarkWrapperCircuitNoLookupCustomGate,
},
};
use circuit_sequencer_api::proof::FinalProof;
use fflonk::FflonkProof;
use serde::{Deserialize, Serialize};
use serde_with::{hex::Hex, serde_as};
Expand Down Expand Up @@ -45,7 +47,7 @@ pub struct FflonkL1BatchProofForL1 {
#[derive(Clone, Serialize, Deserialize)]
pub struct PlonkL1BatchProofForL1 {
pub aggregation_result_coords: [[u8; 32]; 4],
pub scheduler_proof: FinalProof,
pub scheduler_proof: PlonkProof<Bn256, ZkSyncSnarkWrapperCircuit>,
pub protocol_version: ProtocolSemanticVersion,
}

Expand Down
7 changes: 2 additions & 5 deletions docker/proof-fri-gpu-compressor-gar/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,15 @@ FROM nvidia/cuda:12.4.0-runtime-ubuntu22.04 as app

# HACK copying to root is the only way to make Docker layer caching work for these files for some reason
COPY *.bin /
COPY ./setup_fflonk_compact.key /setup_fflonk_compact.key
COPY ./setup_compact.key /setup_compact.key

RUN apt-get update && apt-get install -y curl libpq5 ca-certificates && rm -rf /var/lib/apt/lists/*


# copy finalization hints required for assembly generation
COPY --from=proof_fri_gpu /setup_2\^24.key /setup_2\^24.key
COPY --from=proof_fri_gpu /prover/data/keys/ /prover/data/keys/
COPY --from=proof_fri_gpu /usr/bin/zksync_proof_fri_compressor /usr/bin/

ENV CRS_FILE=/setup_2\^24.key
ENV COMPACT_CRS_FILE=/setup_fflonk_compact.key
ENV COMPACT_CRS_FILE=/setup_compact.key


ENTRYPOINT ["zksync_proof_fri_compressor"]
4 changes: 2 additions & 2 deletions etc/env/base/contracts.toml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ BLOB_VERSIONED_HASH_RETRIEVER_ADDR = "0x0000000000000000000000000000000000000000

GENESIS_ROOT = "0x09e68951458b18c24ae5f4100160b53c4888c9b3c3c1859cc674bc02236675ad"
GENESIS_BATCH_COMMITMENT = "0x7238eab6a0e9f5bb84421feae6b6b9ae80816d490c875d29ff3ded375a3e078f"
GENESIS_ROLLUP_LEAF_INDEX = "64"
GENESIS_ROLLUP_LEAF_INDEX = "64"

# Ecosystem-wide params
L1_ROLLUP_DA_VALIDATOR = "0x0000000000000000000000000000000000000000"
Expand Down Expand Up @@ -67,7 +67,7 @@ L1_NATIVE_TOKEN_VAULT_IMPL_ADDR ="0xFC073319977e314F251EAE6ae6bE76B0B3BAeeCF"
L1_NATIVE_TOKEN_VAULT_PROXY_ADDR ="0xFC073319977e314F251EAE6ae6bE76B0B3BAeeCF"
L2_NATIVE_TOKEN_VAULT_IMPL_ADDR = "0x0000000000000000000000000000000000010004"
L2_NATIVE_TOKEN_VAULT_PROXY_ADDR = "0x0000000000000000000000000000000000010004"
L2_SHARED_BRIDGE_IMPL_ADDR = "0x0000000000000000000000000000000000010003"
L2_SHARED_BRIDGE_IMPL_ADDR = "0x0000000000000000000000000000000000010003"
L2_SHARED_BRIDGE_ADDR = "0x0000000000000000000000000000000000010003"
L2_ERC20_BRIDGE_ADDR = "0x0000000000000000000000000000000000010003"
CTM_DEPLOYMENT_TRACKER_IMPL_ADDR ="0xFC073319977e314F251EAE6ae6bE76B0B3BAeeCF"
Expand Down
4 changes: 2 additions & 2 deletions etc/env/base/fri_proof_compressor.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ prometheus_pushgateway_url = "http://127.0.0.1:9091"
prometheus_push_interval_ms = 100
generation_timeout_in_secs = 3600
max_attempts = 5
universal_setup_path = "../keys/setup/setup_2^24.key"
universal_setup_download_url = "https://storage.googleapis.com/matterlabs-setup-keys-us/setup-keys/setup_2^24.key"
universal_setup_path = "../keys/setup/setup_compact.key"
universal_setup_download_url = "https://storage.googleapis.com/matterlabs-setup-keys-us/setup-keys/setup_compact.key"
verify_wrapper_proof = true
universal_fflonk_setup_path = "../keys/setup/setup_fflonk_compact.key"
universal_fflonk_setup_download_url = "https://storage.googleapis.com/matterlabs-setup-keys-us/setup-keys/setup_fflonk_compact.key"
4 changes: 2 additions & 2 deletions etc/env/file_based/general.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -182,8 +182,8 @@ proof_compressor:
prometheus_push_interval_ms: 100
generation_timeout_in_secs: 3600
max_attempts: 5
universal_setup_path: keys/setup/setup_2^24.key
universal_setup_download_url: https://storage.googleapis.com/matterlabs-setup-keys-us/setup-keys/setup_2^24.key
universal_setup_path: keys/setup/setup_compact.key
universal_setup_download_url: https://storage.googleapis.com/matterlabs-setup-keys-us/setup-keys/setup_compact.key
verify_wrapper_proof: true
universal_fflonk_setup_path: keys/setup/setup_fflonk_compact.key
universal_fflonk_setup_download_url: https://storage.googleapis.com/matterlabs-setup-keys-us/setup-keys/setup_fflonk_compact.key
Expand Down
Loading
Loading