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 16827-3d78da8) Lines: 1143 1291 88.5 %
Date: 2014-09-29 Functions: 469 538 87.2 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 495 604 82.0 %

Function Name Sort by function name Hit count Sort by hit count
F2m_clear 0
F2m_coeff 13872800
F2m_copy 1400
F2m_flip 330344
F2m_set 2200727
F2v_clear 1843274
F2v_coeff 81719477
F2v_copy 0
F2v_ei 7
F2v_flip 330344
F2v_set 14433943
F2v_to_F2x 5705
F2x_clear 1843274
F2x_coeff 82314786
F2x_div 980210
F2x_equal 952525
F2x_equal1 1387
F2x_flip 330344
F2x_renormalize 51587011
F2x_set 32012066
Flm_copy 457386
Flv_copy 707912
Flx_copy 33228221
Flx_div 1215427
Flx_equal1 2711481
Flx_lead 63432
Flx_mulu 131531
FlxqX_div 4837
FlxqX_rem 53978
Flxq_add 0
Flxq_sub 0
FpV_FpC_mul 0
FpXQX_div 0
FpXQX_renormalize 506381
FpXQ_add 0
FpXQ_sub 0
FpXX_renormalize 444435
FpX_div 516107
FpX_renormalize 78469114
Fp_add 37517920
Fp_addmul 2309822
Fp_center 2602686
Fp_div 1922940
Fp_halve 13932
Fp_inv 4275878
Fp_invsafe 310304
Fp_mul 22556877
Fp_muls 231
Fp_mulu 24324785
Fp_neg 9053794
Fp_red 2637569
Fp_sqr 4987243
Fp_sub 46824871
FqXQ_add 0
FqXQ_div 15655
FqXQ_inv 0
FqXQ_invsafe 0
FqXQ_mul 36833
FqXQ_pow 0
FqXQ_sqr 15981
FqXQ_sub 0
FqX_Fp_mul 400427
FqX_Fq_mul 418064
FqX_add 696090
FqX_div 3206
FqX_divrem 0
FqX_extgcd 29757
FqX_gcd 10122
FqX_mul 43491
FqX_mulu 352643
FqX_neg 3748
FqX_red 2968
FqX_rem 11381
FqX_sqr 1533
FqX_sub 75774
Fq_red 1154189
GENbinbase 49460872
QV_isscalar 5250363
Q_abs 234160
Q_abs_shallow 28882
RgC_fpnorml2 116284
RgC_gtofp 239918
RgC_gtomp 560
RgM_dimensions 114217
RgM_fpnorml2 574
RgM_gtofp 17387
RgM_gtomp 14
RgM_inv 27451
RgM_minor 371
RgM_shallowcopy 4615529
RgV_is_QV 0
RgV_is_ZV 1260876
RgV_isscalar 6272
RgXQX_div 0
RgXQX_rem 10584
RgXQ_mul 280309
RgXQ_sqr 137120
RgX_coeff 5411
RgX_copy 56969370
RgX_div 6053245
RgX_equal_var 863301
RgX_fpnorml2 8624
RgX_gtofp 380524
RgX_is_QX 5250
RgX_is_ZX 53562741
RgX_is_monomial 14722895
RgX_is_rational 665
RgX_isscalar 0
RgX_rem 1410273
RgX_renormalize 161735
RgX_shift_inplace 472896
RgX_shift_inplace_init 472896
Rg_col_ei 3102226
ZC_hnfrem 783456
ZM_hnfrem 25725
ZM_lll 1080342
ZV_dvd 23198
ZV_isscalar 1192488
ZV_to_zv 192828
ZXQ_mul 86814
ZXQ_sqr 13496
ZX_ZXY_resultant 0
ZX_equal1 12717
ZX_renormalize 67925502
Z_ispower 14
Z_issquare 230149
abgrp_get_cyc 883732
abgrp_get_gen 225153
abgrp_get_no 7896
absfrac 1090023
absfrac_shallow 7819
addmuliu 7000
addmuliu_inplace 232349495
affc_fixlg 26719
affgr 3203486
bid_get_arch 98249
bid_get_cyc 457744
bid_get_gen 4809
bid_get_gen_nocheck 0
bid_get_grp 463589
bid_get_ideal 73221
bid_get_mod 284087
bid_get_no 0
bin_copy 24734394
bit_accuracy 942567234
bit_accuracy_mul 2105499
bit_prec 20589400
bnf_get_clgp 459385
bnf_get_cyc 239398
bnf_get_fu 6209
bnf_get_fu_nocheck 11270
bnf_get_gen 219245
bnf_get_logfu 340336
bnf_get_nf 894893
bnf_get_no 595
bnf_get_reg 371
bnf_get_tuN 7182
bnf_get_tuU 5670
bnr_get_bid 170042
bnr_get_bnf 341862
bnr_get_clgp 194304
bnr_get_cyc 185554
bnr_get_gen 1386
bnr_get_gen_nocheck 63
bnr_get_mod 8939
bnr_get_nf 2079
bnr_get_no 7301
both_odd 42696953
cgetalloc 2632
cgetc 45797
cgiv 38449472
closure_arity 87703281
closure_codestr 76795740
closure_get_code 0
closure_get_data 76792957
closure_get_dbg 2913
closure_get_frame 1022
closure_get_oper 76795740
closure_get_text 6437
closure_is_variadic 10899853
col_ei 1093796
const_col 15678
const_vec 5419269
const_vecsmall 3070228
constant_term 17398665
cxcompotor 1133449
cxnorm 5301603
cxtofp 565875
cyclic_perm 0
dbllog2r 12877481
degpol 1237182654
divsBIL 2759048080
ellQp_get_p 245
ellQp_get_prec 84
ellQp_get_zero 336
ellR_get_prec 252
ellR_get_sign 667
ell_get_a1 1945343
ell_get_a2 1408744
ell_get_a3 1961758
ell_get_a4 2021909
ell_get_a6 2432039
ell_get_b2 1985796
ell_get_b4 432895
ell_get_b6 824167
ell_get_b8 688023
ell_get_c4 4691250
ell_get_c6 5051218
ell_get_disc 6273757
ell_get_j 880677
ell_get_type 6689621
ell_is_inf 19954891
ellff_get_a4a6 255941
ellff_get_field 576555
ellinf 397697
ellnf_get_nf 49035
equali1 158180188
equalim1 55970
err_get_compo 77
err_get_num 19839
gabsz 0
gaddgs 1448612
gaddz 46636
gal_get_den 1512
gal_get_e 42
gal_get_gen 875
gal_get_group 791
gal_get_invvdm 1512
gal_get_mod 1498
gal_get_orders 413
gal_get_p 924
gal_get_pol 868
gal_get_roots 1855
gcmpgs 9765
gdiventz 0
gdivsg 96190
gdivz 0
gen_I 164912
gener_Fq_local 385
gequalgs 5586
gerepileall 3638242
gerepilecoeffs 8
gerepilecopy 18539207
gerepilemany 36799
gerepileupto 361497180
gerepileuptoint 698171967
gerepileuptoleaf 194494679
gmaxsg 0
gminsg 0
gmodz 0
gmul2nz 0
gmulgs 1992188
gmulz 23346
gnegz 0
gshiftz 0
gsubgs 396348
gsubz 0
gtodouble 5093010
gtofp 6202888
gtomp 22400
gtos 28092039
gtou 0
gval 2331
icopy_avma 753552653
idealpseudomin 140258
idealpseudomin_nonscalar 219720
idealred 139503
idealred_elt 308
identity_perm 63714
inf_get_sign 11344
is_bigint 109347042
is_const_t 543274329
is_extscalar_t 547751
is_intreal_t 500687
is_matvec_t 292240830
is_noncalc_t 50023268
is_pm1 709456104
is_rational_t 108915
is_recursive_t 1757208904
is_scalar_t 148735525
is_universal_constant 15752309
is_vec_t 717913
isint1 3997827
isintm1 0
isintzero 250653295
ismpzero 500589
isonstack 1292623625
killblock 953757
leading_term 57365961
leafcopy_avma 41023946
lgcols 19328627
lgpol 510130771
lincombii 13165790
matpascal 273
mkcol 601502
mkcol2 11568340
mkcol2s 0
mkcol3 40299
mkcol3s 0
mkcol4 0
mkcol4s 0
mkcol5 0
mkcolcopy 25541
mkcols 0
mkcomplex 2908907
mkerr 0
mkfrac 40238
mkfraccopy 1363259
mkintmod 364725
mkintmodu 3535
mkmat 184171
mkmat2 8650110
mkmat3 2996
mkmat4 0
mkmat5 0
mkmatcopy 5117
mkmoo 3584
mkoo 5854
mkpolmod 63896
mkqfi 158109
mkquad 63
mkrfrac 7
mkrfraccopy 14
mkvec 1624547
mkvec2 12528384
mkvec2copy 164028
mkvec2s 8868
mkvec3 19616453
mkvec3s 492492
mkvec4 3589566
mkvec4s 7
mkvec5 11544319
mkveccopy 32732
mkvecs 7
mkvecsmall 21407853
mkvecsmall2 89298210
mkvecsmall3 31542198
mkvecsmall4 405479
mkvecsmall5 161
mpcosz 0
mpexpz 0
mplogz 0
mpsinz 0
mul_content 196432
mul_denom 155651
mulsubii 1273495
nbits2extraprec 208983671
nbits2lg 2359988
nbits2nlong 737722
nbits2prec 66018096
nbrows 11178021
nchar2nlong 8483319
ndec2nlong 15876
ndec2prec 15876
nf_get_G 35475
nf_get_M 854387
nf_get_Tr 784
nf_get_degree 2386165
nf_get_diff 777
nf_get_disc 17479
nf_get_index 416226
nf_get_invzk 1010203
nf_get_pol 5202553
nf_get_r1 918957
nf_get_r2 273
nf_get_roots 38266
nf_get_roundG 321718
nf_get_sign 3584
nf_get_varn 3185
nf_get_zk 5330112
normalize_frac 3914764
odd 159310407
pari_calloc 18851
pari_err_BUG 0
pari_err_COMPONENT 203
pari_err_CONSTPOL 7
pari_err_COPRIME 42
pari_err_DIM 179
pari_err_DOMAIN 1201
pari_err_FILE 0
pari_err_FLAG 7
pari_err_IMPL 112
pari_err_INV 651
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 63
pari_err_ROOTS0 35
pari_err_SQRTN 70
pari_err_TYPE 10079
pari_err_TYPE2 2786
pari_err_VAR 490
pari_free 32863621
pari_malloc 100071276
pari_realloc 60853
pari_stack_alloc 211552648
pari_stack_base 211576805
pari_stack_delete 16683
pari_stack_init 23157
pari_stack_new 185192517
pari_stack_pushp 7467
perm_conj 35
perm_inv 56
perm_mul 17718585
pol0_F2x 1745402
pol0_Flx 19817280
pol1_F2x 508555
pol1_Flx 8893074
pol_0 10498229
pol_1 575073
pol_x 275305
polx_F2x 172352
polx_Flx 5218401
polx_zx 0
powIs 805
powii 299445
pr_get_e 1120260
pr_get_f 3593308
pr_get_gen 1652127
pr_get_p 5075158
pr_get_tau 2202079
pr_is_inert 469996
pr_norm 66625
prec2nbits 40639219
prec2nbits_mul 49754
prec2ndec 3718
precdbl 1572
qfb_disc 3716216
qfb_disc3 3786503
quad_disc 182
quadnorm 1064
remsBIL 2690379764
resultant 24675
rnf_get_absdegree 182
rnf_get_degree 917
rnf_get_disc 140
rnf_get_index 105
rnf_get_invzk 1057
rnf_get_map 1344
rnf_get_nf 4942
rnf_get_nfdegree 539
rnf_get_nfpol 4634
rnf_get_nfvarn 56
rnf_get_nfzk 735
rnf_get_pol 7077
rnf_get_polabs 1820
rnf_get_varn 0
rnf_get_zk 1925
row 113161
row_Flm 24237
row_i 1960
row_zm 0
rowcopy 21
rowpermute 132702
rowslice 92796
rowslicepermute 18896
ser_isexactzero 631530
shallowcopy 186143
sqrfrac 124292
sqrti 2438836
sqrtnr 27048
sqrtr 6191861
sturm 7
submulii 35206167
submuliu 7000
submuliu_inplace 232625220
truecoeff 7
trunc_safe 0
vec_append 54894
vec_ei 296773
vec_lengthen 7574
vec_setconst 1701
vec_shorten 0
vec_to_vecsmall 201228
vecpermute 4193548
vecreverse 1120
vecreverse_inplace 218
vecslice 1609623
vecslicepermute 82732
vecsmall_append 353612
vecsmall_coincidence 0
vecsmall_concat 192290
vecsmall_copy 21902689
vecsmall_ei 7196
vecsmall_indexmax 14
vecsmall_indexmin 14
vecsmall_isin 0
vecsmall_lengthen 448
vecsmall_lexcmp 2586374
vecsmall_max 1638
vecsmall_min 0
vecsmall_pack 84
vecsmall_prefixcmp 35286195
vecsmall_prepend 749
vecsmall_shorten 4193
vecsmall_to_col 417817
vecsmall_to_vec 5473
vecsmallpermute 17411747
vecsmalltrunc_append 2226120
vecsmalltrunc_init 1186495
vecsplice 4067
vectrunc_append 786162
vectrunc_append_batch 0
vectrunc_init 532744
zc_to_ZC 399323
zero_F2m 0
zero_F2m_copy 91887
zero_F2v 731034
zero_F2x 77
zero_Flm 133
zero_Flm_copy 11676
zero_Flv 17969498
zero_Flx 44469
zero_zm 0
zero_zv 12512340
zero_zx 0
zerocol 19462566
zeromat 5306
zeromatcopy 1807054
zeropadic 10815
zeropadic_shallow 315
zeropol 3977322
zeroser 8274
zerovec 5410725
zm_copy 0
zm_to_zxV 0
zm_transpose 91
zv_copy 540226
zv_to_ZV 4277
zv_to_zx 0
zx_renormalize 0
zx_shift 0
zx_to_zv 0

Generated by: LCOV version 1.9