WIN64: missing GMP support for builds using MSVC

sav_ix at ukr.net sav_ix at ukr.net
Thu Feb 1 04:51:26 UTC 2018


Hello everyone,

Drawing your attention, that:
  - recent Autotools versions provide support for builds using MSVC,
  - MSYS2 (https://github.com/msys2/msys2/wiki/MSYS2-introduction) provide environment for such builds,
  - recent MSVC (https://www.visualstudio.com/vs/community/) available for free for Open Source development,
  - Yasm (http://yasm.tortall.net) able to build '.gas' files on Windows.

The above allows to build GMP and MPFR using MSVC (and thus Windows ICC) in the same way and with the same set of '.gas' files, as using mingw-w64 on Windows or GCC on "native" GMP platforms. The output are full-featured binaries with <Shared|Static> layout, which passes all 'make check' tasks. Screenshot with benchmark results added in attachment.

Surely, there are enough issues with such builds using vanilla GMP sources. A part of them relate to MSVC (already reported and expected to be fixed), others to GMP build system and sources (most fixes could be committed to trunk without breaking builds on other platforms, the rest would require workarounds or rethinking design decisions).

As a side effect of builds using MSVC could be considered a wider testing of GMP sources. It already revealed few GMP bugs:
https://gmplib.org/list-archives/gmp-bugs/2017-December/004243.html
https://gmplib.org/list-archives/gmp-bugs/2018-January/004276.html
(although mingw-w64 was enough for this) and presumably would help in such way in future.

If GMP Community would be interested to provide support for builds using MSVC, the starting point may be PR:
https://gmplib.org/list-archives/gmp-bugs/2017-June/004164.html
It's unrelated to MSVC, but allows to use Yasm or mingw-w64 to process '.gas' files for builds using MSVC. There were no regressions with it on Windows. But it wasn't tested on none-Windows platforms, on which its discussion was stopped:
https://gmplib.org/list-archives/gmp-bugs/2017-August/004184.html


Best,

Alexander

-------------- next part --------------
A non-text attachment was scrubbed...
Name: mpfrbench_on_windows.png
Type: image/png
Size: 78304 bytes
Desc: not available
URL: <https://gmplib.org/list-archives/gmp-discuss/attachments/20180201/3a6c8434/attachment-0001.png>


More information about the gmp-discuss mailing list