Re: big number arithmetic

Felix von Leitner <[email protected]> Tue, 27 Mar 2007 18:46:36 +0200
Newsgroups gmane.comp.djb.bignum.devel
Message-ID <[email protected]>
Thus spake D. J. Bernstein ([email protected]):
> > My naive Karatsuba implementation was slower than my naive schoolbook
> > method for 16 word bignums.  I attributed that to it needing to write
> > temp bignums, while my schoolbook method just writes to memory once,
> > into the result bignum.
> Yup, that sounds like a typical Karatsuba slowdown. But the extra costs
> disappear if the extra loads and stores are overlapped with the previous
> computation.

OK, that is not possible on x86 when you use integer arithmetic.
I barely avoid having to spill to memory.  This optimization will open
up to me once I get to floating point :-)

Felix