diff --git a/kimchi/src/prover.rs b/kimchi/src/prover.rs index adf55f2a36c..b99eb4b836c 100644 --- a/kimchi/src/prover.rs +++ b/kimchi/src/prover.rs @@ -1358,18 +1358,40 @@ where )); //~~ * add the combined table polynomial - let table_blinding = if lcs.runtime_selector.is_some() { - let runtime_comm = lookup_context.runtime_table_comm.as_ref().unwrap(); + let table_blinding = { let joint_combiner = lookup_context.joint_combiner.as_ref().unwrap(); - let blinding = runtime_comm.blinders.unshifted[0]; - - PolyComm { - unshifted: vec![*joint_combiner * blinding], - shifted: None, + let mut t = G::ScalarField::zero(); + let mut acc = G::ScalarField::one(); + let table_width = index + .cs + .lookup_constraint_system + .as_ref() + .unwrap() + .configuration + .lookup_info + .max_joint_size; + // Adding one for the table IDs + for _i in 0..table_width + 1 { + t += acc; + // joint_combiner^i + acc *= joint_combiner; + } + if lcs.runtime_selector.is_some() { + let runtime_blinder = { + let runtime_comm = lookup_context.runtime_table_comm.as_ref().unwrap(); + runtime_comm.blinders.unshifted[0] + }; + PolyComm { + unshifted: vec![t + *joint_combiner * runtime_blinder], + shifted: None, + } + } else { + PolyComm { + unshifted: vec![t], + shifted: None, + } } - } else { - non_hiding(1) }; let joint_lookup_table = lookup_context.joint_lookup_table.as_ref().unwrap(); diff --git a/kimchi/src/verifier_index.rs b/kimchi/src/verifier_index.rs index a7f7b28d14a..ec56ce82691 100644 --- a/kimchi/src/verifier_index.rs +++ b/kimchi/src/verifier_index.rs @@ -184,10 +184,10 @@ impl ProverIndex { lookup_table: cs .lookup_table8 .iter() - .map(|e| self.srs.commit_evaluations_non_hiding(domain, e)) + .map(|e| mask_fixed(self.srs.commit_evaluations_non_hiding(domain, e))) .collect(), table_ids: cs.table_ids8.as_ref().map(|table_ids8| { - self.srs.commit_evaluations_non_hiding(domain, table_ids8) + mask_fixed(self.srs.commit_evaluations_non_hiding(domain, table_ids8)) }), runtime_tables_selector: cs .runtime_selector