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 - base2.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.16.1 lcov report (development 28676-df828f1c94) Lines: 2200 2319 94.9 %
Date: 2023-08-26 07:54:43 Functions: 168 172 97.7 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
Decomp 253115
Flx_checkdeflate 1591764
Flx_radical 1591795
FpX_radical 5538
Fp_basis 305658
FqM_to_nfM 9966
FqV_to_nfV 0
FqX_non_root 21
FqX_to_nfX 11549
Fq_to_nf 1463826
QXQV_to_FpM 203
QpXV_denom 505651
QpX_denom 2737177
QpX_remove_denom 1739016
RgV_nffix 28
RgX_nffix 276308
RgX_to_algX 1533
Rg_nffix 833657
Rg_to_ff 9175116
ZX_Dedekind 1529476
ZX_rescale_inv 59665
Z_fac 182
Zlx_gcd 245024
Zlx_sylvester_echelon 4462748
ZpM_hnfmodid 453898
ZpX_disc_val 183678
ZpX_gcd 253112
ZpX_monic_factor 490
ZpX_monic_factor_squarefree 1071
ZpX_primedec 0
ZpX_reduced_resultant 990576
ZpX_reduced_resultant_fast 932021
ZpX_resultant_val 3242893
ZpX_resultant_val_i 3287267
ZpX_round4 770
ZpX_sylvester_echelon 68262
_msqr 11396
_sqr 70327
anti_uniformizer 773880
checkmodpr 210
checkprid 8000876
checkprid_i 9286361
compmod 286056
compositum 91
compositum2 2827
compositum_fix 26469
dbasis 617171
diag_denom 96851
diag_denomval 684012
dim1proj 746390
ei_msqr_mod 343382
errprime 0
expo_is_squarefree 812
fact_from_factors 3500
ffdegree 4151
fill 12696
fix_PE 476
fnz 214206
gen_if_principal 35
get_LV 212671
get_coprimes 273
get_d 2149
get_g 355185
get_gamma 302218
get_maxord 811359
get_modpr 3549
get_module 63
get_norm 505553
get_nu 640181
get_partial_order_as_pols 505652
get_powers 157064
get_pr 409212
get_prid 748216
getprime 561208
ideal_is1 26997
idealprimedec 1142381
idealprimedec_degrees 364
idealprimedec_galois 6587
idealprimedec_kummer 3491156
idealprimedec_limit_f 2554883
idealprimedec_limit_norm 496034
indexpartial 44103
init_m 4174894
init_norm 212654
is_uniformizer 505551
lift_to_zk 89901
loop 238106
manage_cache 705150
maxord 1529433
maxord_disc 711199
maxord_i 454661
minval 15182
mk_pr 3947095
modpr_TAU 3326387
modpr_genFq 4361
modprinit 833119
mul_intersect 699394
mycaract 705266
newtoncharpoly 698637
newtonsums 705276
nfM_to_FqM 5403
nfV_to_FqV 4584
nfXQ_mul 61298
nfX_mul 65680
nfX_rem 61298
nfX_sub 4382
nfX_to_FqX 9709
nfX_to_monic 1547
nf_pV_to_prV 9972
nf_to_Fq 9174613
nf_to_Fq_init 3313492
nfbasis 938
nfcompositum 13346
nfcompositum_lambda 497
nfdisc 66436
nfdiscfactors 644762
nfidealdet1 63
nfmaxord 100165
nfmaxord_check_args 811360
nfmodpr 329
nfmodprinit 7
nfmodprinit0 70
nfmodprlift 77
nfreducemodpr 210
ok_modpr 3870547
p_is_prime 2245
pol_min 116353
polcompositum0 12807
poldiscfactors 42
poldiscfactors_i 787705
pow_ei_mod_p 738079
pr_factorback 3507
pr_factorback_scal 3507
pradical 212674
primedec_aux 2561816
primedec_end 212673
progress 393365
redelt 47947
redelt_i 63367
rnfallbase 2093
rnfbasis 21
rnfdedekind 91
rnfdedekind_i 4417
rnfdet 14
rnfdisc_factored 805
rnfdiscf 77
rnfeltid_powmod 21251
rnfhnfbasis 7
rnfisfree 7
rnfjoinmodules 2176
rnfjoinmodules_i 6348
rnfmaxord 4333
rnfsimplifybasis 0
rnfsteinitz 28
safe_Z_pvalrem 11980
setPE 744881
set_disc 811333
split_char 478990
sqr_mod 822132
testb2 68352
testc2 47946
to_ff_init 3332077
triv_order 953
uniformizer 295304
update_den 3538479
update_fact 1997
update_phi 277491
vstar 621588
zk_to_Fq 3255794
zk_to_Fq_init 18579
zkmodprinit 40658
zx_z_div 1523852

Generated by: LCOV version 1.14