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 - lfun.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.18.1 lcov report (development 30271-60da3cd182) Lines: 1591 1632 97.5 %
Date: 2025-05-11 09:20:26 Functions: 163 163 100.0 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
Rtor 413
Vgaeasytheta 86999
Z_radical 2856
_product 2456
an_msum 239288
antwist 18536
checkconductor 84
checklfuninit 25050
condset 11962
deg1ser_shallow 7511
der_level 2248
derser 126
derservec 63
domain_get_bitprec 36726
domain_get_der 25470
domain_get_dom 84174
fracgammadegree 6349
fracgammaeval 20020
gamma_C 10696
gamma_R 10318
gammafactor 21749
gammafactproduct 20020
gammafrac 1708
gammaordinary 5166
gammavec_expo 91495
gdivvec 9576
get_an 14711353
get_cone 139495
get_cone_fuzz 85550
get_domain 19766
get_eno 5999
ginvsqrtvec 2359
gmulvec 31365
gsubvec 3556
is_dirichlet 9674
is_linit 298942
is_ser 18403
isnegint 20748
ldata_get_an 74200
ldata_get_conductor 271245
ldata_get_degree 26115
ldata_get_dual 59269
ldata_get_gammavec 347620
ldata_get_k 153503
ldata_get_k1 98
ldata_get_k1_dbl 91502
ldata_get_residue 174758
ldata_get_rootno 104664
ldata_get_type 76470
ldata_isreal 2813
lfun 13111
lfun0 6860
lfun_OK 9828
lfun_get_Residue 5151
lfun_get_bitprec 91
lfun_get_dom 59096
lfun_get_domain 84734
lfun_get_expot 19347
lfun_get_factgammavec 9828
lfun_get_k2 49844
lfun_get_pol 31764
lfun_get_step 31764
lfun_get_w2 19347
lfun_init_theta 10696
lfunan 2450
lfuncenterinit 560
lfuncheckfeq 3731
lfuncheckfeq_i 3598
lfunconductor 98
lfuncost 16242
lfuncost0 49
lfunderiv 1624
lfunhardy 19354
lfunhardyzeros 18570
lfuninit 36544
lfuninit0 532
lfuninit_ab 10682
lfuninit_cutoff 11016
lfuninit_make 11788
lfuninit_pol 10836
lfuninit_theta2_worker 22263
lfuninit_worker 56371
lfunlambda 5038
lfunlambda0 1512
lfunlambda_OK 33443
lfunlambdaord 2226
lfunnoinit 224
lfunorderzero 553
lfunp_set 26938
lfunparams2 3598
lfunpoleresidue 5151
lfunprod_get_fact 2575
lfunrootno 5950
lfunrootres 6783
lfunrtoR 21000
lfunrtoR_eno 23121
lfunrtoR_i 23597
lfunrtopoles 4473
lfunser 371
lfunservec 371
lfunspec_OK 38224
lfunsumcoth 4157
lfuntheta 52083
lfunthetacheckinit 62009
lfunthetacost 64564
lfunthetacost0 21
lfunthetainit 336
lfunthetainit0 21000
lfunthetainit_i 10332
lfunthetaspec 420
lfununext 105
lfununextvec 105
lfunzeros 98
lfunzeros_i 98
linit_get_ldata 196563
linit_get_tech 249062
linit_get_type 147000
mkvroots 7875
mulT 320955
mul_an 12879570
mulrealvec 15897
mysercoeff 12017
normalize_simple_pole 6048
normalizepoles 5348
parse_dom 140510
parse_maxcond 98
polepart 8496
polgammaeval 3640
prec_fix 21000
residues_known 8694
rfrac_degree 1799
ropm1 6363
rtoR 4704
sdomain_isincl 24973
ser_coeff0 1232
serextendifnegint 6580
serisscalar 6559
serpole 5089
sersplit1 42
simple_pole 5194
sumVga 103283
sumVgaimpos 26938
theta1 39921
theta2 272971
theta2_i 281047
theta_add_polar_part 6916
theta_dual 9597
theta_get_K 7875
theta_get_R 5991
theta_get_an 52370
theta_get_bitprec 65942
theta_get_isqrtN 62758
theta_get_m 102017
theta_get_tdom 53945
theta_pole_contrib 1918
vecan_cmul 34107774
veccothderivn 8377
vgaell 41891
worker_init 78619
wrap1 6888
wrap2 5032
znchargauss 5502
znchargauss_i 2856

Generated by: LCOV version 1.16