Replacement for GMP as Bignum: ARPREC? Haskell?; OS-X and OpenSSL

Seth Kurtzberg seth at cql.com
Sat Jul 29 22:09:45 EDT 2006


On Sat, 29 Jul 2006 21:45:21 -0400
p.tanski at gmail.com wrote:

> GHC Task Ticket # 601 suggests replacing GMP with OpenSSL's Bignum library, BN.
> I have two questions concerning this:
> 
> (1) Why not use the ARbitrary PRECision Computation Package (ARPREC)
> by David Bailey, Yozo Hida, Karthik Jeyabalan, Xiaoye Li and Brandon
> Thompson?  Here is a reference web page:
> http://crd.lbl.gov/~dhbailey/mpdist/
> 
> ARPREC is written in C++ but supports calls from C (see
> include/arprec/c_mp.h in the distribution directory).  ARPREC is very
> fast and supports more complex mathematics than BN.  The Licensing for
> ARPREC is not a problem: essentially similar to BSD3.
> 
> Note that there would be a basic configuration fix for building
> OpenSSL's BN library on OS 10.4: you would probably--I had to,
> myself--have to temporarily move the default installation of
> /usr/lib/libssl0.9.dylib (and variants) if you want to create a shared
> (.a) library because Apple's ln links dynamic libraries in preference
> to shared libraries.

I think you meant "if you want to create a static (.a) library", not "if you want to create a shared (.a) library"

  Those of you who have some experience with
> Apple's gcc also know that Apple's gcc does not recognise the -shared
> flag.
> 
> (2) A much more aesthetic solution would be to replace any external
> Bignum library with a pure Haskell library.  There are many problems
> with building a truly efficient and fast Bignum library in Haskell but
> challenges like that are how languages evolve...
> 
> -Peter Tanski
> _______________________________________________
> Glasgow-haskell-users mailing list
> Glasgow-haskell-users at haskell.org
> http://www.haskell.org/mailman/listinfo/glasgow-haskell-users
> 


More information about the Glasgow-haskell-users mailing list