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 - polarit2.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.10.0 lcov report (development 21188-db834f2) Lines: 1691 1867 90.6 %
Date: 2017-10-20 06:23:07 Functions: 145 152 95.4 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
FE_matconcat 84
FpV_factorback 97461
Fpmul 23786
Fppow 121247
Lazard 19277
Lazard2 19481
Q_content 94685
Q_content_safe 104063844
Q_denom 54139022
Q_div_to_int 6549
Q_divi_to_int 14902850
Q_divmuli_to_int 4010557
Q_divq_to_int 2177330
Q_gcd 74490211
Q_mul_to_int 0
Q_muli_to_int 29375821
Q_primitive_part 12853558
Q_primpart 1388123
Q_remove_denom 11477034
R_to_Q_down 826
R_to_Q_up 826
RgM_rescale_to_int 222780
RgXQ_charpoly 14419
RgXQ_inv 17321
RgXQ_inv_FpXQ 21
RgXQ_inv_FpXQXQ 7
RgXQ_inv_fast 17321
RgXQ_inv_i 867
RgXQ_ratlift 70
RgXY_factor 84
RgXY_factor_squarefree 91
RgXY_squff 84
RgX_Frobenius_deflate 28
RgX_Rg_mul_i 58779
RgX_cmbf 4487
RgX_disc 1799
RgX_disc_aux 4858
RgX_extgcd 343
RgX_extgcd_simple 0
RgX_gcd 10896736
RgX_gcd_simple 87164
RgX_is_irred 63
RgX_is_irred_i 63
RgX_neg_i 19481
RgX_rescale_to_int 238
RgX_resultant_all 20236
RgX_settype 102673729
RgX_simpletype 96823
RgX_sturmpart 133
RgX_type 6402210
RgX_type2 48841594
RgX_type_decode 404919
RgX_type_is_composite 856088
ZX_content 37188
_pol_0 0
c_is_rational 112
c_zero_gcd 70
caract_const 140
centermod 4795458
centermod_i 8362535
centermodii 112262383
choosetype 54039163
code 169773
cont_gcd 3071546
cont_gcd_gen 6532
cont_gcd_pol 2256919
cont_gcd_rfrac 864876
content 77280822
deg1_from_roots 84053
eltmul 4165
eltpow 16962
factor 41223
factor0 0
factorback 1322108
factorback2 15807129
fix_lcm 133
fix_pol 3374
gauss_cmp 77
gauss_factor 42
gauss_factor_p 35
gauss_gcd 126
gauss_normal 189
gauss_primpart 42
gauss_primpart_try 70
gbezout 280
gcdext0 280
gcdiq 2172175
gcdmonome 7444850
gcdqq 5566983
gdivexact 1888807
gen_factorback 15931827
ggcd 24065941
ggcd0 3960
ginvmod 2737
glcm 3066
glcm0 2891
gp_factor0 37114
idealfactorback 1806
idmul 2142
idmulred 21
idpow 3290
idpowred 623
inexact 26513880
init_resultant 59832
isinexactall 6944498
isirreducible 63
mul 35829557
must_negate 90188
newtonpoly 28
nextSousResultant 19481
nffactorback 13307
normalized_mul 575138
normalized_to_RgX 281274
padic_gcd 2684
pol_approx0 302589
poldisc0 3073
polresultant0 1904
polresultantext 840
polresultantext0 868
polsym 17731
polsym_gen 29799
powi 51615058
primitive_part 1001751
primpart 2835
reduceddiscsmith 7
reductum_lg 55881
rescale_init 1826864
resultant 51138
resultant2 8694
rnfcharpoly 224
roots_from_deg1 980
roots_to_pol 241397
roots_to_pol_r1 39912
s_centermod 0
scalar_bezout 112
scalar_res 0
settype 384192130
sturmpart 840
sturmpart_i 840
subres_step 5130
subresext 0
subresext_i 1735
sylvester_col 72408
sylvestermatrix 7
sylvestermatrix_i 8701
triv_cont_gcd 357
vec_Q_primpart 98806
vecprod 14
zero_bezout 63
zero_extgcd 28
zero_gcd 8197519
zero_gcd2 8749086

Generated by: LCOV version 1.11