ref/include/f11_260.c
// Multiply a narrow residue by a small constant. The result is reduced to 32
// bits, but not narrowed for performance reasons.
Multiply a narrow residue by a small constant. The result is reduced to 32
bits, but not narrowed for performance reasons.
Multiply a narrow residue by a small constant . The result is reduced to 32 bits but not narrowed for performance reasons .
void mul_narrow_const(
  residue_narrow_t *result, const residue_narrow_t *x, int32_t d) {
  residue_wide_t temp;
  for (int i = 0; i < NLIMBS; ++i) {
    temp.limbs[i] = ((uint64_t) x->limbs[i]) * d;
  }
  reduce_step_wide(&temp, &temp);
  narrow(result, &temp);
}
void mul_narrow_const ( residue_narrow_t * result , const residue_narrow_t * x , int32_t d ) { residue_wide_t temp ; for ( int i = 0 ; i < NLIMBS ; ++ i ) { temp . limbs [ i ] = ( ( uint64_t ) x -> limbs [ i ] ) * d ; } reduce_step_wide ( & temp , & temp ) ; narrow ( result , & temp ) ; }
Multiply a narrow residue by a small constant.
Multiply a narrow residue by a small constant .