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-bordeaux.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.10.0 lcov report (development 20422-b487f4d) Lines: 1238 1409 87.9 %
Date: 2017-03-22 05:51:54 Functions: 523 595 87.9 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
F2m_clear 0
F2m_coeff 13005322
F2m_copy 302
F2m_flip 1339603
F2m_set 1668085
F2v_clear 3543228
F2v_coeff 95177894
F2v_copy 0
F2v_ei 7
F2v_flip 1339603
F2v_set 9101657
F2v_to_F2x 6814
F2x_clear 3543228
F2x_coeff 98945208
F2x_copy 64792218
F2x_div 2730935
F2x_equal 3279557
F2x_equal1 790124
F2x_flip 1339603
F2x_renormalize 125055694
F2x_set 33209571
F2xqX_div 29785
Flm_copy 1182258
Flm_row 3387663
Flv_copy 2334926
Flx_copy 74642516
Flx_div 3072267
Flx_equal1 4646345
Flx_lead 406787
Flx_mulu 665946
FlxqX_div 31498
Flxq_add 0
Flxq_sub 110
FpV_FpC_mul 0
FpXQX_div 961
FpXQX_renormalize 982562
FpXQ_add 0
FpXQ_sub 0
FpXX_renormalize 948233
FpX_div 734704
FpX_renormalize 87264166
Fp_add 60090034
Fp_addmul 1509095
Fp_center 5674332
Fp_div 4555754
Fp_halve 19770
Fp_inv 9621151
Fp_invsafe 289588
Fp_mul 51711198
Fp_muls 0
Fp_mulu 46687436
Fp_neg 10704291
Fp_red 1751764
Fp_sqr 6964263
Fp_sub 45883635
FqXQ_add 0
FqXQ_div 0
FqXQ_inv 0
FqXQ_invsafe 0
FqXQ_mul 21018
FqXQ_pow 0
FqXQ_sqr 0
FqXQ_sub 0
FqX_Fp_mul 608338
FqX_Fq_mul 552042
FqX_add 903963
FqX_deriv 268653
FqX_div 2977
FqX_div_by_X_x 5957
FqX_divrem 329
FqX_extgcd 79709
FqX_factor 71148
FqX_gcd 254151
FqX_get_red 5605
FqX_halfgcd 0
FqX_mul 83903
FqX_mulu 459889
FqX_neg 16438
FqX_normalize 1995
FqX_powu 1428
FqX_red 27419
FqX_rem 47875
FqX_roots 5810
FqX_sqr 4760
FqX_sub 2380
Fq_red 1365068
Fq_to_FpXQ 11793
GENbinbase 75922327
QV_isscalar 5606034
Q_abs 405014
Q_abs_shallow 36832
R_abs 0
R_abs_shallow 322
RgC_fpnorml2 132630
RgC_gtofp 264912
RgC_gtomp 560
RgM_dimensions 107365
RgM_fpnorml2 1598
RgM_gtofp 18873
RgM_gtomp 14
RgM_inv 24402
RgM_minor 756
RgM_shallowcopy 6037947
RgV_gtofp 42
RgV_is_QV 147
RgV_is_ZV 2481958
RgV_isscalar 3689
RgXQX_div 7
RgXQX_rem 17192
RgXQ_mul 440801
RgXQ_sqr 229653
RgX_coeff 2225280
RgX_copy 63917517
RgX_div 6321423
RgX_equal_var 3978352
RgX_fpnorml2 7141
RgX_gtofp 485887
RgX_is_QX 106654
RgX_is_ZX 56812658
RgX_is_monomial 15228963
RgX_is_rational 2633
RgX_isscalar 0
RgX_rem 2468040
RgX_renormalize 316001
RgX_shift_inplace 592245
RgX_shift_inplace_init 592242
Rg_col_ei 1086914
ZC_hnfrem 779903
ZM_hnfrem 23454
ZM_lll 1051933
ZV_dvd 23198
ZV_isscalar 1973813
ZV_to_zv 223032
ZXQ_mul 118237
ZXQ_sqr 21196
ZX_ZXY_resultant 0
ZX_equal1 17512
ZX_renormalize 73675647
Z_ispower 14
Z_issquare 1966879
abgrp_get_cyc 1158632
abgrp_get_gen 279254
abgrp_get_no 9527
absfrac 1096033
absfrac_shallow 11056
addmuliu 7000
addmuliu_inplace 108238971
affc_fixlg 186595
affgr 180482
bid_get_U 428286
bid_get_arch 448
bid_get_archp 221563
bid_get_cyc 632741
bid_get_fact 225336
bid_get_fact2 217776
bid_get_gen 7406
bid_get_gen_nocheck 0
bid_get_grp 640742
bid_get_ideal 11725
bid_get_mod 210230
bid_get_no 0
bid_get_sarch 6454
bid_get_sprk 217846
bin_copy 37962444
bit_accuracy 1090316214
bit_accuracy_mul 447301
bit_prec 23478256
bnf_get_clgp 565669
bnf_get_cyc 293919
bnf_get_fu 1806
bnf_get_fu_nocheck 3802
bnf_get_gen 270287
bnf_get_logfu 429300
bnf_get_nf 1520686
bnf_get_no 1134
bnf_get_reg 860
bnf_get_tuN 7672
bnf_get_tuU 2535
bnr_get_bid 211182
bnr_get_bnf 420341
bnr_get_clgp 246392
bnr_get_cyc 229991
bnr_get_gen 7112
bnr_get_gen_nocheck 70
bnr_get_mod 18053
bnr_get_nf 13398
bnr_get_no 8393
both_odd 7281801
cbrtr 0
cbrtr_abs 0
cgetalloc 3912
cgetc 204133
cgiv 26392613
closure_arity 186627271
closure_codestr 152102570
closure_get_code 0
closure_get_data 152000722
closure_get_dbg 16981
closure_get_frame 386494
closure_get_oper 152039160
closure_get_text 37511
closure_is_variadic 34374918
col_ei 1245970
const_col 55857
const_vec 6107436
const_vecsmall 3571859
constant_coeff 17560912
cxcompotor 2143063
cxnorm 8721688
cxtofp 1069773
cyclic_perm 0
dbllog2r 16989206
degpol 2466097027
divsBIL 2852678755
ellQp_get_p 623
ellQp_get_prec 287
ellQp_get_zero 917
ellR_get_prec 36960
ellR_get_sign 1577
ell_get_a1 5030681
ell_get_a2 3316415
ell_get_a3 4497255
ell_get_a4 4108053
ell_get_a6 4682025
ell_get_b2 3950411
ell_get_b4 1010178
ell_get_b6 1614082
ell_get_b8 1457750
ell_get_c4 6101940
ell_get_c6 8133586
ell_get_disc 9562544
ell_get_j 1174768
ell_get_type 7898782
ell_is_inf 25325749
ellff_get_a4a6 677689
ellff_get_field 1561394
ellinf 824150
ellnf_get_bnf 49
ellnf_get_nf 555317
equali1 218113658
equalim1 23550089
err_get_compo 70
err_get_num 47538
gabsz 0
gaddgs 7464388
gaddz 23318
gal_get_den 2135
gal_get_e 63
gal_get_gen 1869
gal_get_group 7413
gal_get_invvdm 2135
gal_get_mod 2135
gal_get_orders 1414
gal_get_p 1225
gal_get_pol 2891
gal_get_roots 2513
gcmpgs 23890
gdiventz 0
gdivsg 450875
gdivz 0
gen_I 424750
gener_Fq_local 833
gequalgs 22827
gerepileall 4921265
gerepilecoeffs 8
gerepilecopy 33529492
gerepilemany 64820
gerepileupto 631549380
gerepileuptoint 904933125
gerepileuptoleaf 518806688
gmaxsg 0
gminsg 0
gmodz 0
gmul2nz 0
gmulgs 5792114
gmulz 11673
gnegz 0
gshiftz 0
gsubgs 554848
gsubz 0
gtodouble 21216798
gtofp 17622649
gtomp 22400
gtos 66533662
gtou 83119
gval 2205
icopy_avma 3632377324
idealchineseinit 1218
idealpseudomin 140833
idealpseudomin_nonscalar 267221
idealpseudored 5131
idealred 145936
idealred_elt 0
identity_perm 554386
inf_get_sign 29218
is_bigint 117783374
is_const_t 1030016788
is_extscalar_t 45301
is_intreal_t 946822
is_matvec_t 337942124
is_noncalc_t 44732881
is_pm1 1506559603
is_rational_t 402961
is_real_t 299211
is_recursive_t 2522774961
is_scalar_t 157712377
is_universal_constant 17122733
is_vec_t 473747
isint1 6840349
isintm1 301
isintzero 357509671
ismpzero 946745
isonstack 2081692629
killblock 1175778
leading_coeff 73106872
leafcopy_avma 94411800
lgcols 86172579
lgpol 1286562866
lincombii 18777338
logint 202230
matpascal 1008
matslice 114555
mkcol 2060768
mkcol2 14737169
mkcol2s 1181376
mkcol3 41615
mkcol3s 0
mkcol4 0
mkcol4s 0
mkcol5 0
mkcol6 799
mkcolcopy 23750
mkcols 728
mkcomplex 2862644
mkerr 0
mkfrac 1796448
mkfraccopy 2922598
mkintmod 327995
mkintmodu 3794
mkmat 643995
mkmat2 15691559
mkmat3 2352
mkmat4 0
mkmat5 0
mkmatcopy 7222
mkmoo 7910
mkoo 14213
mkpolmod 253334
mkqfi 158123
mkquad 42
mkrfrac 7
mkrfraccopy 14
mkvec 3174539
mkvec2 22620989
mkvec2copy 83201
mkvec2s 12103
mkvec3 56184474
mkvec3s 492702
mkvec4 7338719
mkvec4s 0
mkvec5 11738466
mkveccopy 33453
mkvecs 7
mkvecsmall 49166289
mkvecsmall2 110103824
mkvecsmall3 61649164
mkvecsmall4 9290221
mkvecsmall5 435711
modpr_get_T 1769918
modpr_get_p 603447
modpr_get_pr 6205182
mpcosz 0
mpexpz 0
mplogz 0
mpsinz 0
mul_content 202621
mul_denom 522368
mulsubii 1296825
nbits2extraprec 239765690
nbits2lg 3385467
nbits2ndec 179
nbits2nlong 907722
nbits2prec 74531781
nbrows 16860856
nchar2nlong 7181899
ndec2nbits 462
ndec2nlong 23189
ndec2prec 22727
nf_get_G 45644
nf_get_M 1079684
nf_get_Tr 24339
nf_get_degree 8326187
nf_get_diff 1750
nf_get_disc 23240
nf_get_index 617649
nf_get_invzk 1643555
nf_get_pol 12264429
nf_get_r1 1124595
nf_get_r2 1365
nf_get_ramified_primes 28
nf_get_roots 100319
nf_get_roundG 382374
nf_get_sign 6741
nf_get_varn 2106
nf_get_zk 77
nf_get_zkden 126369
nf_get_zkprimpart 123982
normalize_frac 8497356
odd 1824480430
pari_calloc 30658
pari_err_BUG 14
pari_err_COMPONENT 224
pari_err_CONSTPOL 7
pari_err_COPRIME 63
pari_err_DIM 932
pari_err_DOMAIN 5201
pari_err_FILE 0
pari_err_FLAG 28
pari_err_IMPL 350
pari_err_INV 655
pari_err_IRREDPOL 21
pari_err_MAXPRIME 0
pari_err_MODULUS 735
pari_err_OP 287
pari_err_OVERFLOW 70
pari_err_PACKAGE 0
pari_err_PREC 219
pari_err_PRIME 56
pari_err_PRIORITY 119
pari_err_ROOTS0 42
pari_err_SQRTN 77
pari_err_TYPE 18990
pari_err_TYPE2 3073
pari_err_VAR 203
pari_free 46270894
pari_malloc 183877066
pari_realloc 316863
pari_stack_alloc 330371055
pari_stack_base 331239054
pari_stack_delete 781335
pari_stack_init 900514
pari_stack_new 276923026
pari_stack_pushp 5859
perm_conj 204981
perm_inv 482362
perm_mul 42002244
pol0_F2x 10947332
pol0_Flx 43159316
pol1_F2x 2708640
pol1_Flx 17544831
pol_0 13798019
pol_1 1181837
pol_x 645816
pol_xn 2428182
pol_xnall 133
polx_F2x 643520
polx_Flx 16764155
polx_zx 0
powIs 840
powii 211137
pr_get_e 2091239
pr_get_f 7187321
pr_get_gen 4253930
pr_get_p 15887735
pr_get_tau 5550028
pr_is_inert 2006135
pr_norm 293400
prec2nbits 1168425217
prec2nbits_mul 229912
prec2ndec 12134
precdbl 1644
qfb_disc 5915000
qfb_disc3 5995836
quad_disc 252
quadnorm 623
remsBIL 2787681417
resultant 34710
rnf_get_absdegree 156450
rnf_get_alpha 448
rnf_get_degree 311395
rnf_get_disc 63
rnf_get_idealdisc 434
rnf_get_index 105
rnf_get_invzk 1190
rnf_get_k 448
rnf_get_map 34006
rnf_get_nf 123767
rnf_get_nfdegree 14805
rnf_get_nfpol 106519
rnf_get_nfvarn 483
rnf_get_nfzk 1701
rnf_get_pol 463092
rnf_get_polabs 93674
rnf_get_varn 0
rnf_get_zk 2443
row 169606
row_i 2177
rowcopy 56
rowpermute 2341664
rowslice 16913032
rowslicepermute 35104
rowsplice 133
ser_isexactzero 3873815
shallowcopy 2615219
sqrfrac 1405435
sqrti 4717994
sqrtnr 290901
sqrtr 15688694
sturm 448
submulii 13184654
submuliu 7000
submuliu_inplace 109615713
truecoeff 0
trunc_safe 0
ulogint 9114
upr_norm 32277
vec_append 56343
vec_ei 305180
vec_lengthen 10892
vec_setconst 0
vec_shorten 0
vec_to_vecsmall 233994
vecpermute 4770070
vecreverse 4744860
vecreverse_inplace 232
vecslice 166734533
vecslicepermute 702904
vecsmall_append 371653
vecsmall_coincidence 0
vecsmall_concat 633788
vecsmall_copy 1585173
vecsmall_ei 64457
vecsmall_indexmax 14
vecsmall_indexmin 14
vecsmall_isin 0
vecsmall_lengthen 21
vecsmall_lexcmp 8205767
vecsmall_max 40583
vecsmall_min 0
vecsmall_pack 84
vecsmall_prefixcmp 47066978
vecsmall_prepend 1498
vecsmall_reverse 252
vecsmall_shorten 130144
vecsmall_to_col 1227818
vecsmall_to_vec 21399
vecsmall_to_vec_inplace 882
vecsmallpermute 40494467
vecsmalltrunc_append 2727069
vecsmalltrunc_init 1345198
vecsplice 8470
vectrunc_append 42967155
vectrunc_append_batch 0
vectrunc_init 11519385
zc_to_ZC 1208813
zero_F2m 0
zero_F2m_copy 268052
zero_F2v 648674
zero_F2x 35
zero_Flm 794676
zero_Flm_copy 74573
zero_Flv 30620544
zero_Flx 786991
zero_zm 0
zero_zv 16897845
zero_zx 0
zerocol 21499827
zeromat 4683
zeromatcopy 1594180
zeropadic 301035
zeropadic_shallow 511
zeropol 5108602
zeroser 14091
zerovec 7586169
zerovec_block 15771
zm_copy 0
zm_row 0
zm_to_zxV 0
zm_transpose 168
znstar_get_N 19544
znstar_get_U 6902
znstar_get_Ui 161
znstar_get_conreycyc 18053
znstar_get_conreygen 13713
znstar_get_cyc 567
znstar_get_faN 35833
znstar_get_gen 0
znstar_get_no 0
znstar_get_pe 13699
zv_copy 2034267
zv_to_ZV 18249
zv_to_zx 0
zx_renormalize 0
zx_shift 0
zx_to_zv 0

Generated by: LCOV version 1.11