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 17566-be4cfd0) Lines: 1173 1315 89.2 %
Date: 2015-02-26 Functions: 484 550 88.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 514 620 82.9 %

Function Name Sort by function name Hit count Sort by hit count
F2m_clear 0
F2m_coeff 10257920
F2m_copy 1449
F2m_flip 336311
F2m_set 1381617
F2v_clear 2094960
F2v_coeff 79996915
F2v_copy 0
F2v_ei 7
F2v_flip 336311
F2v_set 12362157
F2v_to_F2x 6015
F2x_clear 2094960
F2x_coeff 81587272
F2x_div 1134858
F2x_equal 1105884
F2x_equal1 1530
F2x_flip 336311
F2x_renormalize 55221051
F2x_set 31097978
Flm_copy 473420
Flv_copy 1025651
Flx_copy 45640487
Flx_div 1502105
Flx_equal1 3738361
Flx_lead 349187
Flx_mulu 200026
FlxqX_div 6146
FlxqX_rem 161241
Flxq_add 0
Flxq_sub 0
FpV_FpC_mul 0
FpXQX_div 0
FpXQX_renormalize 826233
FpXQ_add 0
FpXQ_sub 0
FpXX_renormalize 872964
FpX_div 518710
FpX_renormalize 90301641
Fp_add 172271238
Fp_addmul 2376490
Fp_center 3087369
Fp_div 3606766
Fp_halve 16306
Fp_inv 6566851
Fp_invsafe 342122
Fp_mul 146300924
Fp_muls 231
Fp_mulu 48970140
Fp_neg 9605250
Fp_red 2900653
Fp_sqr 4539622
Fp_sub 58290705
FqXQ_add 0
FqXQ_div 16852
FqXQ_inv 0
FqXQ_invsafe 0
FqXQ_mul 107547
FqXQ_pow 0
FqXQ_sqr 39900
FqXQ_sub 0
FqX_Fp_mul 452339
FqX_Fq_mul 467870
FqX_add 768895
FqX_div 9611
FqX_div_by_X_x 5831
FqX_divrem 0
FqX_extgcd 37184
FqX_gcd 38262
FqX_mul 82915
FqX_mulu 389710
FqX_neg 4028
FqX_powu 994
FqX_red 7854
FqX_rem 26252
FqX_sqr 4270
FqX_sub 104264
Fq_red 1532674
Fq_to_FpXQ 3614
GENbinbase 54093258
QV_isscalar 5463675
Q_abs 312902
Q_abs_shallow 37838
RgC_fpnorml2 242522
RgC_gtofp 379113
RgC_gtomp 560
RgM_dimensions 115445
RgM_fpnorml2 1498
RgM_gtofp 18934
RgM_gtomp 14
RgM_inv 29853
RgM_minor 504
RgM_shallowcopy 4837133
RgV_is_QV 0
RgV_is_ZV 1274559
RgV_isscalar 6385
RgXQX_div 7
RgXQX_rem 31668
RgXQ_mul 382725
RgXQ_sqr 191238
RgX_coeff 5425
RgX_copy 62211511
RgX_div 6054231
RgX_equal_var 4074292
RgX_fpnorml2 10204
RgX_gtofp 421666
RgX_is_QX 109326
RgX_is_ZX 55040644
RgX_is_monomial 14648061
RgX_is_rational 2408
RgX_isscalar 0
RgX_rem 2404437
RgX_renormalize 171017
RgX_shift_inplace 512826
RgX_shift_inplace_init 512824
Rg_col_ei 3276559
ZC_hnfrem 801009
ZM_hnfrem 26138
ZM_lll 1132051
ZV_dvd 23198
ZV_isscalar 1566268
ZV_to_zv 192939
ZXQ_mul 104524
ZXQ_sqr 17556
ZX_ZXY_resultant 0
ZX_equal1 12694
ZX_renormalize 77237043
Z_ispower 14
Z_issquare 231339
abgrp_get_cyc 892335
abgrp_get_gen 227568
abgrp_get_no 7994
absfrac 1326215
absfrac_shallow 11564
addmuliu 7000
addmuliu_inplace 263743361
affc_fixlg 26558
affgr 3173038
bid_get_arch 98487
bid_get_cyc 461384
bid_get_gen 4984
bid_get_gen_nocheck 0
bid_get_grp 466886
bid_get_ideal 72892
bid_get_mod 287293
bid_get_no 0
bin_copy 27047607
bit_accuracy 1089722937
bit_accuracy_mul 2501755
bit_prec 23574437
bnf_get_clgp 465216
bnf_get_cyc 242527
bnf_get_fu 6733
bnf_get_fu_nocheck 12067
bnf_get_gen 221996
bnf_get_logfu 347063
bnf_get_nf 927920
bnf_get_no 553
bnf_get_reg 601
bnf_get_tuN 7567
bnf_get_tuU 6034
bnr_get_bid 172086
bnr_get_bnf 345985
bnr_get_clgp 196810
bnr_get_cyc 187906
bnr_get_gen 1393
bnr_get_gen_nocheck 70
bnr_get_mod 9149
bnr_get_nf 2219
bnr_get_no 7441
both_odd 15895005
cbrtr 11341
cgetalloc 4651
cgetc 47633
cgiv 42536546
closure_arity 104519614
closure_codestr 92797888
closure_get_code 0
closure_get_data 92723983
closure_get_dbg 57847
closure_get_frame 10183
closure_get_oper 92761827
closure_get_text 117395
closure_is_variadic 11769862
col_ei 1167975
const_col 19626
const_vec 5709952
const_vecsmall 3229269
constant_term 17427172
cxcompotor 1365425
cxnorm 6963264
cxtofp 681597
cyclic_perm 0
dbllog2r 20177361
degpol 1473955784
divsBIL 3196658697
ellQp_get_p 245
ellQp_get_prec 84
ellQp_get_zero 336
ellR_get_prec 245
ellR_get_sign 660
ell_get_a1 1966828
ell_get_a2 1409604
ell_get_a3 1982606
ell_get_a4 2022370
ell_get_a6 2432199
ell_get_b2 2006050
ell_get_b4 433588
ell_get_b6 824930
ell_get_b8 688457
ell_get_c4 4710363
ell_get_c6 5069855
ell_get_disc 6276784
ell_get_j 897393
ell_get_type 6739204
ell_is_inf 16990632
ellff_get_a4a6 258639
ellff_get_field 603354
ellinf 402644
ellnf_get_nf 52885
equali1 169357746
equalim1 5707133
err_get_compo 77
err_get_num 129825
gabsz 0
gaddgs 1396620
gaddz 23318
gal_get_den 1631
gal_get_e 42
gal_get_gen 875
gal_get_group 840
gal_get_invvdm 1631
gal_get_mod 1617
gal_get_orders 413
gal_get_p 924
gal_get_pol 917
gal_get_roots 1974
gcmpgs 23750
gdiventz 0
gdivsg 98068
gdivz 0
gen_I 165445
gener_Fq_local 462
gequalgs 22435
gerepileall 4175139
gerepilecoeffs 8
gerepilecopy 19559979
gerepilemany 37056
gerepileupto 418569475
gerepileuptoint 995831267
gerepileuptoleaf 315450013
gmaxsg 0
gminsg 0
gmodz 0
gmul2nz 0
gmulgs 2679480
gmulz 11673
gnegz 0
gshiftz 0
gsubgs 392068
gsubz 0
gtodouble 24435619
gtofp 11875445
gtomp 22400
gtos 29750479
gtou 0
gval 427
icopy_avma 950187514
idealpseudomin 149488
idealpseudomin_nonscalar 230279
idealred 148705
idealred_elt 315
identity_perm 64470
inf_get_sign 17572
is_bigint 114575510
is_const_t 662801478
is_extscalar_t 591132
is_intreal_t 515952
is_matvec_t 301427137
is_noncalc_t 50325592
is_pm1 1104301230
is_rational_t 412920
is_recursive_t 2017544638
is_scalar_t 150293226
is_universal_constant 28969385
is_vec_t 267769
isint1 5008857
isintm1 301
isintzero 257354882
ismpzero 515875
isonstack 1772317332
killblock 967439
leading_term 63756471
leafcopy_avma 47395745
lgcols 23913432
lgpol 707999469
lincombii 17976984
matpascal 273
mkcol 622508
mkcol2 12816457
mkcol2s 0
mkcol3 40369
mkcol3s 0
mkcol4 0
mkcol4s 0
mkcol5 0
mkcol6 337
mkcolcopy 27232
mkcols 0
mkcomplex 2983160
mkerr 0
mkfrac 43293
mkfraccopy 2325050
mkintmod 378893
mkintmodu 3675
mkmat 186485
mkmat2 9924411
mkmat3 2345
mkmat4 0
mkmat5 0
mkmatcopy 7203
mkmoo 5403
mkoo 8758
mkpolmod 238917
mkqfi 158109
mkquad 42
mkrfrac 7
mkrfraccopy 14
mkvec 2399967
mkvec2 11003596
mkvec2copy 167444
mkvec2s 10395
mkvec3 64555120
mkvec3s 492702
mkvec4 3587991
mkvec4s 7
mkvec5 11480588
mkveccopy 33180
mkvecs 7
mkvecsmall 29031078
mkvecsmall2 91806612
mkvecsmall3 35557293
mkvecsmall4 1480943
mkvecsmall5 104716
modpr_get_T 763361
modpr_get_p 2331
modpr_get_pr 1709061
mpcosz 0
mpexpz 0
mplogz 0
mpsinz 0
mul_content 238621
mul_denom 176809
mulsubii 1721663
nbits2extraprec 306971626
nbits2lg 2631508
nbits2nlong 678711
nbits2prec 81098220
nbrows 12650604
nchar2nlong 8502215
ndec2nlong 14035
ndec2prec 14035
nf_get_G 42239
nf_get_M 876961
nf_get_Tr 784
nf_get_degree 2590687
nf_get_diff 798
nf_get_disc 20533
nf_get_index 488077
nf_get_invzk 1085150
nf_get_pol 5688635
nf_get_r1 966823
nf_get_r2 1043
nf_get_ramified_primes 7
nf_get_roots 86051
nf_get_roundG 337628
nf_get_sign 3888
nf_get_varn 4325
nf_get_zk 5563508
normalize_frac 5878965
odd 199612355
pari_calloc 35089
pari_err_BUG 14
pari_err_COMPONENT 203
pari_err_CONSTPOL 7
pari_err_COPRIME 42
pari_err_DIM 813
pari_err_DOMAIN 4984
pari_err_FILE 0
pari_err_FLAG 14
pari_err_IMPL 224
pari_err_INV 695
pari_err_IRREDPOL 14
pari_err_MAXPRIME 0
pari_err_MODULUS 714
pari_err_OP 315
pari_err_OVERFLOW 56
pari_err_PACKAGE 0
pari_err_PREC 218
pari_err_PRIME 35
pari_err_PRIORITY 84
pari_err_ROOTS0 35
pari_err_SQRTN 77
pari_err_TYPE 36262
pari_err_TYPE2 2828
pari_err_VAR 490
pari_free 35841386
pari_malloc 106728010
pari_realloc 100882
pari_stack_alloc 232196730
pari_stack_base 232265687
pari_stack_delete 27078
pari_stack_init 48609
pari_stack_new 204939985
pari_stack_pushp 9120
perm_conj 35
perm_inv 98
perm_mul 18123406
pol0_F2x 1957218
pol0_Flx 27088672
pol1_F2x 527958
pol1_Flx 9682297
pol_0 11898655
pol_1 664408
pol_x 321246
polx_F2x 188798
polx_Flx 5978923
polx_zx 0
powIs 805
powii 313852
pr_get_e 1208573
pr_get_f 5293873
pr_get_gen 2345635
pr_get_p 8246377
pr_get_tau 4704648
pr_is_inert 491085
pr_norm 60957
prec2nbits 53637857
prec2nbits_mul 78655
prec2ndec 5651
precdbl 1667
qfb_disc 3716181
qfb_disc3 3786475
quad_disc 175
quadnorm 623
remsBIL 3122602385
resultant 25696
rnf_get_absdegree 155869
rnf_get_alpha 455
rnf_get_degree 310786
rnf_get_disc 63
rnf_get_idealdisc 420
rnf_get_index 98
rnf_get_invzk 1057
rnf_get_k 455
rnf_get_map 33929
rnf_get_nf 122577
rnf_get_nfdegree 15547
rnf_get_nfpol 107716
rnf_get_nfvarn 490
rnf_get_nfzk 6181
rnf_get_pol 461510
rnf_get_polabs 83013
rnf_get_varn 0
rnf_get_zk 3157
row 113231
row_Flm 25995
row_i 2093
row_zm 0
rowcopy 21
rowpermute 141860
rowslice 104066
rowslicepermute 19698
ser_isexactzero 607737
shallowcopy 201910
sqrfrac 138153
sqrti 2448828
sqrtnr 31864
sqrtr 6676020
sturm 441
submulii 41110715
submuliu 7000
submuliu_inplace 264306385
truecoeff 0
trunc_safe 0
vec_append 54894
vec_ei 303822
vec_lengthen 7574
vec_setconst 1701
vec_shorten 0
vec_to_vecsmall 203593
vecpermute 4338884
vecreverse 50799
vecreverse_inplace 218
vecslice 1727508
vecslicepermute 86632
vecsmall_append 357089
vecsmall_coincidence 0
vecsmall_concat 230658
vecsmall_copy 24643147
vecsmall_ei 7196
vecsmall_indexmax 14
vecsmall_indexmin 14
vecsmall_isin 111174
vecsmall_lengthen 448
vecsmall_lexcmp 2586374
vecsmall_max 2566
vecsmall_min 0
vecsmall_pack 84
vecsmall_prefixcmp 35286195
vecsmall_prepend 784
vecsmall_shorten 4536
vecsmall_to_col 446364
vecsmall_to_vec 7559
vecsmallpermute 17816134
vecsmalltrunc_append 2280691
vecsmalltrunc_init 1201802
vecsplice 4984
vectrunc_append 1111411
vectrunc_append_batch 0
vectrunc_init 700661
zc_to_ZC 427324
zero_F2m 0
zero_F2m_copy 96558
zero_F2v 672223
zero_F2x 77
zero_Flm 315
zero_Flm_copy 23532
zero_Flv 19179611
zero_Flx 82871
zero_zm 0
zero_zv 13267072
zero_zx 0
zerocol 22559356
zeromat 5600
zeromatcopy 1984287
zeropadic 271859
zeropadic_shallow 315
zeropol 4219016
zeroser 4942
zerovec 5738213
zm_copy 0
zm_to_zxV 0
zm_transpose 91
zv_copy 728490
zv_to_ZV 6370
zv_to_zx 0
zx_renormalize 0
zx_shift 0
zx_to_zv 0

Generated by: LCOV version 1.9