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.8.0 lcov report (development 18948-dd2a64a) Lines: 1108 1148 96.5 %
Date: 2016-05-27 Functions: 69 69 100.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 926 1110 83.4 %

Function Name Sort by function name Hit count Sort by hit count
Zf_add 36330816
Zf_mul 2038656
Zf_mulsqrt2 36330816
Zf_red_destroy 72006912
Zf_shift 36911355
Zf_sqr 443520
Zf_sub 36613812
addiispec 1865069970
addshiftw 159141507
adduispec 916722468
adduispec_offset 226070319
addumului 543294
affir 96773127
catii 60820710
cmpiispec 2098882527
convi 232468
convi_dac 1069722
diviiexact 189535938
divis 252249
divis_rem 22858047
diviu_rem 99102009
diviuexact 8304516
diviuexact_i 15831165
diviuuexact 387987
divri 13246494
divrr 81234807
dvmdii 503466435
equaliispec 35025684
floorr 284913
incloop 18123789
incneg 4641
incpos 18104028
int_normalize 207920832
mantissa2nr 9044013
muliifft_dis 2476050
muliifft_dit 4509681
muliifft_spliti 11151
muliifft_unspliti 6126
muliispec 1401188607
muliispec_basecase 1338409326
muliispec_fft 5025
mulliifft_params 6126
muluispec 1296147378
muluui 404643
p_sqrtu1 14602476
p_sqrtu2 13348008
pari_kernel_close 564
pari_kernel_init 564
red_montgomery 6719106
remi2n 6349380
resetloop 117528
roundr_up_ip 126477314
setloop 1674753
shiftispec 345917877
sqrispec 487819926
sqrispec_basecase 484388409
sqrispec_fft 1101
sqrtispec 43753887
sqrtispec1_sh 1254468
sqrtispec2 13343532
sqrtispec2_sh 4476
sqrtr_abs 13335501
sqrtremi 1266975
subiispec 1658655990
subiuspec 869798956
truncr 503088
umodiu 809341974
xmpn_copy 141543351
xmpn_zero 13335501

Generated by: LCOV version 1.9