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-bordeaux1.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.8.0 lcov report (development 17774-15dbd24) Lines: 641 716 89.5 %
Date: 2015-04-27 Functions: 53 54 98.1 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 424 533 79.5 %

Function Name Sort by function name Hit count Sort by hit count
GEN2mpz 122766204
addiispec 1269398077
adduispec 1069996156
adduispec_offset 318972526
addumului 1097507
affir 131476076
cmpiispec 1832815997
convi 466550
diviiexact 351137827
divis 59478
divis_rem 39905701
diviu_rem 126777899
diviuexact 343327221
diviuuexact 109867
divri 15198444
divri_with_gmp 3249013
divrr 94176101
divrr_with_gmp 19461575
dvmdii 683513495
equaliispec 28867177
floorr 488537
icopy_ef 12680535
incloop 21466178
incneg 5984
incpos 21472136
int_normalize 136913933
mantissa2nr 20770472
mpz2GEN 112982721
muliispec 1290216853
muliispec_mirror 60834830
muluispec 1444617754
muluui 132075
pari_gmp_free 3006
pari_gmp_realloc 0
pari_kernel_close 1232
pari_kernel_init 1740
red_montgomery 6124040
remi2n 10111814
resetloop 145608
roundr_up_ip 123875807
setloop 1514173
shiftispec 227886917
sqrispec 602800147
sqrispec_mirror 4163385
sqrtr_abs 18156632
sqrtremi 1402892
subiispec 1608882881
subiuspec 969465549
truncr 482551
umodiu 591535820
xmpn_copy 1197251
xmpn_mirror 205338598
xmpn_mirrorcopy 226715532
xmpn_zero 40867220

Generated by: LCOV version 1.9