What is GMP (fragment from GMP documentation)
===============================================
GNU MP is a portable library written in C for arbitrary precision
arithmetic on integers, rational numbers, and floating-point numbers.
It aims to provide the fastest possible arithmetic for all
applications that need higher precision than is directly supported
by the basic C types.
See http://gmplib.org/ for more details.
GMP is distributed under the GNU LGPL. This license makes the library
free to use, share, and improve, and allows you to pass on the result.
The license gives freedoms, but also sets firm restrictions on the use
with non-free programs.
Available files
===============
ftp://ftp.delorie.com/pub/djgpp/current/v2gnu/gmp431b.zip
Binary archive of GMP-4.3.1 for DJGPP v2.03r2
ftp://ftp.delorie.com/pub/djgpp/current/v2gnu/gmp431s.zip
Source archive of GMP-4.3.1 for DJGPP (source are
configured using DJGPP v2.03r2 for target
i386-pc-msdosdjgpp)
ftp://ftp.delorie.com/pub/djgpp/current/v2gnu/gmp431s.zip
Source archive of GMP-4.3.1 for DJGPP (source are
configured using DJGPP v2.04pre for target
i386-pc-msdosdjgpp)
ftp://ftp.delorie.com/pub/djgpp/beta/v2gnu/gmp431b.zip
Binary archive of GMP-4.3.1 for DJGPP v2.04pre
Binary packages are built using GCC-4.4.2.
Building GMP from gmp431s.zip is not tested without LFN support.
Andris Pavenis <andris....@iki.fi>
On Dec 17, 12:56 pm, Andris Pavenis <andris.pave...@iki.fi> wrote:
>
> This is announcement of DJGPP port of GMP-4.3.1
>
> GNU MP is a portable library written in C for arbitrary precision
> arithmetic on integers, rational numbers, and floating-point numbers.
>
> See http://gmplib.org/ for more details.
Dumb question, but why don't they make "--enable-fat" the default for
x86? I just built it, and it's a little larger, but it should
(ideally) be much faster, esp. for time-intensive things that use it
(e.g. GCC) since it checks at runtime what cpu-specific code to run.
(your compile for /beta/):
-rw-a-- 3.0 fat 517550 b- defX 09-Dec-13 18:23 lib/libgmp.a
-rw-a-- 3.0 fat 22976 b- defX 09-Dec-13 18:23 lib/libgmpxx.a
-rw-a-- 3.0 fat 247714 b- defX 09-Dec-13 18:23 lib/libmp.a
(my compile using /beta/):
12/19/2009 06:50 PM 651,238 libgmp.a
12/19/2009 06:50 PM 23,300 libgmpxx.a
12/19/2009 06:51 PM 377,556 libmp.a
http://rapidshare.com/files/323273044/gmp431b-beta-fat.zip.html
MD5: C961D95121DCCC8A76A243A0F609798C
1) the configure option --enable-fat is added:
D:\DJDEV\gmp\test>gmp-chudnovsky.exe 100000000
#terms=7051366, depth=24
sieve time = 1.483
.................................................
bs time = 660.055
gcd time = 0.000
div time = 55.000
sqrt time = 29.615
mul time = 21.264
total time = 767.582
P size=145605885 digits (1.456059)
Q size=145605879 digits (1.456059)
2) the library from earlier build (no --enable-fat)
D:\DJDEV\gmp\test>gmp-chudnovsky.exe 100000000
#terms=7051366, depth=24
sieve time = 1.483
.................................................
bs time = 925.659
gcd time = 0.000
div time = 74.011
sqrt time = 43.407
mul time = 28.571
total time = 1073.296
P size=145605885 digits (1.456059)
Q size=145605879 digits (1.456059)
As one can see, there is some improvement when --enable-fat has been
specified.
I do not believe that compilation speed of GCC is noticeably dependant
on optimization level of GMP.
As far as I understand GMP and MPFR is being using for propagating
constants (if one specifies
some constant expression, GCC tries to calculate value in compile time
instead of genarating code
for evaluation this expression). I guess that the number of such
constant expressions is usually too small
to cause any noticable increase of compilation time dues to
non-optimality of GMP.
Andris