Re: speed of unbalanced multiplication

2013-01-27 Thread Zimmermann Paul
Marco, Date: Sat, 26 Jan 2013 16:21:28 +0100 (CET) From: bodr...@mail.dm.unipi.it Ciao, Il Sab, 26 Gennaio 2013 4:01 pm, bodr...@mail.dm.unipi.it ha scritto: I mean, which timing do you obtain with the following? ./speed -s $((100+775660)/2) mpn_mul_n mpn_mul_n Sorry...

Re: Toom sqr recursion

2013-01-27 Thread Torbjorn Granlund
Torbjorn Granlund t...@gmplib.org writes: I just spotted that we're not depending on SQR_BASECASE_THRESHOLD in any of the recursive toomN_sqr calls. I think we should, at least from toom2_sqr. And in toom44_mul.c and toom4_sqr.c we set MAYBE_*_toom4* using MUL_FFT_THRESHOLD when we should

Re: Toom sqr recursion

2013-01-27 Thread Torbjorn Granlund
Torbjorn Granlund t...@gmplib.org writes: And in toom44_mul.c and toom4_sqr.c we set MAYBE_*_toom4* using MUL_FFT_THRESHOLD when we should really consider TOOM6 or (if TOOM6 = 0) TOOM8. This was forgotten when the 6H and 8H code was merged. Here's is a possible patch set: diff -Nrc2

Extending the mpn interface

2013-01-27 Thread Niels Möller
I'm currently working on some cryptograpic elliptic curve code, using gmp for underlying bignum numbers (of moderate size, largest operation is multiply with 17 limb inputs). I think I want to keep using mpz_t for user-visible functions, but I'm leaning towards using the mpn interface internally,