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.18.0 lcov report (development 29806-4d001396c7) Lines: 1467 1530 95.9 %
Date: 2024-12-21 09:08:57 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
sol_ok 3350
ZX_sturm 3736
ZX_graeffe 5369
fft2 7462
roots 8018
ZX_deg1root 15138
_sqrtnr 22595
polrootsbound_i 27198
polrootsbound 27205
RgX_normalize1 35454
ZX_realroots_irred 48125
realroots 50613
ZX_sturm_irred 115950
ZX_sturm_i 119686
split_pols 165286
polsolve 165287
splitcauchy 165293
solve_exact_pol 231040
cleanroots 231306
isexactpol 239296
roots_com 239296
roots_aux 239324
checkvalidpol 266508
QX_complex_roots 289192
_gen_zero 322114
fix_roots1 393221
conformal_mapping 466827
split_1 466828
split_0_1 467150
split_0_2 467150
logradius 492674
split_2 492680
optimize_split 492681
parameters 492681
split_fromU 492681
update_radius 492681
split_0 493003
refine_F 500908
dft 500918
all_roots 528443
clean_roots 528490
fix_roots 529223
a_posteriori_errors 529224
mygprec_special 529232
logpre_modulus 604814
logmodulus 604815
abs_update_r 776180
ZX_sturmpart 875273
ind_maxlog2 900863
check_ab 925887
isexactscalar 930942
usp 939164
isreal 959509
initdft 993600
dual_modulus 1009949
ZX_Uspensky 1057464
fujiwara_bound_real 1147371
tocomplex 1196979
isvalidcoeff 1224434
conformal_basecase 1400590
conformal_pol 1400709
split_complete 1515232
append_clone 1598460
homothetie 1605636
logmin_modulus 1611343
checkbound 1848905
root_error 1892886
ZX_rescale2prim 1934793
fujiwara_bound 2002396
mygprecrc_special 2152488
cmp_complex_appr 2222547
refine_H 2452198
scalepol 4278907
mygprec_absolute 4284676
_mp_mul 4354072
logmax_modulus 4440890
splitpoleval 5183786
bkeval_single_power 5184057
X2XP1 5201503
newton_polygon 5489291
_mp_sqr 6264842
quicktofp 6438812
dblexp 6532299
RgX_gtofp_bit 7003104
abs_update 7988488
mydbllogr 9526315
homothetie2n 9929843
_gen_nored 11098834
eval_rel_pol 13102371
fft 14114323
_gen_one 14340301
ZX_to_ZiX 16461119
pol_to_gaussint 17543292
_mp_add 24546196
_mp_cmul 34552117
myshiftrc 35406908
homothetie_gauss 36415119
findpower 40863710
lower_bound 40863957
graeffe 49390236
mydbllog2r 55810739
mygprec 63485956
ZiX_sqr 98795211
myshiftic 135477954
mygprecrc 214129689
mydbllog2i 223864902
dbllog2 299711534

Generated by: LCOV version 1.16