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 17110-9967e23) Lines: 1703 1803 94.5 %
Date: 2014-11-26 Functions: 139 147 94.6 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 1031 1256 82.1 %

Function Name Sort by function name Hit count Sort by hit count
RM_round_maxrank 17948
RgV_find_denom 0
ZM_Q_mul 31493
ZM_famat_limit 40618
_idealmulred 30537
_idealsqrred 44417
_mul 19073
_sqr 44417
addmul_col 35440
addmul_mat 14895
append 69267
check_listpr 540
chk_vdir 15
colcomb 28570
colcomb1 34775
coprime_part 2960
element_close 8840
element_mulvecrow 165
elt_cmp 13365
elt_egal 3820
err_divexact 5
ext_inv 3155
ext_mul 113553
ext_pow 190
ext_sqr 44407
extideal_HNF_mul 12420
factor_norm 17067
factorbackprime 2850
famat_add 85394
famat_inv 3255
famat_inv_shallow 5
famat_makecoprime 70227
famat_mul 121209
famat_mul_shallow 1830
famat_pow 1755
famat_reduce 4615
famat_sqr 37002
famat_to_Fp_simple 260
famat_to_Fq_simple 0
famat_to_nf 0
famat_to_nf_moddivisor 8530
famatsmall_reduce 6315
get_random_a 115004
gpidealval 30
hnf_QC_QC 5
hnf_Q_Q 15
hnf_Q_QC 20
hnf_Z_QC 15
hnf_Z_ZC 20
idV_simplify 1485
idealadd 16160
idealaddmultoone 25
idealaddtoone 1755
idealaddtoone0 50
idealaddtoone_i 129004
idealappr 550
idealappr0 10
idealapprfact 540
idealapprfact_i 12122
idealchinese 20
idealcoprime 45
idealcoprimefact 3635
idealdiv 10325
idealdiv0 25
idealdivexact 1225
idealdivpowprime 1555
idealfactor 18032
idealfactor_HNF 17067
idealhnf 1055
idealhnf0 85
idealhnf_principal 88000
idealhnf_shallow 191544
idealhnf_two 903047
idealintersect 15
idealinv 29150
idealinv_HNF 20705
idealinv_HNF_aux 21160
idealmin 5
idealmul 362666
idealmul0 20
idealmul_HNF 240787
idealmul_HNF_two 480744
idealmul_aux 407083
idealmulelt 95611
idealmulpowprime 24795
idealmulred 11464
idealnorm 5735
idealnumden 17087
idealpow 228937
idealpow0 30
idealpow_aux 228937
idealpowprime 163352
idealpowred 36739
idealpows 9210
idealprodprime 0
idealred0 102149
idealsqr 44417
idealtwoelt 8734
idealtwoelt0 45
idealtwoelt2 30
idealtyp 1853699
idealval 236077
init_unif_mod_fZ 15207
isideal 60
make_integral 3155
mat_ideal_two_elt 239440
mat_ideal_two_elt2 15
merge_fact 15
nf_coprime_part 80
nf_get_Gtwist 15
nf_get_Gtwist1 16153
nf_to_Fp_simple 1580
nf_to_Fq_simple 0
nfbezout 16145
nfcleanmod 4070
nfdetint 10
nfdivmodpr 420
nfhnf 1235
nfhnf0 1245
nfhnfmod 275
nfkermodpr 10
nfmulmodpr 425
nfpowmodpr 120
nfreduce 5
nfsnf 0
nfsnf0 15
nfsolvemodpr 15
not_in_ideal 10
ok_elt 142905
pidealprimeinv 870
rowcomb 110
to_Fp_simple 1410
to_Fq_simple 0
to_famat 490
to_famat_shallow 41730
trivial_merge 20
twistG 16183
ucoprime_part 330235
unif_mod_fZ 21642
unnf_minus_x 121854
val_norm 250514
vec_mulid 5
vecdiv 645
vecinv 0
vecmul 125565
vecpow 10805
zero_nfbezout 14455

Generated by: LCOV version 1.9