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 - basemath - FpX_factor.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.10.0 lcov report (development 21741-70cf009) Lines: 1520 1637 92.9 %
Date: 2018-01-21 06:18:30 Functions: 134 141 95.0 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
F2xV_to_FlxV_inplace 18452
F2xV_to_ZXV_inplace 141379
F2x_Berlekamp_i 153342
F2x_Berlekamp_ker 19455
F2x_ddf_simple 26416
F2x_degfact 0
F2x_degfact_2 7035
F2x_edf_simple 12806
F2x_factcantor 15165
F2x_factcantor_i 30684
F2x_factor 14
F2x_factor_2 99946
F2x_factor_Cantor 17805
F2x_factor_Shoup 24472
F2x_factor_deg2 106988
F2x_factor_squarefree 76801
F2x_is_irred 238
F2x_is_irred_2 7
F2x_isirred_Cantor 238
F2x_quad_factortype 58646
F2x_simplefact_Cantor 1736
F2x_simplefact_Shoup 1778
F2x_split_Berlekamp 52920
F2xq_frobtrace 8332
FE_concat 400469
FE_setlg 418751
Fl_disc_bc 21221257
Fl_nonsquare 6
FlxV_to_ZXV_inplace 712524
Flx_Berlekamp_i 778331
Flx_Berlekamp_ker 281150
Flx_Xn1 6
Flx_Xnm1 13
Flx_addmul_inplace 1246893
Flx_cubic_root 171483
Flx_cut_out_roots 14
Flx_ddf 653456
Flx_degfact 1097362
Flx_degfact_2 737877
Flx_edf 18877
Flx_edf_rec 32701
Flx_edf_simple 45767
Flx_factcantor 7628
Flx_factcantor_i 1138998
Flx_factor 101642
Flx_factor_2 409430
Flx_factor_Cantor 29899
Flx_factor_Shoup 33017
Flx_factor_deg2 1147307
Flx_factor_squarefree 742876
Flx_is_irred 581
Flx_is_irred_2 0
Flx_isirred_Cantor 581
Flx_ispower 126
Flx_nbfact 81319
Flx_nbfact_Frobenius 81319
Flx_nbfact_by_degree 186688
Flx_nbroots 2402593
Flx_oneroot 3068468
Flx_oneroot_i 3107116
Flx_oneroot_mod_2 49
Flx_oneroot_split 31438
Flx_otherroot 12258178
Flx_quad_factortype 720734
Flx_quad_root 20503294
Flx_root_mod_2 8659
Flx_roots 21944448
Flx_roots_i 22002715
Flx_roots_naive 14
Flx_simplefact_Cantor 351008
Flx_simplefact_Shoup 351990
Flx_split_Berlekamp 370782
FpX_Berlekamp_i 851786
FpX_Berlekamp_ker 171
FpX_ddf 4242
FpX_degfact 0
FpX_degfact_2 14
FpX_edf 14
FpX_edf_rec 210
FpX_edf_simple 0
FpX_factcantor 0
FpX_factcantor_i 49
FpX_factor 851681
FpX_factor_2 174
FpX_factor_Cantor 7
FpX_factor_Shoup 14
FpX_factor_Yun 453
FpX_factor_deg2 195
FpX_factor_squarefree 742
FpX_is_irred 14
FpX_is_irred_2 7
FpX_is_totally_split 0
FpX_isirred_Cantor 0
FpX_ispower 168
FpX_nbfact 28
FpX_nbfact_Frobenius 4214
FpX_nbroots 99085
FpX_oneroot 11543
FpX_oneroot_i 4284
FpX_oneroot_split 665
FpX_otherroot 2922
FpX_quad_factortype 21
FpX_quad_root 6916
FpX_roots 70157
FpX_roots_i 2854
FpX_simplefact_Cantor 14
FpX_simplefact_Shoup 14
FpX_split_Berlekamp 177
FpX_split_part 142528
Mod0pX 14
ZX_factmod_init 933395
all_roots_mod_p 42
cmpGuGu 2869849
ddf_to_nbfact 85715
ddf_to_simplefact 352004
deg1_Flx 151412
factcantor 70
factcantor0 112
factcantor_i 112
factmod 154
factmod_aux 266
factmod_init 350
factormod0 126
good_root_of_unity 238
prime_fact 77
rootmod 70
rootmod0 84
rootmod2 14
rootmod_aux 70241
simplefactmod 42
split_Flx_cut_out_roots 4990916
split_add 5232512
split_add_done 383038
split_done 364018
split_init 4993862
split_moveto_done 5232576
split_nonsquares 12
split_squares 12
split_todo 331533
trivial_fact 952
zero_fact_intmod 14

Generated by: LCOV version 1.11