Skip to content

Commit

Permalink
Fix stale comments
Browse files Browse the repository at this point in the history
  • Loading branch information
byeongkeunahn committed Sep 19, 2023
1 parent 9a33d19 commit 2639746
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/biguint/ntt.rs
Expand Up @@ -65,7 +65,6 @@ impl<const P: u64> Arith<P> {
const fn ntt_root() -> u64 {
let mut p = 2;
'outer: loop {
/* ensure p is prime */
let root = Self::powmod_naive(p, P/Self::MAX_NTT_LEN);
let mut j = 0;
while j <= Self::FACTOR_TWO {
Expand Down Expand Up @@ -605,7 +604,7 @@ fn conv<const P: u64>(plan: &NttPlan, x: &mut [u64], xlen: usize, y: &mut [u64],
ntt_dif_dit::<P, false>(plan, &mut x[g..], &tf_list);
ntt_dif_dit::<P, false>(plan, &mut y[g..], &tf_list);

/* naive or Karatsuba multiplication */
/* naive multiplication */
let mut i = g;
let (mut ii, mut ii_mod_last_radix) = (0, 0);
let tf = &tf_list[tf_last_start..];
Expand All @@ -624,8 +623,6 @@ fn conv<const P: u64>(plan: &NttPlan, x: &mut [u64], xlen: usize, y: &mut [u64],
} else {
tf_current = Arith::<P>::mmulmod(tf_current, tf_mult);
}

/* we multiply the inverse of the length here to save time */
conv_base::<P>(g, x.as_mut_ptr().wrapping_add(i), y.as_mut_ptr().wrapping_add(i),
tf_current);
i += g;
Expand Down

0 comments on commit 2639746

Please sign in to comment.