[PATCH] Add optimized addmul_1 and submul_1 for IBM z13

Torbjörn Granlund tg at gmplib.org
Sat Mar 6 17:06:28 UTC 2021


Marius Hillenbrand <mhillen at linux.ibm.com> writes:

  z13: introduced the vector extensions
    PoP: Vector Facility for z/Architecture
    Linux: vx / HWCAP_S390_VX

  z14:
    Vector-Enhancements Facility 1
    vxe / HWCAP_S390_VXE

  z15:
    Vector-Enhancements Facility 2 (adds VLERG and VSTERG, among others)
    vxe2 / HWCAP_S390_VXRS_EXT2

You forgot to mention z16?  :-)

IIRC, your config* patches added z13 by grepping /proc/cpuinfo.  It did
not add z14 or z15.  Any particular reason for that?  I think it makes
sense to have accurate recognition code in GMP, even if we then treat
the CPUs exactly the same.

BTW, it turns out that the system I amplaying with is a z15.

Here is /proc/cpuinfo (cut after one CPU):

    vendor_id       : IBM/S390
    # processors    : 2
    bogomips per cpu: 3241.00
    max thread id   : 0
    features        : esan3 zarch stfle msa ldisp eimm dfp edat etf3eh highgprs te vx vxd vxe gs vxe2 vxp sort dflt sie 
    facilities      : 0 1 2 3 4 6 7 8 9 10 12 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 30 31 32 33 34 35 36 37 38 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 57 58 59 60 61 73 74 75 76 77 80 81 82 128 129 130 131 133 134 135 146 147 148 150 151 152 155 156 168
    cache0          : level=1 type=Data scope=Private size=128K line_size=256 associativity=8
    cache1          : level=1 type=Instruction scope=Private size=128K line_size=256 associativity=8
    cache2          : level=2 type=Data scope=Private size=4096K line_size=256 associativity=8
    cache3          : level=2 type=Instruction scope=Private size=4096K line_size=256 associativity=8
    cache4          : level=3 type=Unified scope=Shared size=262144K line_size=256 associativity=32
    cache5          : level=4 type=Unified scope=Shared size=983040K line_size=256 associativity=60
    processor 0: version = FF,  identification = 100003,  machine = 8561
    processor 1: version = FF,  identification = 200003,  machine = 8561

    cpu number      : 0
    physical id     : 0
    core id         : 0
    book id         : 0
    drawer id       : 0
    dedicated       : 0
    address         : 0
    siblings        : 1
    cpu cores       : 1
    version         : FF
    identification  : 100003
    machine         : 8561
    cpu MHz dynamic : 5200
    cpu MHz static  : 5200

I measure the actual clock to 3800 MHz, not 5200.

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


More information about the gmp-devel mailing list