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 17910-ca0bb25) Lines: 1174 1317 89.1 %
Date: 2015-07-07 Functions: 485 551 88.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 518 620 83.5 %

Function Name Sort by function name Hit count Sort by hit count
F2m_clear 0
F2m_coeff 11755130
F2m_copy 1449
F2m_flip 338487
F2m_set 1549002
F2v_clear 2115222
F2v_coeff 95743854
F2v_copy 0
F2v_ei 7
F2v_flip 338487
F2v_set 13121421
F2v_to_F2x 6013
F2x_clear 2115222
F2x_coeff 98376537
F2x_div 1134910
F2x_equal 1179874
F2x_equal1 150411
F2x_flip 338487
F2x_renormalize 56525174
F2x_set 32449492
Flm_copy 473812
Flm_row 28674
Flv_copy 1316215
Flx_copy 45410384
Flx_div 1403001
Flx_equal1 3783923
Flx_lead 401562
Flx_mulu 314413
FlxqX_div 6146
FlxqX_rem 161242
Flxq_add 0
Flxq_sub 0
FpV_FpC_mul 0
FpXQX_div 0
FpXQX_renormalize 857051
FpXQ_add 0
FpXQ_sub 0
FpXX_renormalize 913179
FpX_div 518859
FpX_renormalize 93574293
Fp_add 174121997
Fp_addmul 2428304
Fp_center 3103854
Fp_div 4661127
Fp_halve 22608
Fp_inv 7850681
Fp_invsafe 351370
Fp_mul 148952109
Fp_muls 231
Fp_mulu 61097563
Fp_neg 9906010
Fp_red 3410947
Fp_sqr 6434834
Fp_sub 62704841
FqXQ_add 0
FqXQ_div 23432
FqXQ_inv 0
FqXQ_invsafe 0
FqXQ_mul 144787
FqXQ_pow 0
FqXQ_sqr 55020
FqXQ_sub 0
FqX_Fp_mul 539321
FqX_Fq_mul 554817
FqX_add 901895
FqX_div 9597
FqX_div_by_X_x 5831
FqX_divrem 0
FqX_extgcd 37212
FqX_gcd 40754
FqX_mul 101395
FqX_mulu 463210
FqX_neg 5848
FqX_powu 1554
FqX_red 10094
FqX_rem 38572
FqX_sqr 6510
FqX_sub 142484
Fq_red 1544042
Fq_to_FpXQ 5294
GENbinbase 54780981
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 4839560
RgV_is_QV 0
RgV_is_ZV 1276554
RgV_isscalar 6385
RgXQX_div 7
RgXQX_rem 31668
RgXQ_mul 401735
RgXQ_sqr 215978
RgX_coeff 360510
RgX_copy 62224089
RgX_div 6054301
RgX_equal_var 4074252
RgX_fpnorml2 10225
RgX_gtofp 448602
RgX_is_QX 109354
RgX_is_ZX 55886562
RgX_is_monomial 14651162
RgX_is_rational 2429
RgX_isscalar 0
RgX_rem 2607628
RgX_renormalize 307097
RgX_shift_inplace 537545
RgX_shift_inplace_init 537542
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 12939
ZX_renormalize 79671519
Z_ispower 14
Z_issquare 231455
abgrp_get_cyc 892335
abgrp_get_gen 227568
abgrp_get_no 7994
absfrac 1326169
absfrac_shallow 11564
addmuliu 7000
addmuliu_inplace 264441212
affc_fixlg 175463
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 27391474
bit_accuracy 1121254213
bit_accuracy_mul 2501827
bit_prec 23928278
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 16137880
cbrtr 11355
cgetalloc 4737
cgetc 181544
cgiv 42529794
closure_arity 99214526
closure_codestr 87015895
closure_get_code 0
closure_get_data 86881143
closure_get_dbg 58141
closure_get_frame 82756
closure_get_oper 86960947
closure_get_text 118214
closure_is_variadic 12254294
col_ei 1167966
const_col 19787
const_vec 5719529
const_vecsmall 3229735
constant_term 17428083
cxcompotor 1611111
cxnorm 6686872
cxtofp 804440
cyclic_perm 0
dbllog2r 20797489
degpol 1543349263
divsBIL 3302164343
ellQp_get_p 245
ellQp_get_prec 84
ellQp_get_zero 336
ellR_get_prec 252
ellR_get_sign 688
ell_get_a1 1994551
ell_get_a2 1413526
ell_get_a3 2010361
ell_get_a4 2026334
ell_get_a6 2436240
ell_get_b2 2030014
ell_get_b4 444039
ell_get_b6 835409
ell_get_b8 688520
ell_get_c4 4723811
ell_get_c6 5083302
ell_get_disc 6408832
ell_get_j 946456
ell_get_type 6891623
ell_is_inf 18067859
ellff_get_a4a6 313290
ellff_get_field 794155
ellinf 406662
ellnf_get_nf 52885
equali1 170550611
equalim1 5765528
err_get_compo 77
err_get_num 130123
gabsz 0
gaddgs 7030201
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 21104
gdiventz 0
gdivsg 150506
gdivz 0
gen_I 411264
gener_Fq_local 462
gequalgs 22435
gerepileall 4302181
gerepilecoeffs 8
gerepilecopy 19707759
gerepilemany 37063
gerepileupto 420536294
gerepileuptoint 1048576348
gerepileuptoleaf 307950856
gmaxsg 0
gminsg 0
gmodz 0
gmul2nz 0
gmulgs 4882437
gmulz 11673
gnegz 0
gshiftz 0
gsubgs 398141
gsubz 0
gtodouble 24625154
gtofp 16319178
gtomp 22400
gtos 29925008
gtou 0
gval 427
icopy_avma 996411016
idealpseudomin 149487
idealpseudomin_nonscalar 230278
idealred 148704
idealred_elt 315
identity_perm 64470
inf_get_sign 20561
is_bigint 118645330
is_const_t 696341196
is_extscalar_t 591269
is_intreal_t 766364
is_matvec_t 303728440
is_noncalc_t 50405583
is_pm1 1326351219
is_rational_t 417666
is_recursive_t 2119417713
is_scalar_t 150502911
is_universal_constant 30874763
is_vec_t 282746
isint1 5000473
isintm1 301
isintzero 308802484
ismpzero 766287
isonstack 1819468211
killblock 993539
leading_term 64773932
leafcopy_avma 56789217
lgcols 24546415
lgpol 747047579
lincombii 17963412
matpascal 364
matslice 96726
mkcol 622697
mkcol2 12841077
mkcol2s 0
mkcol3 40369
mkcol3s 0
mkcol4 0
mkcol4s 0
mkcol5 0
mkcol6 351
mkcolcopy 27267
mkcols 0
mkcomplex 2615062
mkerr 0
mkfrac 43779
mkfraccopy 2478259
mkintmod 378964
mkintmodu 3675
mkmat 186499
mkmat2 9978602
mkmat3 2345
mkmat4 0
mkmat5 0
mkmatcopy 7203
mkmoo 5788
mkoo 9626
mkpolmod 238945
mkqfi 158109
mkquad 42
mkrfrac 7
mkrfraccopy 14
mkvec 2429869
mkvec2 11115697
mkvec2copy 167444
mkvec2s 10416
mkvec3 78714553
mkvec3s 492702
mkvec4 3652790
mkvec4s 7
mkvec5 11508075
mkveccopy 33180
mkvecs 7
mkvecsmall 29826822
mkvecsmall2 91979455
mkvecsmall3 35545150
mkvecsmall4 1482343
mkvecsmall5 104716
modpr_get_T 763417
modpr_get_p 2331
modpr_get_pr 1709096
mpcosz 0
mpexpz 0
mplogz 0
mpsinz 0
mul_content 238651
mul_denom 177071
mulsubii 1725107
nbits2extraprec 318348178
nbits2lg 2770993
nbits2nlong 714051
nbits2prec 71567827
nbrows 12693448
nchar2nlong 8749170
ndec2nlong 14207
ndec2prec 14207
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 6291341
odd 268104859
pari_calloc 36229
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 36186350
pari_malloc 110772860
pari_realloc 107254
pari_stack_alloc 234455841
pari_stack_base 234493040
pari_stack_delete 27723
pari_stack_init 57268
pari_stack_new 206578809
pari_stack_pushp 9292
perm_conj 35
perm_inv 98
perm_mul 18123735
pol0_F2x 2179976
pol0_Flx 27891657
pol1_F2x 631872
pol1_Flx 9914831
pol_0 14305307
pol_1 788291
pol_x 345146
polx_F2x 192712
polx_Flx 5922939
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 54992415
prec2nbits_mul 233098
prec2ndec 6120
precdbl 1667
qfb_disc 3716342
qfb_disc3 3786636
quad_disc 259
quadnorm 623
remsBIL 3227265634
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 1188884
shallowcopy 207070
sqrfrac 91036
sqrti 2452734
sqrtnr 32019
sqrtr 6537837
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 204328
vecpermute 4339794
vecreverse 50883
vecreverse_inplace 225
vecslice 3346006
vecslicepermute 86688
vecsmall_append 357089
vecsmall_coincidence 0
vecsmall_concat 230658
vecsmall_copy 25269924
vecsmall_ei 7196
vecsmall_indexmax 14
vecsmall_indexmin 14
vecsmall_isin 111174
vecsmall_lengthen 0
vecsmall_lexcmp 2586374
vecsmall_max 3779
vecsmall_min 133
vecsmall_pack 84
vecsmall_prefixcmp 35286195
vecsmall_prepend 784
vecsmall_shorten 5796
vecsmall_to_col 446390
vecsmall_to_vec 7559
vecsmallpermute 17816183
vecsmalltrunc_append 2281459
vecsmalltrunc_init 1201824
vecsplice 4984
vectrunc_append 1154401
vectrunc_append_batch 0
vectrunc_init 703356
zc_to_ZC 427350
zero_F2m 0
zero_F2m_copy 96798
zero_F2v 682339
zero_F2x 77
zero_Flm 315
zero_Flm_copy 23532
zero_Flv 19329851
zero_Flx 100154
zero_zm 0
zero_zv 13407195
zero_zx 0
zerocol 23122701
zeromat 5600
zeromatcopy 2007204
zeropadic 275436
zeropadic_shallow 315
zeropol 4393046
zeroser 5229
zerovec 5800070
zm_copy 0
zm_row 0
zm_to_zxV 0
zm_transpose 91
zv_copy 1019065
zv_to_ZV 6370
zv_to_zx 0
zx_renormalize 0
zx_shift 0
zx_to_zv 0

Generated by: LCOV version 1.9