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 17846-16c9112) Lines: 1179 1317 89.5 %
Date: 2015-05-26 Functions: 486 551 88.2 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 520 620 83.9 %

Function Name Sort by function name Hit count Sort by hit count
F2m_clear 0
F2m_coeff 11752610
F2m_copy 1449
F2m_flip 336170
F2m_set 1549002
F2v_clear 2111106
F2v_coeff 95732297
F2v_copy 0
F2v_ei 7
F2v_flip 336170
F2v_set 13117627
F2v_to_F2x 6013
F2x_clear 2111106
F2x_coeff 98254354
F2x_div 1134910
F2x_equal 1178530
F2x_equal1 150565
F2x_flip 336170
F2x_renormalize 56090312
F2x_set 32368266
Flm_copy 473602
Flm_row 28175
Flv_copy 1026394
Flx_copy 44921244
Flx_div 1402515
Flx_equal1 3744317
Flx_lead 349216
Flx_mulu 200026
FlxqX_div 6146
FlxqX_rem 161242
Flxq_add 0
Flxq_sub 0
FpV_FpC_mul 0
FpXQX_div 0
FpXQX_renormalize 826804
FpXQ_add 0
FpXQ_sub 0
FpXX_renormalize 874819
FpX_div 518789
FpX_renormalize 90135532
Fp_add 173070878
Fp_addmul 2376490
Fp_center 3091149
Fp_div 4459462
Fp_halve 16308
Fp_inv 7438059
Fp_invsafe 342928
Fp_mul 147182191
Fp_muls 231
Fp_mulu 60574357
Fp_neg 9646683
Fp_red 2903855
Fp_sqr 6306163
Fp_sub 61424543
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 452381
FqX_Fq_mul 467870
FqX_add 768895
FqX_div 9597
FqX_div_by_X_x 5831
FqX_divrem 0
FqX_extgcd 37212
FqX_gcd 38234
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 1532702
Fq_to_FpXQ 3614
GENbinbase 54588222
QV_isscalar 5463443
Q_abs 312858
Q_abs_shallow 37841
RgC_fpnorml2 242522
RgC_gtofp 379428
RgC_gtomp 560
RgM_dimensions 115445
RgM_fpnorml2 1505
RgM_gtofp 18941
RgM_gtomp 14
RgM_inv 29902
RgM_minor 504
RgM_shallowcopy 4838048
RgV_is_QV 0
RgV_is_ZV 1276540
RgV_isscalar 6385
RgXQX_div 7
RgXQX_rem 31668
RgXQ_mul 395926
RgXQ_sqr 204079
RgX_coeff 360510
RgX_copy 62219840
RgX_div 6054217
RgX_equal_var 4074252
RgX_fpnorml2 10225
RgX_gtofp 442540
RgX_is_QX 109354
RgX_is_ZX 55699798
RgX_is_monomial 14649496
RgX_is_rational 2429
RgX_isscalar 0
RgX_rem 2580479
RgX_renormalize 171017
RgX_shift_inplace 534454
RgX_shift_inplace_init 534452
Rg_col_ei 3276350
ZC_hnfrem 801015
ZM_hnfrem 26145
ZM_lll 1132722
ZV_dvd 23198
ZV_isscalar 1566280
ZV_to_zv 193639
ZXQ_mul 104657
ZXQ_sqr 17654
ZX_ZXY_resultant 0
ZX_equal1 12743
ZX_renormalize 77255009
Z_ispower 14
Z_issquare 231385
abgrp_get_cyc 892335
abgrp_get_gen 227568
abgrp_get_no 7994
absfrac 1326169
absfrac_shallow 11564
addmuliu 7000
addmuliu_inplace 264441212
affc_fixlg 175449
affgr 176947
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 27295088
bit_accuracy 1112023562
bit_accuracy_mul 2501797
bit_prec 23818924
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 15989244
cbrtr 11355
cgetalloc 4737
cgetc 181530
cgiv 42528436
closure_arity 99160811
closure_codestr 86932052
closure_get_code 0
closure_get_data 86836541
closure_get_dbg 58141
closure_get_frame 82602
closure_get_oper 86898948
closure_get_text 118214
closure_is_variadic 12254297
col_ei 1167959
const_col 19787
const_vec 5709869
const_vecsmall 3229735
constant_term 17427222
cxcompotor 1611111
cxnorm 6597104
cxtofp 804440
cyclic_perm 0
dbllog2r 20688445
degpol 1526372317
divsBIL 3288853093
ellQp_get_p 245
ellQp_get_prec 84
ellQp_get_zero 336
ellR_get_prec 252
ellR_get_sign 688
ell_get_a1 1967188
ell_get_a2 1409782
ell_get_a3 1982966
ell_get_a4 2022548
ell_get_a6 2432377
ell_get_b2 2006247
ell_get_b4 433602
ell_get_b6 824944
ell_get_b8 688457
ell_get_c4 4710538
ell_get_c6 5070030
ell_get_disc 6408689
ell_get_j 946442
ell_get_type 6728457
ell_is_inf 17954890
ellff_get_a4a6 258920
ellff_get_field 603850
ellinf 402735
ellnf_get_nf 52885
equali1 169552724
equalim1 5737535
err_get_compo 77
err_get_num 130123
gabsz 0
gaddgs 7027513
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 21083
gdiventz 0
gdivsg 150506
gdivz 0
gen_I 411124
gener_Fq_local 462
gequalgs 22435
gerepileall 4153941
gerepilecoeffs 8
gerepilecopy 19892257
gerepilemany 37063
gerepileupto 415328343
gerepileuptoint 1035721743
gerepileuptoleaf 305795899
gmaxsg 0
gminsg 0
gmodz 0
gmul2nz 0
gmulgs 4846828
gmulz 11673
gnegz 0
gshiftz 0
gsubgs 396062
gsubz 0
gtodouble 24582587
gtofp 16156344
gtomp 22400
gtos 29924962
gtou 0
gval 427
icopy_avma 985296514
idealpseudomin 149487
idealpseudomin_nonscalar 230278
idealred 148704
idealred_elt 315
identity_perm 64470
inf_get_sign 20554
is_bigint 118600543
is_const_t 694039575
is_extscalar_t 591269
is_intreal_t 766364
is_matvec_t 303264679
is_noncalc_t 50389213
is_pm1 1326205422
is_rational_t 417652
is_recursive_t 2091005968
is_scalar_t 150343875
is_universal_constant 30124073
is_vec_t 282700
isint1 5000438
isintm1 301
isintzero 303314905
ismpzero 766287
isonstack 1799252440
killblock 993599
leading_term 63555845
leafcopy_avma 53119247
lgcols 24544744
lgpol 735760027
lincombii 17963412
matpascal 364
matslice 96726
mkcol 622641
mkcol2 12841077
mkcol2s 0
mkcol3 40369
mkcol3s 0
mkcol4 0
mkcol4s 0
mkcol5 0
mkcol6 351
mkcolcopy 27267
mkcols 0
mkcomplex 2512876
mkerr 0
mkfrac 43779
mkfraccopy 2474199
mkintmod 378964
mkintmodu 3675
mkmat 186499
mkmat2 9966156
mkmat3 2345
mkmat4 0
mkmat5 0
mkmatcopy 7203
mkmoo 5788
mkoo 9619
mkpolmod 238945
mkqfi 158109
mkquad 42
mkrfrac 7
mkrfraccopy 14
mkvec 2403139
mkvec2 10943849
mkvec2copy 167444
mkvec2s 10416
mkvec3 78649535
mkvec3s 492702
mkvec4 3588761
mkvec4s 7
mkvec5 11480887
mkveccopy 33180
mkvecs 7
mkvecsmall 28832894
mkvecsmall2 91479422
mkvecsmall3 35515415
mkvecsmall4 1480943
mkvecsmall5 104716
modpr_get_T 763417
modpr_get_p 2331
modpr_get_pr 1709096
mpcosz 0
mpexpz 0
mplogz 0
mpsinz 0
mul_content 238644
mul_denom 177071
mulsubii 1725107
nbits2extraprec 318168574
nbits2lg 2734470
nbits2nlong 713533
nbits2prec 71447045
nbrows 12690760
nchar2nlong 8670725
ndec2nlong 14137
ndec2prec 14137
nf_get_G 42238
nf_get_M 876966
nf_get_Tr 784
nf_get_degree 2590586
nf_get_diff 798
nf_get_disc 20567
nf_get_index 488081
nf_get_invzk 1084960
nf_get_pol 5688300
nf_get_r1 966834
nf_get_r2 1043
nf_get_ramified_primes 7
nf_get_roots 86071
nf_get_roundG 337627
nf_get_sign 3888
nf_get_varn 4325
nf_get_zk 5563364
normalize_frac 6286889
odd 283746523
pari_calloc 36200
pari_err_BUG 14
pari_err_COMPONENT 210
pari_err_CONSTPOL 7
pari_err_COPRIME 42
pari_err_DIM 827
pari_err_DOMAIN 5019
pari_err_FILE 0
pari_err_FLAG 21
pari_err_IMPL 224
pari_err_INV 697
pari_err_IRREDPOL 14
pari_err_MAXPRIME 0
pari_err_MODULUS 714
pari_err_OP 315
pari_err_OVERFLOW 63
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 36339
pari_err_TYPE2 2821
pari_err_VAR 490
pari_free 36089753
pari_malloc 110435488
pari_realloc 105998
pari_stack_alloc 227614506
pari_stack_base 227660140
pari_stack_delete 27723
pari_stack_init 54952
pari_stack_new 199745834
pari_stack_pushp 9292
perm_conj 35
perm_inv 98
perm_mul 18123455
pol0_F2x 2079021
pol0_Flx 26948521
pol1_F2x 571800
pol1_Flx 9460165
pol_0 12047356
pol_1 667953
pol_x 322032
polx_F2x 189009
polx_Flx 5896766
polx_zx 0
powIs 805
powii 313870
pr_get_e 1159401
pr_get_f 4648303
pr_get_gen 1732379
pr_get_p 8197256
pr_get_tau 4704512
pr_is_inert 491092
pr_norm 60964
prec2nbits 54975134
prec2nbits_mul 233070
prec2ndec 6113
precdbl 1667
qfb_disc 3716345
qfb_disc3 3786639
quad_disc 259
quadnorm 623
remsBIL 3214602838
resultant 25710
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 113245
row_i 2093
rowcopy 56
rowpermute 141881
rowslice 162992
rowslicepermute 19712
ser_isexactzero 1188856
shallowcopy 207070
sqrfrac 91029
sqrti 2450319
sqrtnr 32012
sqrtr 6485428
sturm 441
submulii 41124752
submuliu 7000
submuliu_inplace 264842529
truecoeff 0
trunc_safe 0
vec_append 55979
vec_ei 303899
vec_lengthen 7574
vec_setconst 1701
vec_shorten 0
vec_to_vecsmall 204321
vecpermute 4339794
vecreverse 50883
vecreverse_inplace 225
vecslice 3343752
vecslicepermute 86688
vecsmall_append 357089
vecsmall_coincidence 0
vecsmall_concat 230658
vecsmall_copy 25034753
vecsmall_ei 7196
vecsmall_indexmax 14
vecsmall_indexmin 14
vecsmall_isin 111174
vecsmall_lengthen 448
vecsmall_lexcmp 2586374
vecsmall_max 3779
vecsmall_min 133
vecsmall_pack 84
vecsmall_prefixcmp 35286195
vecsmall_prepend 784
vecsmall_shorten 4536
vecsmall_to_col 446390
vecsmall_to_vec 7559
vecsmallpermute 17816183
vecsmalltrunc_append 2281459
vecsmalltrunc_init 1201824
vecsplice 4984
vectrunc_append 1151048
vectrunc_append_batch 0
vectrunc_init 701095
zc_to_ZC 427350
zero_F2m 0
zero_F2m_copy 96539
zero_F2v 681821
zero_F2x 77
zero_Flm 315
zero_Flm_copy 23532
zero_Flv 19283159
zero_Flx 83302
zero_zm 0
zero_zv 13361024
zero_zx 0
zerocol 23062858
zeromat 5600
zeromatcopy 1994772
zeropadic 273819
zeropadic_shallow 315
zeropol 4347967
zeroser 5229
zerovec 5742513
zm_copy 0
zm_row 0
zm_to_zxV 0
zm_transpose 91
zv_copy 729244
zv_to_ZV 6370
zv_to_zx 0
zx_renormalize 0
zx_shift 0
zx_to_zv 0

Generated by: LCOV version 1.9