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/none - mp.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.10.0 lcov report (development 21741-70cf009) Lines: 1113 1148 97.0 %
Date: 2018-01-21 06:18:30 Functions: 69 69 100.0 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
Zf_add 27678912
Zf_mul 2043264
Zf_mulsqrt2 27678912
Zf_red_destroy 56916189
Zf_shift 29385507
Zf_sqr 268416
Zf_sub 27999057
addiispec 1743796314
addshiftw 130001829
adduispec 865670437
adduispec_offset 137725080
addumului 442344
affir 89232159
catii 68910306
cmpiispec 1727217870
convi 275557
convi_dac 1053969
diviiexact 200194660
divis 291510
divis_rem 63702699
diviu_rem 104415465
diviuexact 25160664
diviuexact_i 16648269
diviuuexact 402774
divri 13909557
divrr 68471745
dvmdii 519270812
equaliispec 82379074
floorr 348009
incloop 19687611
incneg 4701
incpos 19655124
int_normalize 158215710
mantissa2nr 9847158
muliifft_dis 2299989
muliifft_dit 4332741
muliifft_spliti 22203
muliifft_unspliti 11691
muliispec 1830484070
muliispec_basecase 1785587891
muliispec_fft 10512
mulliifft_params 11691
muluispec 1733390631
muluui 419430
p_sqrtu1 19172422
p_sqrtu2 16927161
pari_kernel_close 645
pari_kernel_init 647
red_montgomery 24063840
remi2n 6766167
resetloop 127959
roundr_up_ip 234485177
setloop 1871475
shiftispec 391759641
sqrispec 582504957
sqrispec_basecase 578816559
sqrispec_fft 1179
sqrtispec 51086628
sqrtispec1_sh 2245261
sqrtispec2 16631475
sqrtispec2_sh 295686
sqrtr_abs 16563603
sqrtremi 2608822
subiispec 1335196432
subiuspec 680995187
truncr 1222137
umodiu 964283162
xmpn_copy 162278979
xmpn_zero 16563603

Generated by: LCOV version 1.11