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-04-18 08:07:12 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 114675
ZX_sturm_i 116089
split_pols 164782
polsolve 164785
splitcauchy 164799
ZX_Uspensky 182108
solve_exact_pol 212597
cleanroots 212968
isexactpol 220853
roots_com 220853
roots_aux 220881
usp 229452
checkvalidpol 247845
fujiwara_bound_real 269190
QX_complex_roots 289031
_gen_zero 321031
fix_roots1 375326
ZX_rescale2prim 415675
conformal_mapping 445738
split_1 445738
split_0_1 446061
split_0_2 446062
split_2 470709
logradius 470710
parameters 470710
update_radius 470712
optimize_split 470713
split_fromU 470713
split_0 471034
refine_F 478703
dft 478706
all_roots 509838
clean_roots 509886
a_posteriori_errors 510647
fix_roots 510649
mygprec_special 510656
logpre_modulus 581032
logmodulus 581036
abs_update_r 736066
isexactscalar 858319
ind_maxlog2 858597
isreal 916451
initdft 949417
dual_modulus 965460
fujiwara_bound 1097577
isvalidcoeff 1148238
tocomplex 1174101
X2XP1 1276907
conformal_basecase 1337330
conformal_pol 1337449
split_complete 1452717
append_clone 1536750
homothetie 1537557
logmin_modulus 1541535
root_error 1828531
mygprecrc_special 2072214
cmp_complex_appr 2152116
refine_H 2355185
quicktofp 4052092
scalepol 4086461
mygprec_absolute 4173813
logmax_modulus 4251582
_mp_mul 4316987
splitpoleval 5166685
bkeval_single_power 5166927
newton_polygon 5275125
_mp_sqr 6228184
dblexp 6260207
RgX_gtofp_bit 6738025
abs_update 7726889
mydbllogr 9198981
homothetie2n 9526317
_gen_nored 11047018
eval_rel_pol 12577846
fft 13732060
_gen_one 14287433
ZX_to_ZiX 16189069
pol_to_gaussint 16829525
_mp_add 24371084
myshiftrc 34083161
_mp_cmul 34335799
homothetie_gauss 34874537
lower_bound 39133660
findpower 39134547
graeffe 47327595
mydbllog2r 52749391
mygprec 61050753
ZiX_sqr 94676292
myshiftic 130490891
mygprecrc 207550921
mydbllog2i 215847473
dbllog2 290610652

Generated by: LCOV version 1.14