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.17.0 lcov report (development 29540-a31209ca65) Lines: 2213 2338 94.7 %
Date: 2024-09-18 09:02:58 Functions: 168 172 97.7 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
FqV_to_nfV 0
ZpX_primedec 0
errprime 0
rnfsimplifybasis 0
nfmodprinit 7
rnfhnfbasis 7
rnfisfree 7
rnfdet 14
FqX_non_root 21
rnfbasis 21
rnfsteinitz 28
gen_if_principal 35
poldiscfactors 42
RgV_nffix 49
get_module 63
nfidealdet1 63
nfmodprinit0 70
nfmodprlift 77
rnfdiscf 77
compositum 91
rnfdedekind 91
Z_fac 183
QXQV_to_FpM 203
checkmodpr 210
nfreducemodpr 210
get_coprimes 273
nfmodpr 329
idealprimedec_degrees 371
fix_PE 477
ZpX_monic_factor 490
nfcompositum_lambda 497
ZpX_round4 770
expo_is_squarefree 812
rnfdisc_factored 854
nfbasis 938
triv_order 1016
ZpX_monic_factor_squarefree 1071
RgX_to_algX 1638
nfX_to_monic 1652
update_fact 2083
p_is_prime 2154
rnfjoinmodules 2218
rnfallbase 2219
get_d 2275
compositum2 2835
fact_from_factors 3591
pr_factorback 3605
pr_factorback_scal 3605
ffdegree 4109
modpr_genFq 4326
rnfmaxord 4445
nfX_sub 4494
rnfdedekind_i 4529
FpX_radical 5502
nfM_to_FqM 5627
rnfjoinmodules_i 6537
idealprimedec_galois 6552
nfX_to_FqX 10108
FqM_to_nfM 10316
_msqr 11137
FqX_to_nfX 11815
safe_Z_pvalrem 12306
polcompositum0 12793
fill 13074
nfcompositum 13332
minval 15686
zk_to_Fq_init 18711
rnfeltid_powmod 21818
compositum_fix 26440
ideal_is1 27788
nf_pV_to_prV 38535
indexpartial 44066
redelt 48135
testc2 48135
ZX_rescale_inv 59832
nfXQ_mul 62166
nfX_rem 62166
redelt_i 63661
nfdisc 66409
nfX_mul 66660
testb2 66770
_sqr 70432
ZpX_sylvester_echelon 72982
lift_to_zk 91321
diag_denom 97575
nfmaxord 100756
pol_min 116645
get_modpr 137746
get_powers 158108
nfV_to_FqV 167403
zkmodprinit 174949
ZpX_disc_val 182220
init_norm 213231
pradical 213260
get_LV 213262
primedec_end 213262
fnz 215933
loop 237037
Zlx_gcd 244809
Decomp 252991
ZpX_gcd 252998
update_phi 275123
RgX_nffix 279529
compmod 285167
uniformizer 295175
get_gamma 299881
Fp_basis 305511
ei_msqr_mod 343968
get_g 352944
progress 392025
get_pr 409406
ZpM_hnfmodid 451656
maxord_i 452433
split_char 475800
is_uniformizer 500649
get_norm 500655
idealprimedec_limit_norm 505216
get_partial_order_as_pols 505418
QpXV_denom 505421
getprime 558868
dbasis 617591
vstar 619407
get_nu 636014
nfdiscfactors 644760
diag_denomval 685132
newtoncharpoly 693356
mul_intersect 698451
manage_cache 700049
mycaract 700092
newtonsums 700112
maxord_disc 711165
pow_ei_mod_p 734782
setPE 745485
poldiscfactors_i 788142
set_disc 811901
get_maxord 811927
nfmaxord_check_args 811927
sqr_mod 815728
Rg_nffix 842602
ZpX_reduced_resultant_fast 927115
get_prid 936572
anti_uniformizer 964003
ZpX_reduced_resultant 986705
dim1proj 1029608
modprinit 1157663
idealprimedec 1270206
zx_z_div 1525573
ZX_Dedekind 1531096
maxord 1531096
Flx_radical 1593548
Flx_checkdeflate 1593572
QpX_remove_denom 1730186
idealprimedec_limit_f 2695521
primedec_aux 2702431
QpX_denom 2725757
Fq_to_nf 3234925
ZpX_resultant_val 3442770
ZpX_resultant_val_i 3486898
nf_to_Fq_init 3510960
modpr_TAU 3523894
update_den 3528238
to_ff_init 3529693
idealprimedec_kummer 3794706
mk_pr 4249045
ok_modpr 4361989
init_m 4369820
Zlx_sylvester_echelon 4653659
zk_to_Fq 7112568
nf_to_Fq 15167387
Rg_to_ff 15167886
checkprid 17887754
checkprid_i 22825521

Generated by: LCOV version 1.16