Re: mul_fft, cleaning up some details of the code

2022-03-06 Thread Marco Bodrato
Ciao, Il 2022-03-06 12:16 Torbjörn Granlund ha scritto: Marco Bodrato writes: The comment before the mpn_mul_fft_decompose function says "We must have nl <= 2*K*l", this means that we should never have ((dif = nl - Kl) > Kl), and the code in that branch should never be used. I notic

Re: mul_fft, cleaning up some details of the code

2022-03-06 Thread Torbjörn Granlund
Marco Bodrato writes: This is not really needed to solve a bug. The comment before the mpn_mul_fft_decompose function says "We must have nl <= 2*K*l", this means that we should never have ((dif = nl - Kl) > Kl), and the code in that branch should never be used. I noticed that at some poi

mul_fft, cleaning up some details of the code

2022-03-06 Thread Marco Bodrato
Ciao, I looked into the code published by Samuel Vivien. I realised that in mul_fft there are a lot of _add_1 and _sub_1. At least some of them can be easily replaced by _INCR_U or _DECR_U... Specifically I'd focus into a suspicious piece of code, shared by both our current code and Vivien's.