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 to exceed 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.12.1 lcov report (development 24495-f03dc99ac) Lines: 1119 1151 97.2 %
Date: 2019-10-22 05:49:16 Functions: 69 69 100.0 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
pari_kernel_close 678
pari_kernel_init 680
sqrispec_fft 1116
incneg 6054
muliispec_fft 10134
muliifft_unspliti 11250
mulliifft_params 11250
muliifft_spliti 21384
diviuuexact 100815
muluui 117483
resetloop 127992
convi 239289
Zf_sqr 258816
sqrtispec2_sh 486537
addumului 519453
floorr 611742
convi_dac 670035
divis 892653
truncr 1498977
Zf_mul 1752192
muliifft_dis 1999758
sqrtispec1_sh 2161227
setloop 2235540
sqrtremi 2735721
muliifft_dit 3741816
remi2n 8675439
mantissa2nr 12846462
diviuexact_i 17757024
sqrtr_abs 19199724
xmpn_zero 19199724
sqrtispec2 19287627
p_sqrtu2 19774164
incpos 20332449
incloop 20587299
red_montgomery 21603621
p_sqrtu1 21935391
divri 22805058
Zf_add 22819776
Zf_mulsqrt2 22819776
Zf_sub 23154183
Zf_shift 24772986
diviuexact 27602568
divis_rem 44170422
Zf_red_destroy 47996922
sqrtispec 62222121
divrr 81141810
catii 85868988
affir 112532709
absdiviu_rem 119122194
equaliispec 125480361
addshiftw 140186109
adduispec_offset 148303353
int_normalize 177533307
xmpn_copy 199781745
diviiexact 231286680
roundr_up_ip 259890611
shiftispec 432045438
sqrispec_basecase 514954020
sqrispec 519627789
dvmdii 618563874
subiuspec 736978873
adduispec 968177646
umodiu 1182262857
subiispec 1447854480
muluispec 1747904232
cmpiispec 1876846761
addiispec 1892652720
muliispec_basecase 1955310159
muliispec 2000128317

Generated by: LCOV version 1.13