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 - basemath - gen2.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.8.0 lcov report (development 19378-5335519) Lines: 1324 1531 86.5 %
Date: 2016-08-31 06:11:49 Functions: 134 145 92.4 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
Q_pval 1523339
Q_pvalrem 160023
RgX_to_ser 928150
RgX_to_ser_inexact 334993
ZV_Z_dvd 49
ZV_lval 0
ZV_lvalrem 0
ZV_pval 4235
ZV_pvalrem 3430
ZX_lval 28
ZX_lvalrem 0
ZX_pval 6307
ZX_pvalrem 522830
Z_lval 10660308
Z_lvalrem 6801583
Z_lvalrem_stop 478100633
Z_pval 6659634
Z_pvalrem 4549185
Z_pvalrem_DC 1368273
_domul 70390
cgetp 1016969
closure_identical 28
cmp_str 476
cmp_universal 46141732
cmp_universal_rec 25932221
cmpfrac 51261
cmpgen 42
cmpifrac 16486
cmprfrac 35840
col_test 84
croak 0
ctop 14
cvstop2 0
cvtop 29043
cvtop2 196325
ensure_nb 786023
factorial_lval 64642
gabs 7950326
gaffect 246200
gaffsg 980
gassoc_proto 103863
gcmp 150214573
gcmpsg 24408
gcvtop 21
gen_2val 588
gen_2valrem 266413
gen_Z_divides 3836
gen_lval 8396
gen_lvalrem 526224
gen_pval 10542
gen_pvalrem 526260
gen_pvalrem_DC 6305
gen_z_divides 2492
gequal 52989089
gequal0 395420036
gequal1 143422200
gequalX 173674
gequal_try 1719710
gequalm1 1188065
gequalsg 22960
gexpo 65345720
gidentical 34936278
gisexactzero 43267028
glength 4357852
gmax 7830131
gmaxgs 0
gmin 89651
gmings 0
gneg 190430449
gneg_i 38609373
gpvaluation 3605
greffe_aux 1263122
gsigne 3007362
gtolist 410
gtolong 77
gvaluation 12285
identicalrr 21
intdvd 91
is_monomial_test 13073815
is_negative 0
isexactzero 197033661
isless_iu 170315345
isrationalzero 275894528
lexcmp 87075
lexcmp_s_matvec 21
lexcmp_scal_matvec 224
lexcmp_scal_vecsmall 28
lexcmp_similar 29401
lexcmp_vec_mat 84
lexcmp_vecsmall_mat 42
lexcmp_vecsmall_other 182
lexcmp_vecsmall_vec 154
lexcmpgs 28
lexcmpsg 329
list_cmp 336
listcreate 687
listcreate_typ 729
listinsert 35014
listkill 7
listpop 21910
listpop0 35
listput 751051
listput0 700049
listsort 21
map_proto_G 182
map_proto_lG 3552714
map_proto_lGL 126
mat_test 98
matsize 112
minval 224
mklistcopy 49
normalize 5597447
normalizepol 90263
normalizepol_approx 665
normalizepol_lg 165863763
padic_to_Fl 77
padic_to_Fp 56
padicaff0 0
polequal 339603
polidentical 763356
qtop 14
quadtofp 112
ratval 57246
rfrac_to_ser 133
roughtype 174479
serequal 294
seridentical 14
sizedigit 7
u_lval 7482710
u_lvalrem 9902410
u_lvalrem_stop 414768664
u_pval 1036
u_pvalrem 376089
vecequal 608485
vecidentical 3649380
vecindexmax 5702
vecindexmin 5548
vecmax 1608
vecmax0 1748
vecmin 5520
vecmin0 5590
z_lval 157007
z_lvalrem 0
z_pval 2093
z_pvalrem 0

Generated by: LCOV version 1.11