GMP support for AMD Ryzen

Torbjörn Granlund tg at gmplib.org
Mon Apr 17 00:00:12 UTC 2017


I've committed initial optimisation for AMD Ryzen.  Before these
commits, GMP worked fine but was only recognised as a plain x86-64 CPU.

We now get a GMPbench score of about 1250 per GHz per core, which is
among the best results seen: https://gmplib.org/gmpbench.html

AMD decided for an integer multiplier with a throughput of 1 every 2nd
cycle, which is good but not optimal.  There are ample non-multiply
integer execution resources in these CPUs, so with the committed code we
sustain one accumulated 128-bit product every 2nd cycle, i.e., we
saturate the multiplier.


-- 
Torbjörn
Please encrypt, key id 0xC8601622


More information about the gmp-devel mailing list