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 17226-bccfbd3) Lines: 1162 1304 89.1 %
Date: 2014-12-17 Functions: 482 548 88.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 507 612 82.8 %

Function Name Sort by function name Hit count Sort by hit count
F2m_clear 0
F2m_coeff 13879865
F2m_copy 1428
F2m_flip 335868
F2m_set 2200727
F2v_clear 1923259
F2v_coeff 82283004
F2v_copy 0
F2v_ei 7
F2v_flip 335868
F2v_set 14477087
F2v_to_F2x 6013
F2x_clear 1923259
F2x_coeff 82879995
F2x_div 934668
F2x_equal 906563
F2x_equal1 1488
F2x_flip 335868
F2x_renormalize 51083546
F2x_set 31992224
Flm_copy 470114
Flv_copy 961307
Flx_copy 45338510
Flx_div 1387431
Flx_equal1 3070037
Flx_lead 52743
Flx_mulu 200026
FlxqX_div 6146
FlxqX_rem 160905
Flxq_add 0
Flxq_sub 0
FpV_FpC_mul 0
FpXQX_div 0
FpXQX_renormalize 621735
FpXQ_add 0
FpXQ_sub 0
FpXX_renormalize 467349
FpX_div 516732
FpX_renormalize 82677009
Fp_add 44774998
Fp_addmul 2372794
Fp_center 3052182
Fp_div 2365781
Fp_halve 15925
Fp_inv 5126918
Fp_invsafe 323829
Fp_mul 32593677
Fp_muls 231
Fp_mulu 23472164
Fp_neg 9277909
Fp_red 2856630
Fp_sqr 2865966
Fp_sub 53540743
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 448482
FqX_Fq_mul 464629
FqX_add 763767
FqX_div 9373
FqX_div_by_X_x 5761
FqX_divrem 0
FqX_extgcd 36757
FqX_gcd 37814
FqX_mul 81704
FqX_mulu 386502
FqX_neg 3972
FqX_powu 973
FqX_red 7665
FqX_rem 25139
FqX_sqr 4179
FqX_sub 103039
Fq_red 1327007
Fq_to_FpXQ 3572
GENbinbase 52848584
QV_isscalar 5451900
Q_abs 300836
Q_abs_shallow 36847
RgC_fpnorml2 242214
RgC_gtofp 376075
RgC_gtomp 560
RgM_dimensions 115361
RgM_fpnorml2 1470
RgM_gtofp 18542
RgM_gtomp 14
RgM_inv 29986
RgM_minor 315
RgM_shallowcopy 4821202
RgV_is_QV 0
RgV_is_ZV 1271199
RgV_isscalar 6385
RgXQX_div 7
RgXQX_rem 27062
RgXQ_mul 323588
RgXQ_sqr 145573
RgX_coeff 5425
RgX_copy 61915532
RgX_div 6053083
RgX_equal_var 3931970
RgX_fpnorml2 9917
RgX_gtofp 409116
RgX_is_QX 81193
RgX_is_ZX 54514185
RgX_is_monomial 14698920
RgX_is_rational 2093
RgX_isscalar 0
RgX_rem 1847150
RgX_renormalize 171017
RgX_shift_inplace 481129
RgX_shift_inplace_init 481129
Rg_col_ei 3258346
ZC_hnfrem 801309
ZM_hnfrem 26089
ZM_lll 1129393
ZV_dvd 23198
ZV_isscalar 1564775
ZV_to_zv 192834
ZXQ_mul 103754
ZXQ_sqr 16758
ZX_ZXY_resultant 0
ZX_equal1 12669
ZX_renormalize 70513659
Z_ispower 14
Z_issquare 231013
abgrp_get_cyc 891957
abgrp_get_gen 227372
abgrp_get_no 7980
absfrac 1287067
absfrac_shallow 11291
addmuliu 7000
addmuliu_inplace 254516610
affc_fixlg 26558
affgr 3172046
bid_get_arch 98452
bid_get_cyc 461293
bid_get_gen 4970
bid_get_gen_nocheck 0
bid_get_grp 466781
bid_get_ideal 72829
bid_get_mod 287251
bid_get_no 0
bin_copy 26428826
bit_accuracy 1027141845
bit_accuracy_mul 2105991
bit_prec 23135683
bnf_get_clgp 464838
bnf_get_cyc 242331
bnf_get_fu 6691
bnf_get_fu_nocheck 11983
bnf_get_gen 221814
bnf_get_logfu 347098
bnf_get_nf 927101
bnf_get_no 553
bnf_get_reg 573
bnf_get_tuN 7497
bnf_get_tuU 5978
bnr_get_bid 172009
bnr_get_bnf 345789
bnr_get_clgp 196712
bnr_get_cyc 187815
bnr_get_gen 1400
bnr_get_gen_nocheck 70
bnr_get_mod 9121
bnr_get_nf 2205
bnr_get_no 7427
both_odd 14957910
cgetalloc 2647
cgetc 46406
cgiv 40956950
closure_arity 91974096
closure_codestr 80202909
closure_get_code 0
closure_get_data 80196617
closure_get_dbg 6451
closure_get_frame 4410
closure_get_oper 80202909
closure_get_text 13497
closure_is_variadic 11766748
col_ei 1146987
const_col 17995
const_vec 5693608
const_vecsmall 3218262
constant_term 17427629
cxcompotor 1306127
cxnorm 6804781
cxtofp 652109
cyclic_perm 0
dbllog2r 13078141
degpol 1261199042
divsBIL 2991273697
ellQp_get_p 245
ellQp_get_prec 84
ellQp_get_zero 336
ellR_get_prec 245
ellR_get_sign 660
ell_get_a1 1966403
ell_get_a2 1409497
ell_get_a3 1982300
ell_get_a4 2022396
ell_get_a6 2432330
ell_get_b2 2005893
ell_get_b4 433546
ell_get_b6 824909
ell_get_b8 688471
ell_get_c4 4712572
ell_get_c6 5072085
ell_get_disc 6276767
ell_get_j 897442
ell_get_type 6738520
ell_is_inf 16156838
ellff_get_a4a6 258307
ellff_get_field 602735
ellinf 406870
ellnf_get_nf 52864
equali1 160475326
equalim1 61066
err_get_compo 77
err_get_num 27022
gabsz 0
gaddgs 1396518
gaddz 23318
gal_get_den 1526
gal_get_e 42
gal_get_gen 875
gal_get_group 798
gal_get_invvdm 1526
gal_get_mod 1512
gal_get_orders 413
gal_get_p 924
gal_get_pol 875
gal_get_roots 1869
gcmpgs 23372
gdiventz 0
gdivsg 96841
gdivz 0
gen_I 165123
gener_Fq_local 448
gequalgs 22435
gerepileall 4079505
gerepilecoeffs 8
gerepilecopy 19117585
gerepilemany 36986
gerepileupto 386845812
gerepileuptoint 936972335
gerepileuptoleaf 241759542
gmaxsg 0
gminsg 0
gmodz 0
gmul2nz 0
gmulgs 2392407
gmulz 11673
gnegz 0
gshiftz 0
gsubgs 392386
gsubz 0
gtodouble 6057749
gtofp 8476124
gtomp 22400
gtos 29720145
gtou 0
gval 406
icopy_avma 880214467
idealpseudomin 149312
idealpseudomin_nonscalar 230257
idealred 148529
idealred_elt 315
identity_perm 64183
inf_get_sign 14107
is_bigint 112291946
is_const_t 668554220
is_extscalar_t 587692
is_intreal_t 520838
is_matvec_t 298922206
is_noncalc_t 50125742
is_pm1 1075784077
is_rational_t 335997
is_recursive_t 1879646038
is_scalar_t 150229587
is_universal_constant 18186977
is_vec_t 731718
isint1 4976862
isintm1 238
isintzero 253845770
ismpzero 520761
isonstack 1606545001
killblock 954992
leading_term 58727417
leafcopy_avma 45597563
lgcols 22800195
lgpol 609272193
lincombii 17787378
matpascal 273
mkcol 620833
mkcol2 11585833
mkcol2s 0
mkcol3 40341
mkcol3s 0
mkcol4 0
mkcol4s 0
mkcol5 0
mkcol6 337
mkcolcopy 27036
mkcols 0
mkcomplex 2954080
mkerr 0
mkfrac 43033
mkfraccopy 1518069
mkintmod 380200
mkintmodu 3654
mkmat 186527
mkmat2 8673198
mkmat3 2996
mkmat4 0
mkmat5 0
mkmatcopy 6839
mkmoo 4514
mkoo 7267
mkpolmod 199990
mkqfi 158109
mkquad 42
mkrfrac 7
mkrfraccopy 14
mkvec 2392433
mkvec2 10254123
mkvec2copy 167129
mkvec2s 9562
mkvec3 30005691
mkvec3s 492702
mkvec4 3587018
mkvec4s 7
mkvec5 11475840
mkveccopy 33411
mkvecs 7
mkvecsmall 25450020
mkvecsmall2 85877118
mkvecsmall3 35275113
mkvecsmall4 1480775
mkvecsmall5 196
modpr_get_T 761464
modpr_get_p 2317
modpr_get_pr 1703468
mpcosz 0
mpexpz 0
mplogz 0
mpsinz 0
mul_content 231119
mul_denom 175363
mulsubii 1713270
nbits2extraprec 229742815
nbits2lg 2476080
nbits2nlong 759282
nbits2prec 73654197
nbrows 12233976
nchar2nlong 8194057
ndec2nlong 15057
ndec2prec 15057
nf_get_G 42070
nf_get_M 876959
nf_get_Tr 784
nf_get_degree 2549573
nf_get_diff 791
nf_get_disc 20308
nf_get_index 477204
nf_get_invzk 1066438
nf_get_pol 5565899
nf_get_r1 963985
nf_get_r2 287
nf_get_roots 45219
nf_get_roundG 337221
nf_get_sign 3825
nf_get_varn 3947
nf_get_zk 5551230
normalize_frac 4230776
odd 195454414
pari_calloc 25136
pari_err_BUG 14
pari_err_COMPONENT 203
pari_err_CONSTPOL 7
pari_err_COPRIME 42
pari_err_DIM 191
pari_err_DOMAIN 1318
pari_err_FILE 0
pari_err_FLAG 14
pari_err_IMPL 133
pari_err_INV 658
pari_err_IRREDPOL 14
pari_err_MAXPRIME 0
pari_err_MODULUS 707
pari_err_OP 308
pari_err_OVERFLOW 56
pari_err_PACKAGE 0
pari_err_PREC 218
pari_err_PRIME 35
pari_err_PRIORITY 77
pari_err_ROOTS0 35
pari_err_SQRTN 77
pari_err_TYPE 10616
pari_err_TYPE2 2793
pari_err_VAR 490
pari_free 34571920
pari_malloc 104812080
pari_realloc 61758
pari_stack_alloc 216367759
pari_stack_base 216393841
pari_stack_delete 19727
pari_stack_init 24867
pari_stack_new 189106138
pari_stack_pushp 6355
perm_conj 35
perm_inv 98
perm_mul 17903680
pol0_F2x 1715455
pol0_Flx 23678897
pol1_F2x 514528
pol1_Flx 9644945
pol_0 11222103
pol_1 621938
pol_x 311808
polx_F2x 170073
polx_Flx 5908272
polx_zx 0
powIs 805
powii 311321
pr_get_e 1201947
pr_get_f 5272982
pr_get_gen 2329363
pr_get_p 8227069
pr_get_tau 4700781
pr_is_inert 487599
pr_norm 61013
prec2nbits 46292472
prec2nbits_mul 48006
prec2ndec 3653
precdbl 1674
qfb_disc 3716181
qfb_disc3 3786475
quad_disc 175
quadnorm 623
remsBIL 2919249784
resultant 25598
rnf_get_absdegree 37632
rnf_get_alpha 371
rnf_get_degree 63630
rnf_get_disc 196
rnf_get_idealdisc 224
rnf_get_index 105
rnf_get_invzk 1057
rnf_get_k 392
rnf_get_map 23660
rnf_get_nf 63140
rnf_get_nfdegree 13986
rnf_get_nfpol 82068
rnf_get_nfvarn 406
rnf_get_nfzk 3500
rnf_get_pol 175868
rnf_get_polabs 58002
rnf_get_varn 0
rnf_get_zk 2478
row 113210
row_Flm 23761
row_i 2072
row_zm 0
rowcopy 21
rowpermute 139298
rowslice 101007
rowslicepermute 19642
ser_isexactzero 609942
shallowcopy 198920
sqrfrac 134485
sqrti 2448583
sqrtnr 29891
sqrtr 6523804
sturm 210
submulii 41102041
submuliu 7000
submuliu_inplace 254865968
truecoeff 0
trunc_safe 0
vec_append 54894
vec_ei 303416
vec_lengthen 7574
vec_setconst 1750
vec_shorten 0
vec_to_vecsmall 203131
vecpermute 4251321
vecreverse 1176
vecreverse_inplace 218
vecslice 1685578
vecslicepermute 86576
vecsmall_append 355369
vecsmall_coincidence 0
vecsmall_concat 192388
vecsmall_copy 21135722
vecsmall_ei 7224
vecsmall_indexmax 14
vecsmall_indexmin 14
vecsmall_isin 111174
vecsmall_lengthen 448
vecsmall_lexcmp 2586374
vecsmall_max 1904
vecsmall_min 0
vecsmall_pack 84
vecsmall_prefixcmp 35286195
vecsmall_prepend 784
vecsmall_shorten 4508
vecsmall_to_col 429044
vecsmall_to_vec 6929
vecsmallpermute 17596506
vecsmalltrunc_append 2261597
vecsmalltrunc_init 1200415
vecsplice 3997
vectrunc_append 1109922
vectrunc_append_batch 0
vectrunc_init 700488
zc_to_ZC 410032
zero_F2m 0
zero_F2m_copy 95290
zero_F2v 752552
zero_F2x 77
zero_Flm 315
zero_Flm_copy 23462
zero_Flv 19050830
zero_Flx 73281
zero_zm 0
zero_zv 13059993
zero_zx 0
zerocol 21310365
zeromat 6678
zeromatcopy 1937676
zeropadic 10787
zeropadic_shallow 315
zeropol 4206587
zeroser 4704
zerovec 5731204
zm_copy 0
zm_to_zxV 0
zm_transpose 91
zv_copy 728875
zv_to_ZV 5740
zv_to_zx 0
zx_renormalize 0
zx_shift 0
zx_to_zv 0

Generated by: LCOV version 1.9