PARI/GP
Main
  Download
  Packages
  GP in your browser
  Timeline
  Search

Support
  FAQ
  Documentation
  Tutorials
  Ateliers PARI/GP
  Mailing Lists

GP scripts library
  Contributed scripts

Development
  Bugs
  Latest Changes
  Version Control
  Coding Guidelines
  PariDroid
  Funding

Tests & benchmarks
  Buildlogs
  Coverage Report
  Doc Coverage
  Benchmarks

Miscellaneous
  WWW Stats
  Logo
  Fun!
  Links

PARI library benchmarks: integer arithmetic

This page refers to version 2.9.0 of the PARI/GP system [ bench source code ], with native kernel and GMP kernel respectively. PARI and GMP-6.0.0 were linked dynamically to the bench program.

The following tables give the cpu time in milliseconds spent by the PARI kernels for different operations, at different (decimal) digitsizes. For everything but divisions, a test for N digits means two operands with N decimal digits. For divisions, the dividend has 2N decimal digits, and the divisor has N decimal digits.

64-bit machine: pari.math.u-bordeaux.fr

Xeon E5540 @ 2.53Ghz, running Linux 3.16.0-4-amd64. Libraries were compiled with gcc 4.9.2 and native flags.

100 digits pari-2.9.0-gmp pari-2.9.0
addii 0.000030 0.000028
sqri 0.000062 0.000091
mulii 0.000084 0.00011
sqrti 0.00025 0.00073
diviiexact 0.00014 0.00017
divii 0.00022 0.00027
dvmdii 0.00023 0.00030
redc 0.00014 0.00015
gcdii 0.0023 0.001.00
bezout 0.0031 0.0056
invmod 0.0028 0.0045
ratlift 0.0025 0.0024
1000 digits pari-2.9.0-gmp pari-2.9.0
addii 0.00013 0.000081
sqri 0.0022 0.0033
mulii 0.0036 0.0054
sqrti 0.0019 0.0033
diviiexact 0.0033 0.0037
divii 0.0056 0.0075
dvmdii 0.0056 0.0076
redc 0.0066 0.0067
gcdii 0.052 0.22
bezout 0.068 0.12
invmod 0.061 0.094
ratlift 0.052 0.049
10000 digits pari-2.9.0-gmp pari-2.9.0
addii 0.0010 0.00065
sqri 0.092 0.15
mulii 0.12 0.24
sqrti 0.061 0.090
diviiexact 0.19 0.30
divii 0.28 0.63
dvmdii 0.28 0.63
redc 0.64 0.65
gcdii 1.4 13
bezout 2.4 6.2
invmod 2.1 4.2
ratlift 2.3 2.2
100000 digits pari-2.9.0-gmp pari-2.9.0
addii 0.010 0.0064
sqri 2.1 3.6
mulii 3.0 5.3
sqrti 2.3 6.2
diviiexact 5.5 30
divii 7.4 62
dvmdii 7.4 62
redc 64 65
gcdii 45 1164
bezout 74 583
invmod 66 384
ratlift 209 198

32-bit machine: pari.math.u-bordeaux.fr

Xeon E5540 @ 2.53Ghz, running Linux 3.16.0-4-amd64. Libraries were compiled with gcc 4.9.2 -m32 and native flags.

100 digits pari-2.9.0-gmp pari-2.9.0
addii 0.000034 0.000043
sqri 0.00012 0.00027
mulii 0.00017 0.00052
sqrti 0.00049 0.0013
diviiexact 0.00025 0.00041
divii 0.00048 0.00075
dvmdii 0.00048 0.00078
redc 0.00072 0.00051
gcdii 0.0043 0.017
bezout 0.0059 0.014
invmod 0.0053 0.010
ratlift 0.0051 0.0054
1000 digits pari-2.9.0-gmp pari-2.9.0
addii 0.00010 0.00016
sqri 0.0048 0.016
mulii 0.0074 0.026
sqrti 0.0048 0.011
diviiexact 0.0075 0.015
divii 0.019 0.052
dvmdii 0.019 0.052
redc 0.053 0.035
gcdii 0.094 0.46
bezout 0.14 0.49
invmod 0.13 0.34
ratlift 0.10 0.18
10000 digits pari-2.9.0-gmp pari-2.9.0
addii 0.00078 0.0013
sqri 0.15 0.67
mulii 0.22 1.0
sqrti 0.17 0.56
diviiexact 0.38 1.2
divii 0.64 5.1
dvmdii 0.64 5.1
redc 5.4 3.5
gcdii 3.8 34
bezout 5.2 36
invmod 4.6 24
ratlift 5.6 13
100000 digits pari-2.9.0-gmp pari-2.9.0
addii 0.0083 0.013
sqri 3.1 10.0
mulii 4.8 16
sqrti 4.5 46
diviiexact 9.7 121
divii 12 507
dvmdii 12 508
redc 543 345
gcdii 95 3256
bezout 153 3588
invmod 139 2372
ratlift 517 1216

PARI/GP Development
Last Modified: 2016-08-02 15:02:24
Copyleft © 2003-2016 the PARI group.