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.0 lcov report (development 23008-54b2e2f01) Lines: 1119 1151 97.2 %
Date: 2018-09-20 05:37:46 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 654
pari_kernel_init 656
sqrispec_fft 1182
incneg 4704
muliispec_fft 10620
muliifft_unspliti 11802
mulliifft_params 11802
muliifft_spliti 22422
resetloop 127959
convi 266945
Zf_sqr 269184
sqrtispec2_sh 324477
diviuuexact 468633
muluui 485289
addumului 534990
floorr 542874
divis 786402
convi_dac 926310
truncr 1438992
Zf_mul 1862400
muliifft_dis 2119782
setloop 2174991
sqrtispec1_sh 2274644
sqrtremi 2682665
muliifft_dit 3971562
remi2n 8296686
mantissa2nr 11838351
diviuexact_i 16738308
sqrtr_abs 19742871
xmpn_zero 19742871
sqrtispec2 19826409
p_sqrtu2 20150886
incpos 20168568
incloop 20421990
red_montgomery 21496602
p_sqrtu1 22425530
divri 23075697
Zf_add 24249216
Zf_mulsqrt2 24249216
Zf_sub 24601071
diviuexact 25947237
Zf_shift 26012922
divis_rem 33627081
Zf_red_destroy 50345466
sqrtispec 64124913
divrr 82570503
catii 88597008
equaliispec 89272643
affir 109772325
absdiviu_rem 110688090
addshiftw 138582723
adduispec_offset 138917640
int_normalize 174201270
xmpn_copy 206056707
diviiexact 228744573
roundr_up_ip 264485789
shiftispec 411298524
dvmdii 540728348
sqrispec_basecase 604221720
sqrispec 609089454
subiuspec 686289645
adduispec 891972877
umodiu 1026908866
subiispec 1361230607
addiispec 1767567266
cmpiispec 1781066417
muluispec 1813066362
muliispec_basecase 1840827117
muliispec 1883885130

Generated by: LCOV version 1.13