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.1 lcov report (development 28676-df828f1c94) Lines: 1480 1543 95.9 %
Date: 2023-08-26 07:54:43 Functions: 116 119 97.5 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
FFT 56
FFT_i 98
FFTinv 56
QX_complex_roots 271166
RgX_gtofp_bit 4626256
RgX_normalize1 36239
X2XP1 1267154
ZX_Uspensky 181576
ZX_Uspensky_equal 28
ZX_Uspensky_equal_yes 14
ZX_Uspensky_no 21
ZX_deg1root 14055
ZX_graeffe 5306
ZX_realroots_irred 46619
ZX_rescale2prim 412406
ZX_sturm 1414
ZX_sturm_i 115858
ZX_sturm_irred 114444
ZX_sturmpart 3090
ZX_to_ZiX 15700373
ZiX_sqr 58996340
_gen_nored 10470997
_gen_one 13588607
_gen_zero 280494
_intervalcmp 0
_mp_add 23058350
_mp_cmul 32499200
_mp_mul 4135578
_mp_sqr 5981578
_mp_sub 0
_sqrtnr 21603
a_posteriori_errors 290750
abs_update 6141076
abs_update_r 365042
all_roots 289990
append_clone 937852
bkeval_single_power 4883217
check_ab 53503
checkbound 105396
checkvalidpol 47969
clean_roots 290953
cleanroots 11849
cmp_complex_appr 1608338
conformal_basecase 776806
conformal_mapping 258893
conformal_pol 776931
dblexp 4011078
dbllog2 217888084
dft 287202
dual_modulus 582874
eval_rel_pol 8370033
fft 12048859
fft2 7462
findpower 23806082
fix_roots 290751
fix_roots1 180449
fujiwara_bound 844960
fujiwara_bound_real 268510
graeffe 29499908
homothetie 968401
homothetie2n 6169766
homothetie_gauss 21235250
ind_maxlog2 488889
initdft 566661
isexactpol 19790
isexactscalar 58155
isreal 538356
isvalidcoeff 368758
logmax_modulus 2569138
logmin_modulus 924106
logmodulus 393630
logpre_modulus 393628
logradius 279457
lower_bound 23806627
mydbllog2i 154885583
mydbllog2r 40288412
mydbllogr 7056521
mygprec 38883833
mygprec_absolute 2997615
mygprec_special 290757
mygprecrc 162318761
mygprecrc_special 1253415
myshiftic 91157361
myshiftrc 23829888
newton_polygon 3600994
optimize_split 279461
parameters 279460
pol_to_gaussint 10939025
polgraeffe 14
polmod_to_embed 84
polrootsbound 28172
polrootsbound_i 28165
polsolve 163905
quicktofp 3187448
realroots 50413
refine_F 287199
refine_H 1414262
root_error 1180403
roots 7969
roots_aux 19818
roots_com 19790
rootsdeg0 35
scalepol 2391662
scalepol2n 0
sol_ok 3378
solve_exact_pol 11716
split_0 279595
split_0_1 259030
split_0_2 259030
split_1 258895
split_2 279459
split_complete 849937
split_fromU 279461
split_pols 163901
splitcauchy 163905
splitpoleval 4882499
tocomplex 914472
update_radius 279460
usp 229311

Generated by: LCOV version 1.14