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

Implement dummy IR padding for blocks with < 2 txns #15

Merged
merged 10 commits into from
Apr 8, 2024
Merged
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
1,664 changes: 961 additions & 703 deletions Cargo.lock

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ resolver = "2"
ethers = "2.0.7"
tokio = { version = "1", features = ["full"] }
anyhow = "1.0.71"
plonky2 = { git = "https://github.com/0xPolygonZero/plonky2", rev = "39a2d62d6d025631380da88aa78c2f8b929852a2" }
plonky2_evm = { git = "https://github.com/0xPolygonZero/plonky2", rev = "39a2d62d6d025631380da88aa78c2f8b929852a2" }
plonky2 = "0.2.1"
evm_arithmetization = { git = "https://github.com/0xPolygonZero/zk_evm.git", branch = "develop" }
clap = { version = "4.4.11", features = ["derive", "env"] }
protocol_decoder = { git = "https://github.com/0xPolygonZero/proof-protocol-decoder.git", rev = "6f97b3cd837d385c3501107bfdfbb3761e392b73" }
plonky_block_proof_gen = { git = "https://github.com/0xPolygonZero/proof-protocol-decoder.git", rev = "6f97b3cd837d385c3501107bfdfbb3761e392b73" }
trace_decoder = { git = "https://github.com/0xPolygonZero/zk_evm.git", branch = "develop" }
proof_gen = { git = "https://github.com/0xPolygonZero/zk_evm.git", branch = "develop" }
dotenvy = "0.15.7"
paladin-core = "0.4.1"
serde = { version = "1.0.193", features = ["derive"] }
Expand Down
4 changes: 2 additions & 2 deletions common/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ edition = "2021"

[dependencies]
tracing = { workspace = true }
plonky_block_proof_gen = { workspace = true }
proof_gen = { workspace = true }
plonky2 = { workspace = true }
plonky2_evm = { workspace = true }
evm_arithmetization = { workspace = true }
clap = { workspace = true }
thiserror = "1.0.50"
4 changes: 2 additions & 2 deletions common/src/prover_state/circuit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ use std::{
str::FromStr,
};

use plonky2_evm::{all_stark::AllStark, config::StarkConfig};
use plonky_block_proof_gen::types::AllRecursiveCircuits;
use evm_arithmetization::{all_stark::AllStark, StarkConfig};
use proof_gen::types::AllRecursiveCircuits;

use crate::parsing::{parse_range, RangeParseError};

Expand Down
2 changes: 1 addition & 1 deletion common/src/prover_state/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
use std::{fmt::Display, sync::OnceLock};

use clap::ValueEnum;
use plonky_block_proof_gen::prover_state::ProverState;
use proof_gen::prover_state::ProverState;
use tracing::info;

pub mod circuit;
Expand Down
2 changes: 1 addition & 1 deletion common/src/prover_state/persistence.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ use plonky2::{
plonk::config::PoseidonGoldilocksConfig,
util::serialization::{DefaultGateSerializer, DefaultGeneratorSerializer},
};
use plonky_block_proof_gen::types::AllRecursiveCircuits;
use proof_gen::types::AllRecursiveCircuits;
use tracing::{info, warn};

use super::circuit::CircuitConfig;
Expand Down
15 changes: 11 additions & 4 deletions leader/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,27 @@ edition = "2021"
[dependencies]
tokio = { workspace = true }
plonky2 = { workspace = true }
plonky2_evm = { workspace = true }
evm_arithmetization = { workspace = true }
clap = { workspace = true }
protocol_decoder = { workspace = true }
plonky_block_proof_gen = { workspace = true }
trace_decoder = { workspace = true }
proof_gen = { workspace = true }
anyhow = { workspace = true }
serde = { workspace = true }
serde_path_to_error = "0.1.14"
paladin-core = { workspace = true }
dotenvy = { workspace = true }
tracing = { workspace = true }
tracing-subscriber = { workspace = true }
ethers = { workspace = true }
futures = "0.3.30"
reqwest = { version = "0.12.2", default-features = false, features = [
"json",
"rustls-tls",
] }


itertools = "0.11.0"
eth_trie_utils = { git = "https://github.com/0xPolygonZero/eth_trie_utils.git", rev = "7fc3c3f54b3cec9c6fc5ffc5230910bd1cb77f76" }
mpt_trie = { git = "https://github.com/0xPolygonZero/zk_evm.git", branch = "develop" }
hex = "0.4.3"
serde_json = "1.0.108"

Expand Down
5 changes: 5 additions & 0 deletions leader/src/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,11 @@ pub enum Command {
/// The transaction hash from which to generate the witness.
#[arg(long, short)]
transaction_hash: TxHash,

/// If enabled, we will instead attempt to get the block miner from
/// clique.
#[arg(long, short)]
request_miner_from_clique: bool,
},
/// Generates a proof from the given witness and outputs it to stdout.
Prove {
Expand Down
6 changes: 3 additions & 3 deletions leader/src/init.rs
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
use tracing_subscriber::{fmt::format::FmtSpan, prelude::*, util::SubscriberInitExt, EnvFilter};
use tracing_subscriber::{prelude::*, util::SubscriberInitExt, EnvFilter};
pub(crate) fn tracing() {
tracing_subscriber::Registry::default()
.with(
tracing_subscriber::fmt::layer()
.pretty()
.with_span_events(FmtSpan::CLOSE)
.without_time()
.with_ansi(false)
.with_filter(EnvFilter::from_default_env()),
)
.init();
Expand Down
Loading