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/gmp - mp.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.8.0 lcov report (development 19199-979caa2) Lines: 639 716 89.2 %
Date: 2016-07-24 07:10:30 Functions: 53 54 98.1 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
GEN2mpz 238086133
addiispec 1660749675
adduispec 1304539375
adduispec_offset 327039940
addumului 590578
affir 130082716
cmpiispec 2087386499
convi 481279
diviiexact 319579153
divis 338277
divis_rem 30910398
diviu_rem 123891372
diviuexact 310195763
diviuuexact 506819
divri 17624342
divri_with_gmp 3587011
divrr 106113373
divrr_with_gmp 30940329
dvmdii 811981812
equaliispec 58004512
floorr 386811
icopy_ef 18826252
incloop 32422573
incneg 6184
incpos 32410841
int_normalize 150633642
mantissa2nr 23331175
mpz2GEN 220032220
muliispec 1869961360
muliispec_mirror 60907592
muluispec 2108401994
muluui 529027
pari_gmp_free 341002
pari_gmp_realloc 0
pari_kernel_close 1272
pari_kernel_init 764
red_montgomery 6608768
remi2n 11334239
resetloop 156728
roundr_up_ip 270162865
setloop 2391558
shiftispec 354722176
sqrispec 642461724
sqrispec_mirror 4210646
sqrtr_abs 20911962
sqrtremi 2427771
subiispec 1763962246
subiuspec 1086578081
truncr 1404767
umodiu 779796375
xmpn_copy 1251690
xmpn_mirror 205625174
xmpn_mirrorcopy 267313221
xmpn_zero 55439302

Generated by: LCOV version 1.11