PARI/GP
Main
  Download
  Packages
  Timeline
  Search

Support
  FAQ
  Documentation
  Tutorials
  Ateliers PARI/GP
  Mailing Lists

GP scripts library
  Contributed scripts

Development
  Bugs
  Latest Changes
  Version Control
  Coding Guidelines

Tests & benchmarks
  Buildlogs
  Coverage report
  Benchmarks

Miscellaneous
  WWW Stats
  Logo
  Fun!
  Links

PARI library benchmarks: integer arithmetic

This page refers to the stable version 2.5.5 of the PARI/GP system [ bench source code ], with native kernel and GMP kernel respectively. PARI and GMP-4.3.2 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 N decimal digits.

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

Xeon E5540 @ 2.53Ghz, running Linux 2.6.32-5-amd64. Libraries were compiled with gcc 4.4.5 and native flags.

100 digits pari-2.5.5-gmp pari-2.5.5
addii 0.000032 0.000025
sqri 0.000073 0.000086
mulii 0.000083 0.00011
sqrti 0.00026 0.00065
diviiexact 0.00013 0.00018
divii 0.00022 0.00038
dvmdii 0.00023 0.00040
redc 0.00014 0.00014
gcdii 0.0028 0.0093
bezout 0.0036 0.0059
invmod 0.0033 0.0051
ratlift 0.0027 0.0026
1000 digits pari-2.5.5-gmp pari-2.5.5
addii 0.00013 0.00012
sqri 0.0036 0.0033
mulii 0.0037 0.0057
sqrti 0.0019 0.0036
diviiexact 0.0032 0.0037
divii 0.0061 0.0088
dvmdii 0.0060 0.0088
redc 0.0064 0.0066
gcdii 0.055 0.26
bezout 0.072 0.14
invmod 0.065 0.11
ratlift 0.052 0.059
10000 digits pari-2.5.5-gmp pari-2.5.5
addii 0.0010 0.0011
sqri 0.14 0.16
mulii 0.14 0.26
sqrti 0.066 0.095
diviiexact 0.25 0.31
divii 0.29 0.63
dvmdii 0.29 0.63
redc 0.62 0.64
gcdii 1.4 19
bezout 2.5 8.8
invmod 2.1 6.0
ratlift 2.3 3.1
100000 digits pari-2.5.5-gmp pari-2.5.5
addii 0.011 0.011
sqri 3.9 4.5
mulii 3.9 6.7
sqrti 2.4 6.4
diviiexact 9.9 30
divii 10.0 61
dvmdii 9.9 61
redc 62 64
gcdii 49 1813
bezout 87 837
invmod 73 557
ratlift 209 293

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

Xeon E5540 @ 2.53Ghz, running Linux 2.6.32-5-amd64. Libraries were compiled with gcc 4.4.5 -m32 and native flags.

100 digits pari-2.5.5-gmp pari-2.5.5
addii 0.000046 0.000056
sqri 0.00029 0.00034
mulii 0.00030 0.00061
sqrti 0.00051 0.0012
diviiexact 0.00027 0.00047
divii 0.00051 0.00090
dvmdii 0.00051 0.00094
redc 0.00068 0.00067
gcdii 0.0043 0.016
bezout 0.0061 0.014
invmod 0.0054 0.011
ratlift 0.0055 0.0058
1000 digits pari-2.5.5-gmp pari-2.5.5
addii 0.00019 0.00039
sqri 0.014 0.021
mulii 0.014 0.035
sqrti 0.0059 0.012
diviiexact 0.012 0.030
divii 0.023 0.058
dvmdii 0.023 0.058
redc 0.055 0.055
gcdii 0.10 0.75
bezout 0.17 0.60
invmod 0.15 0.44
ratlift 0.14 0.23
10000 digits pari-2.5.5-gmp pari-2.5.5
addii 0.0017 0.0038
sqri 0.44 0.91
mulii 0.44 1.4
sqrti 0.24 0.64
diviiexact 0.99 2.7
divii 0.99 5.5
dvmdii 0.99 5.5
redc 5.5 5.5
gcdii 4.3 63
bezout 8.1 51
invmod 6.6 34
ratlift 8.4 18
100000 digits pari-2.5.5-gmp pari-2.5.5
addii 0.019 0.037
sqri 7.7 16
mulii 9.5 24
sqrti 8.6 51
diviiexact 31 270
divii 31 544
dvmdii 31 543
redc 545 548
gcdii 162 6244
bezout 300 5060
invmod 257 3381
ratlift 832 1788

PARI/GP Development
Last Modified: 2013-10-06 19:25:02
Copyleft © 2003-2013 the PARI group.