Skip to content
This repository was archived by the owner on Jul 5, 2024. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
7f8ba17
WIP
ed255 Jun 30, 2022
3723f01
Join EVM + TxCircuit
ed255 Jul 1, 2022
44a39ba
WIP clean
ed255 Jul 1, 2022
61ecc59
WIP add bytecode circuit
ed255 Jul 1, 2022
4616faf
Fix tx_circuit compat with EVM
ed255 Jul 4, 2022
23fc158
Add bytecode circuit to super circuit
ed255 Jul 4, 2022
396c466
WIP
ed255 Jul 11, 2022
7743784
Fix bytecode assignment
ed255 Jul 12, 2022
ba5befa
Harmonize tables
ed255 Jul 12, 2022
1dfa99c
Reuse keccak table between TxCircuit and BytecodeCircuit
ed255 Jul 12, 2022
21b81f5
WIP
ed255 Jul 14, 2022
a4be2b6
WIP
ed255 Jul 15, 2022
e738148
WIP
ed255 Jul 15, 2022
e25931c
Do some clean ups
ed255 Jul 15, 2022
f73ac93
WIP
ed255 Jul 18, 2022
0c295cd
Move cross-circuit table stuff to src/table.rs
ed255 Jul 18, 2022
3197b22
cargo fmt
ed255 Jul 18, 2022
194c266
Document pub stuff
ed255 Jul 18, 2022
d20088a
Merge branch 'main' into feature/super-circuit
ed255 Jul 18, 2022
d6ff781
Fix merge
ed255 Jul 18, 2022
06a9ea5
Pass clippy
ed255 Jul 19, 2022
a9beebb
WIP
ed255 Jul 19, 2022
38f7e7c
Abstract CopyTable from CopyCircuit
ed255 Jul 19, 2022
a04464f
Mark super circuit test as serial
ed255 Jul 20, 2022
2ebff8b
Merge branch 'main' into feature/super-circuit
ed255 Jul 20, 2022
a23dfa1
Introduce Super Circuit and adapt existing circuits for it
ed255 Jul 20, 2022
fbab7e4
Merge branch 'main' into feature/super-circuit
ed255 Jul 21, 2022
6d881aa
Reset our halo2 fork
ed255 Jul 21, 2022
d8a0d12
Merge branch 'main' into feature/super-circuit
ed255 Jul 22, 2022
7955480
Address comments from @han0110 and @lispc
ed255 Jul 27, 2022
73aa42a
Merge branch 'main' into feature/super-circuit
ed255 Jul 27, 2022
68350c4
Merge branch 'main' into feature/super-circuit
ed255 Jul 28, 2022
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
4 changes: 2 additions & 2 deletions bus-mapping/src/circuit_input_builder/execution.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ use eth_types::{
GethExecStep, H256,
};
use gadgets::impl_expr;
use halo2_proofs::{arithmetic::FieldExt, plonk::Expression};
use halo2_proofs::plonk::Expression;
use strum_macros::EnumIter;

/// An execution step of the EVM.
Expand Down Expand Up @@ -201,7 +201,7 @@ pub enum NumberOrHash {

/// Defines a copy event associated with EVM opcodes such as CALLDATACOPY,
/// CODECOPY, CREATE, etc. More information:
/// https://github.com/privacy-scaling-explorations/zkevm-specs/blob/master/specs/copy-proof.md.
/// <https://github.com/privacy-scaling-explorations/zkevm-specs/blob/master/specs/copy-proof.md>.
#[derive(Clone, Debug)]
pub struct CopyEvent {
/// Represents the start address at the source of the copy event.
Expand Down
9 changes: 5 additions & 4 deletions circuit-benchmarks/src/evm_circuit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ use halo2_proofs::{
plonk::{Circuit, ConstraintSystem, Error, Expression},
};
use zkevm_circuits::evm_circuit::{witness::Block, EvmCircuit};
use zkevm_circuits::table::{BlockTable, BytecodeTable, RwTable, TxTable};

#[derive(Debug, Default)]
pub struct TestCircuit<F> {
Expand All @@ -21,10 +22,10 @@ impl<F: Field> Circuit<F> for TestCircuit<F> {
}

fn configure(meta: &mut ConstraintSystem<F>) -> Self::Config {
let tx_table = [(); 4].map(|_| meta.advice_column());
let rw_table = [(); 11].map(|_| meta.advice_column());
let bytecode_table = [(); 5].map(|_| meta.advice_column());
let block_table = [(); 3].map(|_| meta.advice_column());
let tx_table = TxTable::construct(meta);
let rw_table = RwTable::construct(meta);
let bytecode_table = BytecodeTable::construct(meta);
let block_table = BlockTable::construct(meta);
let copy_table = [(); 11].map(|_| meta.advice_column());
// Use constant expression to mock constant instance column for a more
// reasonable benchmark.
Expand Down
4 changes: 2 additions & 2 deletions gadgets/src/util.rs
Original file line number Diff line number Diff line change
Expand Up @@ -126,15 +126,15 @@ pub trait Expr<F: FieldExt> {
#[macro_export]
macro_rules! impl_expr {
($type:ty) => {
impl<F: FieldExt> $crate::util::Expr<F> for $type {
impl<F: halo2_proofs::arithmetic::FieldExt> $crate::util::Expr<F> for $type {
#[inline]
fn expr(&self) -> Expression<F> {
Expression::Constant(F::from(*self as u64))
}
}
};
($type:ty, $method:path) => {
impl<F: FieldExt> $crate::util::Expr<F> for $type {
impl<F: halo2_proofs::arithmetic::FieldExt> $crate::util::Expr<F> for $type {
#[inline]
fn expr(&self) -> Expression<F> {
Expression::Constant(F::from($method(self) as u64))
Expand Down
Loading