invert_limb_table and "generic" code

Torbjorn Granlund tg at gmplib.org
Tue May 3 21:23:29 CEST 2011


nisse at lysator.liu.se (Niels Möller) writes:

  Torbjorn Granlund <tg at gmplib.org> writes:
  
  > David Harvey <dmharvey at cims.nyu.edu> writes:
  >   configure: error: no version of invert_limb_table found in path: generic
  >   
  >   It looks like maybe the --disable-assembly option is buggy, it doesn't even exist in GMP 5.0.
  >   
  > Yes, it was added recently.
  >
  > Niels, perhaps you could take a look at this?  
  
  invert_limb_table is added to extra_functions_64, for x86_&$ hosts. I
  though files on that list are optional, but maybe I misunderstood. Does
  the below work, and if so, is it the right way to solve the problem?
  
  diff -r 588de4e62671 configure.in
  --- a/configure.in   Mon May 02 19:41:32 2011 +0200
  +++ b/configure.in   Mon May 02 23:10:54 2011 +0200
  @@ -1515,7 +1515,9 @@ case $host in
   	cyclecounter_size_64=2
   	abilist="64 32"
   	path_64="x86_64"
  -	extra_functions_64="invert_limb_table"
  +	if test "$enable_assembly" = "yes ; then
  +	    extra_functions_64="invert_limb_table"
  +	fi
   
  	case $host_cpu in
   	  x86_64)
  
  
  Or would it be better to add it to the more global
  gmp_mpn_functions_optional (which aren't required, right?).
  
I don't know which would be better.

Since this table is probably quite non-standard--its values will not
make sense for all target systems, I suppose defining it as you do above
might make most sense.

-- 
Torbjörn


More information about the gmp-devel mailing list