Skip to content

Commit

Permalink
Remove the additional columns required by quadri.
Browse files Browse the repository at this point in the history
The variable N_COL only defines the number of columns used by the current layout, without quadri.
  • Loading branch information
dannywillems committed Jun 24, 2024
1 parent 6382aef commit 8800bbb
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions ivc/src/ivc/columns.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use super::{N_ADDITIONAL_WIT_COL_QUAD, N_LIMBS_XLARGE};
use super::N_LIMBS_XLARGE;
use crate::poseidon_8_56_5_3_2::{
bn254::{
Column as IVCPoseidonColumn, NB_FULL_ROUND as IVC_POSEIDON_NB_FULL_ROUND,
Expand Down Expand Up @@ -331,15 +331,16 @@ pub enum IVCColumn {

impl ColumnIndexer for IVCColumn {
/// Number of columns used by the IVC circuit
/// It contains at least the columns used for Poseidon, and the columns used
/// to reduce to degree 2 the constraints of the circuit
/// It contains at least the columns used for Poseidon.
/// It does not include the additional columns that might be required
/// to reduce to degree 2.
/// FIXME: This can be improved by changing a bit the layer.
/// The reduction to degree 2 should happen in the gadgets to avoid adding
/// extra columns and leave sparse rows.
// We consider IVCPoseidonColumn::N_COL but it should be the maximum of
// the different gadgets/blocks.
// We also add 1 for the FoldIteration column.
const N_COL: usize = IVCPoseidonColumn::N_COL + N_ADDITIONAL_WIT_COL_QUAD + 1;
const N_COL: usize = IVCPoseidonColumn::N_COL + 1;

fn to_column(self) -> Column {
match self {
Expand Down

0 comments on commit 8800bbb

Please sign in to comment.