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 - base3.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.16.2 lcov report (development 29115-f22e516b23) Lines: 2040 2174 93.8 %
Date: 2024-05-07 08:07:52 Functions: 228 241 94.6 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
idealstar0 0
nfM_ker 0
nfembed 0
oksigns 0
oksigns2 0
sprk_get_AgL2 0
tablemul 0
zidealstar 0
zidealstarinit 0
zidealstarinitgen 0
zkadd 0
zkchinese 0
zksub 0
Q_mod_bid 14
ideallistarch 14
join_archunit 14
nfM_det 14
famatQ_to_famatZ 35
famat_abs 35
famat_cba 35
famat_norm 35
famat_sign 35
join_arch 42
join_bid_arch 42
log_prk_units_init 49
idmulred 56
gideallist 63
idealHNF_norm_pval 63
nfissquare 63
sprk_get_k 63
sprk_to_bid 63
ideallog_units 84
nfV_cxlog 97
idealstarmod 105
to_RgX 105
idealprincipalunits 154
nfinvmodideal 175
famat_zlog_pr_coprime 196
nfdiveuc 259
nfdivrem 259
nfmod 259
zkchinese1init2 259
Idealstarprk 273
nfeltembed 294
nfeltembed_i 294
pr_equal 357
idpowred 413
join_unit 448
rnfeltnorm 462
join_bid 469
join_idealinit 469
veclog_prk 497
ZM_ZMV_mul 518
log_prk_units 518
cxlog_m1 542
nfembed_i 658
pl_convert 775
Idealstar 924
rnfelttrace 1015
num_positive 1268
famat_logembed 1309
RgM_RgX_mul 1365
rnfalgtobasis 1428
nfpolsturm 1596
sprk_log_gen_pr 2037
matbasistoalg 2240
pl_normalize 2247
vecsmall01_to_indices 2247
multable 2520
tablemulvec 2520
isprfact 4192
pr_init 4192
chineseinit_i 4647
nfispower 8083
idealchinese 8392
is_chineseinit 9401
nfM_mul 9924
nfM_inv 10344
_nf_s 10358
ideallist 10563
RgM_to_nfM 10603
mulbytab 10618
ideallist0 11297
Ideallist 11332
tablemul_ei 11347
ideallog 13762
nfchecksigns 14719
gpnfvalrem 15015
scalar_logembed 16681
tablemul_ei_ej 21090
nftrace 21302
cxlog_1 23284
RgX_to_nfX 29090
matalgtobasis 30631
chk_ind 35483
nfdiv 36170
ei_multable 39185
pr_basis_perm 43616
nfsign 43958
rnfbasistoalg 47488
tablesqr 48551
_nf_inv 51201
nfC_multable_mul 55071
principal_units_relations 56616
idmul 70354
ZC_sub1 70454
nfchecksigns_i 80203
setsigns_init 83407
idealfactorback 85149
log_gen_arch 86101
idpow 86116
log_prk_init 90118
nflogembed 99953
sprk_log_gen_pr2 105618
nfeltsign 124061
parse_embed 125944
checkarchp 134088
indices_to_vec01 136809
polmod_nffix 141303
polmod_nffix2 141394
RgC_to_nfC 145892
get_C 163600
sarch_get_lambda 163600
sarch_get_F 163601
sarch_get_MI 163601
principal_units 169063
idealprincipalunits_i 169067
ZC_add1 169664
nfC_nf_mul 192434
nfnorm 194745
nfM_nfC_mul 199439
zkC_multable_mul 204316
check_nfelt 218736
get_nf_field 219721
famat_cxlog 223321
ideallog_units0 226980
nfinv 236551
zidealij 236788
zkchineseinit 237127
zkVchinese1 237369
zkadd1 255301
zkmul 255312
zkchinese1 255341
zksub1 255341
split_U 257382
Idealstarmod 257794
Idealstarmod_i 258070
bid_grp 258361
check_mod_factored 258708
famat_strip2 258745
nfarchstar 259387
nffactorback 265082
join_ideal 268492
_mul 270173
sprk_log_prk1 274139
nfsetsigns 274458
coltoalg 304906
set_sign_mod_divisor 305992
zk_inv 315219
sprk_get_gnf 318446
eltmul 325146
sprk_get_gen 335716
nfpow_u 343732
basistoalg 357732
init_zlog 379922
zlog 381176
sprk_log_prk1_2 402408
log_gen_pr 413449
famat_nfvalrem 420721
sprkinit 425764
eltpow 462165
sarch_get_cyc 486108
order_update 558033
sarch_get_archp 659875
_nf_neg 735590
concat_join 758061
eval_sign 786009
_sqr 807272
eval_sign_embed 882542
nfpow 883903
zk_embed 900807
algtobasis 919015
powp 951496
nfsign_arch 995538
vec01_to_indices 1042235
sprk_get_U2 1202501
sprk_get_L2 1211183
ZC_prdvd 1243663
zkmultable_capZ 1258319
nf_cxlog 1309040
log_prk1 1328590
famat_zlog 1371794
ideallog_i 1381013
ideallogmod 1387691
zkmultable_inv 1573535
ZC_cxlog 1673932
ZMV_ZCV_mul 1752915
nfsub 1803268
ZV_snf_gcd 1952144
famat_zlog_pr 1966597
sprk_get_expo 1966793
init_zlog_mod 1987911
apply_U 2148989
sprk_is_prime 2540288
sprk_get_ff 2540292
sprk_get_pr 2600869
log_prk 2614072
famat_to_nf_modideal_coprime 2618514
_nf_red 3020596
nfsqrmodideal 3077618
nfvalrem 3651027
nf_to_scalar_or_alg 3867976
sprk_get_cyc 3978099
nfmuli 4247741
low_prec 4444156
pol_to_scalar_or_basis 4551614
nfmulpowmodideal 4627898
nfsqri 4701292
zk_scalar_or_multable 4884758
sprk_get_prk 4909560
nfval 5632750
nfpowmodideal 5775424
nfsqri_ZC 7330359
nfmulmodideal 7612868
zk_modHNF 8353542
nfmuli_ZC 8803179
nfsqr 8857979
poltobasis 9704611
ZM_ZX_mul 10301049
zk_multable 10688297
_nf_add 12502657
_nf_mul 14987696
ZC_nfval 21765537
nfadd 23295159
zk_ei_mul 23826142
ZC_nfvalrem 26028884
nfmul 36100209
get_tab 40028629
is_famat 74183790
nf_to_scalar_or_basis 160256974
_mulii 1082704670

Generated by: LCOV version 1.14