Code coverage tests

This page documents the degree to which the PARI/GP source code is tested by our public test suite, distributed with the source distribution in directory src/test/. This is measured by the gcov utility; we then process gcov output using the lcov frond-end.

We test a few variants depending on Configure flags on the pari.math.u-bordeaux.fr machine (x86_64 architecture), and agregate them in the final report:

The target is 90% coverage for all mathematical modules (given that branches depending on DEBUGLEVEL or DEBUGMEM are not covered). This script is run to produce the results below.

LCOV - code coverage report
Current view: top level - kernel/gmp - mp.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.10.0 lcov report (development 20783-cec4728) Lines: 639 716 89.2 %
Date: 2017-06-28 05:59:20 Functions: 53 54 98.1 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
GEN2mpz 243004789
addiispec 1649413270
adduispec 1231710052
adduispec_offset 328640250
addumului 840547
affir 108838042
cmpiispec 2049906002
convi 833832
diviiexact 246136714
divis 313432
divis_rem 44552786
diviu_rem 129731816
diviuexact 262871811
diviuuexact 552173
divri 17466695
divri_with_gmp 3280533
divrr 85421197
divrr_with_gmp 33785611
dvmdii 984834487
equaliispec 105613371
floorr 485230
icopy_ef 19496047
incloop 66519292
incneg 6188
incpos 66485428
int_normalize 146876305
mantissa2nr 23383737
mpz2GEN 233109928
muliispec 2290243103
muliispec_mirror 60605451
muluispec 2295684952
muluui 574381
pari_gmp_free 204815
pari_gmp_realloc 0
pari_kernel_close 872
pari_kernel_init 872
red_montgomery 8164152
remi2n 12782640
resetloop 170732
roundr_up_ip 271529643
setloop 2452215
shiftispec 363645092
sqrispec 752915884
sqrispec_mirror 4768240
sqrtr_abs 22381584
sqrtremi 3283660
subiispec 1637129057
subiuspec 834336469
truncr 1514350
umodiu 856883437
xmpn_copy 1340079
xmpn_mirror 186886636
xmpn_mirrorcopy 276010841
xmpn_zero 59447728

Generated by: LCOV version 1.11