uint icon indicating copy to clipboard operation
uint copied to clipboard

`algorithms/gcd/matrix`: We can avoid the temporary if we implement a dedicated matrix

Open github-actions[bot] opened this issue 2 years ago • 0 comments

On 2022-06-06 @recmo wrote in 4c74c09 “Merge pull request #110 from recmo/gcd”:

We can avoid the temporary if we implement a dedicated matrix multiplication.

        b: &mut Uint<BITS, LIMBS>,
    ) {
        if BITS == 0 {
            return;
        }
        // OPT: We can avoid the temporary if we implement a dedicated matrix
        // multiplication.
        let (c, d) = if self.4 {
            (
                Uint::from(self.0) * *a - Uint::from(self.1) * *b,
                Uint::from(self.3) * *b - Uint::from(self.2) * *a,
            )

From src/algorithms/gcd/matrix.rs:45

github-actions[bot] avatar Jun 06 '22 03:06 github-actions[bot]