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.10.0 lcov report (development 21703-2e13792) Lines: 1357 1546 87.8 %
Date: 2018-01-17 06:18:31 Functions: 140 151 92.7 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
ZV_lval 0
ZV_lvalrem 0
ZX_lvalrem 0
croak 0
cvstop2 0
gmaxgs 0
gmings 0
is_negative 0
padicaff0 0
z_lvalrem 0
z_pvalrem 0
listcreate_gp 7
listkill 7
sizedigit 7
ctop 14
qtop 14
seridentical 14
identicalrr 21
lexcmp_s_matvec 21
listsort 21
closure_identical 28
gcvtop 28
lexcmp_scal_vecsmall 28
lexcmpgs 28
listpop0 35
mkmap 35
ZX_lval 42
cmpgen 42
lexcmp_vecsmall_mat 42
mklistcopy 49
gpexponent 63
gtolong 77
padic_to_Fl 77
lexcmp_vec_mat 84
intdvd 91
quadtofp 112
rfracrecip_to_ser_absolute 112
matsize 119
map_proto_lGL 126
lexcmp_vecsmall_vec 154
lexcmp_vecsmall_other 182
map_proto_G 182
ZV_Z_dvd 217
lexcmp_scal_matvec 224
rfrac_to_ser 224
minval 231
serequal 315
lexcmpsg 329
list_cmp 336
gtolist 410
cmp_str 476
mklist 729
mklist_typ 771
gaffsg 1008
u_pval 2002
col_test 2023
vecmax 2490
gen_z_divides 2541
vecmax0 2637
gpvaluation 3661
gen_2val 3934
gen_Z_divides 3962
padic_to_Fp 4207
ZX_pval 6363
ZV_pval 6454
gen_pvalrem_DC 6466
vecindexmax 6570
lexcmp_similar 8001
vecmin 8593
vecindexmin 8614
vecmin0 8670
cx_approx_equal 9268
gen_lval 10685
gen_pval 12817
cmpifrac 13146
mat_test 16184
listpop 21910
gequalsg 25417
gcmpsg 26312
listinsert 35014
cmprfrac 35861
z_pval 41841
cvtop 46508
normalizepol_approx 60942
factorial_lval 66525
cmpfrac 83393
ratval 84686
gmin 92203
gequalm1 101198
ZV_pvalrem 106747
normalizepol 107190
gvaluation 198686
gaffect 245878
cvtop2 267814
_domul 279962
gassoc_proto 289669
gen_2valrem 299443
z_lval 347888
RgX_to_ser_inexact 351443
u_pvalrem 383488
Q_pvalrem 425342
ZX_pvalrem 535542
gen_lvalrem 642253
gen_pvalrem 642289
listput0 700049
RgX_to_ser 734645
listput 751051
ensure_nb 786023
polidentical 888322
gequalX 1044050
greffe_aux 1086060
Z_pvalrem_DC 1365164
Q_pval 1392924
cgetp 1546264
polequal 2247788
gequal_try 2272538
lexcmp 2919699
vecequal 3414118
gsigne 3426036
map_proto_lG 3468372
vecidentical 4045223
glength 4532929
roughtype 5839727
normalize 5925457
Z_pvalrem 5963708
Z_pval 6791262
gmax 7832420
Z_lvalrem 8256767
gabs 9271404
u_lval 10041032
Z_lval 10797171
u_lvalrem 12559135
is_monomial_test 13139059
cmp_universal_rec 27347362
gidentical 35875836
gneg_i 39770578
cmp_universal 47888666
gisexactzero 48232795
gexpo 85858782
gexpo_safe 85895133
gequal 131421348
gcmp 146573260
gequal1 153446558
isless_iu 169443177
normalizepol_lg 176782272
gneg 191516638
isexactzero 208685685
isrationalzero 217732163
u_lvalrem_stop 394763941
Z_lvalrem_stop 445253859
gequal0 509081530

Generated by: LCOV version 1.11