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-bordeaux1.fr machine (x86_64 architecture), and agregate them in the final report:

The target is 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 - base4.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.8.0 lcov report (development 17403-69c3b04) Lines: 1339 1413 94.8 %
Date: 2015-01-28 Functions: 124 130 95.4 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 795 944 84.2 %

Function Name Sort by function name Hit count Sort by hit count
RM_round_maxrank 29695
ZM_Q_mul 48662
ZM_famat_limit 58562
_idealmulred 44849
_idealsqrred 65794
_mul 28554
_sqr 65794
addmul_col 56350
addmul_mat 25411
append 99411
check_listpr 756
chk_vdir 21
coprime_part 4144
elt_cmp 19838
elt_egal 5985
err_divexact 7
ext_inv 4469
ext_mul 165521
ext_pow 266
ext_sqr 65780
extideal_HNF_mul 18863
factor_norm 26301
factorbackprime 5894
famat_add 122905
famat_inv 4609
famat_inv_shallow 7
famat_makecoprime 98637
famat_mul 176982
famat_mul_shallow 2905
famat_pow 2863
famat_reduce 7091
famat_sqr 55231
famat_to_Fp_simple 385
famat_to_Fq_simple 0
famat_to_nf 0
famat_to_nf_moddivisor 12572
famatsmall_reduce 8841
get_random_a 165422
gpidealval 42
hnf_QC_QC 7
hnf_Q_Q 21
hnf_Q_QC 28
hnf_Z_QC 21
hnf_Z_ZC 28
idealadd 28091
idealaddmultoone 35
idealaddtoone 2709
idealaddtoone0 70
idealaddtoone_i 182543
idealappr 770
idealappr0 14
idealapprfact 756
idealapprfact_i 17530
idealchinese 1155
idealcoprime 63
idealcoprimefact 5089
idealdiv 15519
idealdiv0 35
idealdivexact 2107
idealdivpowprime 3647
idealfactor 28212
idealfactor_HNF 26301
idealhnf 2562
idealhnf0 119
idealhnf_principal 138423
idealhnf_shallow 275475
idealhnf_two 1287729
idealintersect 21
idealinv 48107
idealinv_HNF 32247
idealinv_HNF_aux 32891
idealmin 7
idealmul 526230
idealmul0 28
idealmul_HNF 349091
idealmul_HNF_two 688257
idealmul_aux 592024
idealmulelt 138505
idealmulpowprime 37296
idealmulred 16295
idealnorm 9687
idealnumden 26329
idealpow 329201
idealpow0 42
idealpow_aux 329201
idealpowprime 233268
idealpowred 53293
idealpows 13468
idealprodprime 0
idealred0 149767
idealsqr 65794
idealtwoelt 14258
idealtwoelt0 63
idealtwoelt2 42
idealtyp 2701159
idealval 347485
init_unif_mod_fZ 21968
isideal 84
make_integral 4417
mat_ideal_two_elt 344116
mat_ideal_two_elt2 21
merge_fact 21
nf_coprime_part 112
nf_get_Gtwist 21
nf_get_Gtwist1 26195
nf_to_Fp_simple 3640
nf_to_Fq_simple 0
nfdivmodpr 588
nfkermodpr 14
nfmulmodpr 595
nfpowmodpr 168
nfsolvemodpr 21
not_in_ideal 14
ok_elt 208447
pidealprimeinv 1727
to_Fp_simple 3444
to_Fq_simple 0
to_famat 770
to_famat_shallow 59998
trivial_merge 28
twistG 26237
ucoprime_part 483784
unif_mod_fZ 31292
unnf_minus_x 172582
val_norm 368578
vec_mulid 7
vecdiv 903
vecinv 0
vecmul 177527
vecpow 15127

Generated by: LCOV version 1.9