6.0.0 crash at high precision mul?
marc.glisse at inria.fr
Thu Jun 5 12:25:17 UTC 2014
On Thu, 5 Jun 2014, Torbjörn Granlund wrote:
> Marc Glisse <marc.glisse at inria.fr> writes:
> Yes, better replace 65536 with something smaller in gmp-impl.h.
Note this was meant as a suggestion for the OP, not necessarily a
proposition for GMP (you already rejected it some years ago).
> That's 65536 bytes, or 8192 limbs on a 64-bit machine. It is not clear
> to me that this is a too high limit, not even for a system with tiny
> stack size defaults.
Some GMP functions do 10 allocations, can be called recursively, call
other functions that do allocations, etc. With a 512kB stack (or even 1MB)
it goes quite quickly...
Is there a measurable performance difference if we divide 65536 by 4?
I think it was Marco who wanted to generalize the use of TMP_ALLOC_LIMBS_2
recently, that could help as well.
More information about the gmp-discuss