.Trust our experience in High-Power Network Tools and Communication Tools.


(Updated January 2015)

MPIR (http://www.mpir.org/) is based on GMP (http://www.gmplib.org) and can run in GMP compatibility mode. Unlike GMP, MPIR (http://www.mpir.org) can be compiled for Windows out-of-the-box.

With the unmodified MPIR 2.6.0 distribution (which you can download from the MPIR website at http://www.mpir.org/mpir-2.6.0.tar.bz2), I built MPIR DLLs and Static Libraries, for 32-bit as P4 (Pentium 4) and for 64-bit as Core2. This will cover most of the existing Intel machines up to i7. I am not sure how the included compilations will behave on AMD processors, but I have not received any complaints so far.

MPFR (http://www.mpfr.org/) is a C library for multiple-precision floating-point computations with correct rounding. It works either with GMP or MPIR. With the unmodified MPFR 3.1.2 distribution (which you can download from the MPFR website at http://www.mpfr.org/mpfr-3.1.2/) and after struggling a bit, I managed to build 32-bit and 64-bit MPFR DLLs and Static Libraries for Windows.

To confirm everything worked as expected I made a full Visual Studio 2010 project and built 32-bit and 64-bit executables to run either dynamically linked or statically linked.

On the MPIR-only test, which consists of a Pollard’s Rho factorization, 64-bit executables performed almost twice as fast as 32-bit executables. This is good news when lots of software actually run slow when compiled as 64-bit.

If you are new to the MPIR/GMP/MPFR Open Source multiple precision packages and want to learn fast how to use them from Visual Studio, then download the complete project from HERE, it is free. It includes the MPIR and MPFR binaries and static libraries (reason why is over 7 MB).

Note: MPIR and MPFR are licensed under LGPL 3.0. Details can be obtained from http://www.gnu.org/copyleft/lesser.html

Using MPIR and MPFR under Windows