Skip to content

Commit

Permalink
Denom is not zero (#793)
Browse files Browse the repository at this point in the history
debug assert denom is not zero
  • Loading branch information
shaharsamocha7 authored Aug 25, 2024
2 parents f16ba08 + 4fc09a7 commit 40cb2fe
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions crates/prover/src/constraint_framework/logup.rs
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,11 @@ impl<'a> LogupColGenerator<'a> {
numerator: PackedSecureField,
denom: PackedSecureField,
) {
debug_assert!(
denom.to_array().iter().all(|x| *x != SecureField::zero()),
"{:?}",
("denom at vec_row {} is zero {}", denom, vec_row)
);
unsafe {
self.numerator.set_packed(vec_row, numerator);
*self.gen.denom.data.get_unchecked_mut(vec_row) = denom;
Expand Down

0 comments on commit 40cb2fe

Please sign in to comment.