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 - basemath - rootpol.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.16.2 lcov report (development 29115-f22e516b23) Lines: 1480 1543 95.9 %
Date: 2024-05-07 08:07:52 Functions: 116 119 97.5 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
_intervalcmp 0
_mp_sub 0
scalepol2n 0
ZX_Uspensky_equal_yes 14
polgraeffe 14
ZX_Uspensky_no 21
ZX_Uspensky_equal 28
rootsdeg0 42
FFT 56
FFTinv 56
polmod_to_embed 84
FFT_i 98
ZX_sturm 1414
ZX_sturmpart 3074
sol_ok 3399
ZX_graeffe 5306
fft2 7462
roots 7913
ZX_deg1root 14443
_sqrtnr 22216
polrootsbound_i 26978
polrootsbound 26985
RgX_normalize1 35234
ZX_realroots_irred 47414
realroots 50536
check_ab 53610
checkbound 105596
ZX_sturm_irred 114676
ZX_sturm_i 116090
split_pols 164779
polsolve 164792
splitcauchy 164796
ZX_Uspensky 182111
solve_exact_pol 212597
cleanroots 212968
isexactpol 220853
roots_com 220853
roots_aux 220881
usp 229460
checkvalidpol 247845
fujiwara_bound_real 269192
QX_complex_roots 289032
_gen_zero 321025
fix_roots1 375324
ZX_rescale2prim 415687
conformal_mapping 445723
split_1 445724
split_0_1 446044
split_0_2 446044
parameters 470704
split_2 470706
logradius 470707
optimize_split 470708
split_fromU 470708
update_radius 470708
split_0 471027
refine_F 478697
dft 478703
all_roots 509841
clean_roots 509882
fix_roots 510650
a_posteriori_errors 510653
mygprec_special 510653
logmodulus 581034
logpre_modulus 581037
abs_update_r 736082
isexactscalar 858319
ind_maxlog2 858600
isreal 916429
initdft 949408
dual_modulus 965470
fujiwara_bound 1097581
isvalidcoeff 1148238
tocomplex 1174089
X2XP1 1276920
conformal_basecase 1337283
conformal_pol 1337400
split_complete 1452702
append_clone 1536762
homothetie 1537549
logmin_modulus 1541472
root_error 1828513
mygprecrc_special 2072196
cmp_complex_appr 2152083
refine_H 2355157
quicktofp 4052101
scalepol 4086355
mygprec_absolute 4173747
logmax_modulus 4251385
_mp_mul 4316887
splitpoleval 5166433
bkeval_single_power 5166827
newton_polygon 5275119
_mp_sqr 6228112
dblexp 6260040
RgX_gtofp_bit 6737963
abs_update 7726365
mydbllogr 9198457
homothetie2n 9526132
_gen_nored 11045753
eval_rel_pol 12577766
fft 13730412
_gen_one 14285043
ZX_to_ZiX 16187214
pol_to_gaussint 16829296
_mp_add 24369635
myshiftrc 34081367
_mp_cmul 34332115
homothetie_gauss 34873277
lower_bound 39132073
findpower 39132320
graeffe 47326064
mydbllog2r 52747421
mygprec 61049593
ZiX_sqr 94671562
myshiftic 130480241
mygprecrc 207542823
mydbllog2i 215832718
dbllog2 290586080

Generated by: LCOV version 1.14