pub fn batch_multiplicative_inverse_general<F, Inv>(
x: &[F],
result: &mut [F],
inv: Inv,
)Expand description
A simple single-threaded implementation of Montgomery’s trick. Since not all PrimeCharacteristicRings
support inversion, this takes a custom inversion function.
Unlike batch_multiplicative_inverse, this writes into a caller-provided buffer,
avoiding heap allocation. This makes it suitable for small, fixed-size inputs
such as packed field lanes.