[PATCH] Optimize 32-bit sparc T1 multiply routines.

David Miller davem at davemloft.net
Fri Jan 4 21:34:09 CET 2013


From: bodrato at mail.dm.unipi.it
Date: Fri, 4 Jan 2013 14:12:23 +0100 (CET)

> Il Ven, 4 Gennaio 2013 10:07 am, David Miller ha scritto:
>> 	mpmul	3			! The immediate field is "N - 1"
> 
> Does the immediate means that, to write e.g. sqr_basecase (it should be
> far simpler than writing mul_basecase), you need a branch for each
> different N?

Yes, you need to conditionally load the proper number of inputs and
store the proper number of outputs as well.  Generally a Duffs Device
type thing for the argument and return value handling, a set of stubs
for each "mpmul N" case, and table driven dispatch.


More information about the gmp-devel mailing list