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 - headers - pariinl.h (source / functions) Hit Total Coverage
Test: PARI/GP v2.8.0 lcov report (development 16962-5a32637) Lines: 1145 1295 88.4 %
Date: 2014-10-29 Functions: 470 540 87.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 497 608 81.7 %

Function Name Sort by function name Hit count Sort by hit count
F2m_clear 0
F2m_coeff 13873601
F2m_copy 1428
F2m_flip 332566
F2m_set 2200727
F2v_clear 1846574
F2v_coeff 81719411
F2v_copy 0
F2v_ei 7
F2v_flip 332566
F2v_set 14436177
F2v_to_F2x 5964
F2x_clear 1846574
F2x_coeff 82313871
F2x_div 933191
F2x_equal 906212
F2x_equal1 1488
F2x_flip 332566
F2x_renormalize 50591580
F2x_set 31790140
Flm_copy 457606
Flv_copy 892717
Flx_copy 36523039
Flx_div 1223415
Flx_equal1 2925475
Flx_lead 63218
Flx_mulu 199984
FlxqX_div 4837
FlxqX_rem 131097
Flxq_add 0
Flxq_sub 0
FpV_FpC_mul 0
FpXQX_div 0
FpXQX_renormalize 549548
FpXQ_add 0
FpXQ_sub 0
FpXX_renormalize 490833
FpX_div 513817
FpX_renormalize 80695683
Fp_add 36472303
Fp_addmul 2327427
Fp_center 2599907
Fp_div 2306277
Fp_halve 15920
Fp_inv 4666769
Fp_invsafe 323262
Fp_mul 23483094
Fp_muls 231
Fp_mulu 16449104
Fp_neg 9206494
Fp_red 2796426
Fp_sqr 2708883
Fp_sub 51925548
FqXQ_add 0
FqXQ_div 16670
FqXQ_inv 0
FqXQ_invsafe 0
FqXQ_mul 105783
FqXQ_pow 0
FqXQ_sqr 38976
FqXQ_sub 0
FqX_Fp_mul 437534
FqX_Fq_mul 462619
FqX_add 763591
FqX_div 7161
FqX_div_by_X_x 5761
FqX_divrem 0
FqX_extgcd 29449
FqX_gcd 34643
FqX_mul 75691
FqX_mulu 386446
FqX_neg 3972
FqX_powu 973
FqX_red 7665
FqX_rem 25024
FqX_sqr 4039
FqX_sub 102927
Fq_red 1236476
GENbinbase 50308574
QV_isscalar 5228439
Q_abs 232963
Q_abs_shallow 28231
RgC_fpnorml2 116284
RgC_gtofp 242725
RgC_gtomp 560
RgM_dimensions 113517
RgM_fpnorml2 546
RgM_gtofp 17422
RgM_gtomp 14
RgM_inv 27045
RgM_minor 231
RgM_shallowcopy 4594088
RgV_is_QV 0
RgV_is_ZV 1260673
RgV_isscalar 6230
RgXQX_div 0
RgXQX_rem 9842
RgXQ_mul 279763
RgXQ_sqr 137044
RgX_coeff 5411
RgX_copy 56845204
RgX_div 6051579
RgX_equal_var 790818
RgX_fpnorml2 8316
RgX_gtofp 375960
RgX_is_QX 5187
RgX_is_ZX 53472405
RgX_is_monomial 14687622
RgX_is_rational 630
RgX_isscalar 0
RgX_rem 1353327
RgX_renormalize 161497
RgX_shift_inplace 472240
RgX_shift_inplace_init 472240
Rg_col_ei 3089983
ZC_hnfrem 780348
ZM_hnfrem 25067
ZM_lll 1076702
ZV_dvd 23198
ZV_isscalar 1188715
ZV_to_zv 192820
ZXQ_mul 86394
ZXQ_sqr 13034
ZX_ZXY_resultant 0
ZX_equal1 12835
ZX_renormalize 69274248
Z_ispower 14
Z_issquare 230040
abgrp_get_cyc 880848
abgrp_get_gen 224495
abgrp_get_no 7798
absfrac 1086418
absfrac_shallow 7651
addmuliu 7000
addmuliu_inplace 232292049
affc_fixlg 26544
affgr 3172046
bid_get_arch 97948
bid_get_cyc 455679
bid_get_gen 4774
bid_get_gen_nocheck 0
bid_get_grp 460971
bid_get_ideal 72262
bid_get_mod 282351
bid_get_no 0
bin_copy 25158259
bit_accuracy 947413761
bit_accuracy_mul 2104010
bit_prec 20529837
bnf_get_clgp 459119
bnf_get_cyc 239286
bnf_get_fu 6160
bnf_get_fu_nocheck 11144
bnf_get_gen 219140
bnf_get_logfu 340070
bnf_get_nf 894242
bnf_get_no 553
bnf_get_reg 357
bnf_get_tuN 7098
bnf_get_tuU 5593
bnr_get_bid 169979
bnr_get_bnf 341715
bnr_get_clgp 194052
bnr_get_cyc 185365
bnr_get_gen 1379
bnr_get_gen_nocheck 63
bnr_get_mod 8939
bnr_get_nf 2079
bnr_get_no 7245
both_odd 42667519
cgetalloc 2563
cgetc 45566
cgiv 38417322
closure_arity 87790874
closure_codestr 76886680
closure_get_code 0
closure_get_data 76880597
closure_get_dbg 6228
closure_get_frame 1022
closure_get_oper 76886680
closure_get_text 13079
closure_is_variadic 10899812
col_ei 1088686
const_col 14789
const_vec 5405906
const_vecsmall 3054653
constant_term 17399849
cxcompotor 1127695
cxnorm 5281272
cxtofp 562998
cyclic_perm 0
dbllog2r 12776225
degpol 1275399034
divsBIL 2747825681
ellQp_get_p 245
ellQp_get_prec 84
ellQp_get_zero 336
ellR_get_prec 245
ellR_get_sign 569
ell_get_a1 1961089
ell_get_a2 1408124
ell_get_a3 1977861
ell_get_a4 2021471
ell_get_a6 2431769
ell_get_b2 2002351
ell_get_b4 432664
ell_get_b6 823957
ell_get_b8 687932
ell_get_c4 4706951
ell_get_c6 5066618
ell_get_disc 6273225
ell_get_j 897400
ell_get_type 6722202
ell_is_inf 20725361
ellff_get_a4a6 255990
ellff_get_field 593467
ellinf 398091
ellnf_get_nf 49035
equali1 158284519
equalim1 55364
err_get_compo 77
err_get_num 26499
gabsz 0
gaddgs 1380586
gaddz 23318
gal_get_den 1512
gal_get_e 42
gal_get_gen 875
gal_get_group 791
gal_get_invvdm 1512
gal_get_mod 1498
gal_get_orders 413
gal_get_p 924
gal_get_pol 868
gal_get_roots 1855
gcmpgs 9709
gdiventz 0
gdivsg 96015
gdivz 0
gen_I 164100
gener_Fq_local 385
gequalgs 22435
gerepileall 3799573
gerepilecoeffs 8
gerepilecopy 18652197
gerepilemany 35784
gerepileupto 363091533
gerepileuptoint 873644698
gerepileuptoleaf 201301971
gmaxsg 0
gminsg 0
gmodz 0
gmul2nz 0
gmulgs 2081558
gmulz 11673
gnegz 0
gshiftz 0
gsubgs 376860
gsubz 0
gtodouble 5086636
gtofp 6586832
gtomp 22400
gtos 28091132
gtou 0
gval 413
icopy_avma 764032055
idealpseudomin 140013
idealpseudomin_nonscalar 219699
idealred 139265
idealred_elt 308
identity_perm 63623
inf_get_sign 10798
is_bigint 109400015
is_const_t 541873087
is_extscalar_t 545413
is_intreal_t 500036
is_matvec_t 291241717
is_noncalc_t 49540394
is_pm1 708225276
is_rational_t 108503
is_recursive_t 1788324921
is_scalar_t 148528297
is_universal_constant 18155748
is_vec_t 716515
isint1 3985824
isintm1 0
isintzero 250358393
ismpzero 499959
isonstack 1476465795
killblock 949552
leading_term 58061454
leafcopy_avma 42150812
lgcols 19249184
lgpol 531023710
lincombii 13111624
matpascal 273
mkcol 604953
mkcol2 11579612
mkcol2s 0
mkcol3 40341
mkcol3s 0
mkcol4 0
mkcol4s 0
mkcol5 0
mkcolcopy 25737
mkcols 0
mkcomplex 2902411
mkerr 0
mkfrac 37416
mkfraccopy 1366286
mkintmod 364144
mkintmodu 3514
mkmat 183996
mkmat2 8661100
mkmat3 2996
mkmat4 0
mkmat5 0
mkmatcopy 5103
mkmoo 3353
mkoo 5574
mkpolmod 63098
mkqfi 158109
mkquad 42
mkrfrac 7
mkrfraccopy 14
mkvec 1622519
mkvec2 9904051
mkvec2copy 162481
mkvec2s 8617
mkvec3 19629993
mkvec3s 492492
mkvec4 3586738
mkvec4s 7
mkvec5 11535296
mkveccopy 32830
mkvecs 7
mkvecsmall 22167402
mkvecsmall2 89822904
mkvecsmall3 31567926
mkvecsmall4 405521
mkvecsmall5 189
mpcosz 0
mpexpz 0
mplogz 0
mpsinz 0
mul_content 195410
mul_denom 154755
mulsubii 1267909
nbits2extraprec 208048173
nbits2lg 2359358
nbits2nlong 738236
nbits2prec 66094645
nbrows 11145131
nchar2nlong 8404615
ndec2nlong 12053
ndec2prec 12053
nf_get_G 34922
nf_get_M 853288
nf_get_Tr 784
nf_get_degree 2375980
nf_get_diff 777
nf_get_disc 17178
nf_get_index 414763
nf_get_invzk 1002398
nf_get_pol 5173965
nf_get_r1 916465
nf_get_r2 259
nf_get_roots 37608
nf_get_roundG 321459
nf_get_sign 3500
nf_get_varn 3185
nf_get_zk 5309497
normalize_frac 3911172
odd 159585894
pari_calloc 20991
pari_err_BUG 14
pari_err_COMPONENT 203
pari_err_CONSTPOL 7
pari_err_COPRIME 42
pari_err_DIM 191
pari_err_DOMAIN 1220
pari_err_FILE 0
pari_err_FLAG 7
pari_err_IMPL 119
pari_err_INV 644
pari_err_IRREDPOL 14
pari_err_MAXPRIME 0
pari_err_MODULUS 707
pari_err_OP 308
pari_err_OVERFLOW 57
pari_err_PACKAGE 0
pari_err_PREC 218
pari_err_PRIME 35
pari_err_PRIORITY 63
pari_err_ROOTS0 35
pari_err_SQRTN 70
pari_err_TYPE 10476
pari_err_TYPE2 2786
pari_err_VAR 490
pari_free 33278828
pari_malloc 100869374
pari_realloc 58893
pari_stack_alloc 211519357
pari_stack_base 211544557
pari_stack_delete 19055
pari_stack_init 24027
pari_stack_new 185159308
pari_stack_pushp 6145
perm_conj 35
perm_inv 56
perm_mul 17719150
pol0_F2x 1708768
pol0_Flx 20569552
pol1_F2x 510479
pol1_Flx 9300171
pol_0 10494554
pol_1 574506
pol_x 289529
polx_F2x 168304
polx_Flx 5242761
polx_zx 0
powIs 805
powii 298416
pr_get_e 1115101
pr_get_f 3579329
pr_get_gen 1645960
pr_get_p 5046745
pr_get_tau 2195359
pr_is_inert 468211
pr_norm 65897
prec2nbits 40493304
prec2nbits_mul 47985
prec2ndec 3646
precdbl 1551
qfb_disc 3716181
qfb_disc3 3786475
quad_disc 175
quadnorm 623
remsBIL 2678261041
resultant 24507
rnf_get_absdegree 182
rnf_get_degree 917
rnf_get_disc 140
rnf_get_index 105
rnf_get_invzk 1057
rnf_get_map 1344
rnf_get_nf 4942
rnf_get_nfdegree 539
rnf_get_nfpol 4634
rnf_get_nfvarn 56
rnf_get_nfzk 735
rnf_get_pol 7077
rnf_get_polabs 1820
rnf_get_varn 0
rnf_get_zk 1925
row 113035
row_Flm 23670
row_i 1953
row_zm 0
rowcopy 21
rowpermute 132583
rowslice 91802
rowslicepermute 18238
ser_isexactzero 609491
shallowcopy 184099
sqrfrac 123564
sqrti 2438652
sqrtnr 26691
sqrtr 6175747
sturm 0
submulii 35199583
submuliu 7000
submuliu_inplace 232566793
truecoeff 0
trunc_safe 0
vec_append 54894
vec_ei 296381
vec_lengthen 7574
vec_setconst 1687
vec_shorten 0
vec_to_vecsmall 200520
vecpermute 4185946
vecreverse 1106
vecreverse_inplace 218
vecslice 1598556
vecslicepermute 81136
vecsmall_append 353430
vecsmall_coincidence 0
vecsmall_concat 192388
vecsmall_copy 20996946
vecsmall_ei 7140
vecsmall_indexmax 14
vecsmall_indexmin 14
vecsmall_isin 0
vecsmall_lengthen 448
vecsmall_lexcmp 2586374
vecsmall_max 1638
vecsmall_min 0
vecsmall_pack 84
vecsmall_prefixcmp 35286195
vecsmall_prepend 742
vecsmall_shorten 4466
vecsmall_to_col 418125
vecsmall_to_vec 5452
vecsmallpermute 17412298
vecsmalltrunc_append 2226134
vecsmalltrunc_init 1186404
vecsplice 3591
vectrunc_append 807008
vectrunc_append_batch 0
vectrunc_init 545729
zc_to_ZC 399631
zero_F2m 0
zero_F2m_copy 92172
zero_F2v 731555
zero_F2x 77
zero_Flm 133
zero_Flm_copy 11536
zero_Flv 17959901
zero_Flx 46023
zero_zm 0
zero_zv 12505428
zero_zx 0
zerocol 19382780
zeromat 5159
zeromatcopy 1799424
zeropadic 10780
zeropadic_shallow 315
zeropol 3970539
zeroser 7143
zerovec 5457730
zm_copy 0
zm_to_zxV 0
zm_transpose 91
zv_copy 725248
zv_to_ZV 4263
zv_to_zx 0
zx_renormalize 0
zx_shift 0
zx_to_zv 0

Generated by: LCOV version 1.9