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 to exceed 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 - FpXX.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.16.2 lcov report (development 29395-ef22f77854) Lines: 950 1214 78.3 %
Date: 2024-06-15 09:03:40 Functions: 114 134 85.1 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
FpXQXQ_div 0
FpXQXQ_inv 0
FpXQXQ_invsafe 0
FpXQXQ_matrix_pow 0
FpXQXT_red 0
FpXQXV_red 0
FpXQX_extgcd_basecase 0
FpXQX_extgcd_halfgcd 0
FpXQX_halfres 0
FpXQX_halfres_update 0
FpXQX_to_mod_raw 0
FpXQXn_exp 0
FpXQXn_sqr 0
FpXX_integ 0
FqXC_to_mod_raw 0
FqXM_to_mod 0
FqX_to_mod_raw 0
get_FpXQX_algebra 0
matJ2_FpXQXM 0
matid2_FpXQXM 0
FpXQXQ_auttrace_mul 1
FpXQXQ_auttrace_sqr 1
FpXQXQ_auttrace 8
FqXC_to_mod 14
FpXQX_resultant_basecase 28
FpXQX_disc 35
FpXQXQ_minpoly 44
FpXQX_halfgcd 44
polxn_FpXX 44
random_FpXQX 52
FpXQX_powu 63
FpXQX_resultant 63
FpXQXQ_transmul_init 88
FpXQX_halfgcd_all 114
FpXQX_halfgcd_all_i 114
ZXX_copy 126
_FpXQXQ_zero 132
FpXY_FpXQ_evalx 154
FpXQXM_mul2 161
FpXQX_FpXQXM_qmul 161
FpXQXn_expint 178
FpXYQQ_pow 182
FpXQXV_FpXQX_fromdigits 189
FpXYQQ_mul 196
FpXQXQ_transmul 200
FpXQX_halfres_split 215
FpXQX_recipspec 248
FpXQX_halfres_basecase 275
FpXYQQ_sqr 280
FpXQXQ_autpow_mul 325
get_FpXQXQ_algebra 352
FpXQXM_FpXQX_mul2 376
FpXQX_dotproduct 396
FpXYQQ_redswap 476
FpXQX_halfres_i 490
FpXQXQ_autpow 493
FpXQXQ_autpow_sqr 507
FpXQX_to_mod 525
FpXQX_invBarrett_Newton 537
FpXQX_digits 623
FpXQXn_div 714
FpXQXn_inv 714
ZlXQXn_expint 714
FpXQX_addmulmul 752
FpXX_integXn 763
FpXQX_FpXQXQ_eval 855
FpXQXQ_autsum 1233
FpXQXQ_autsum_sqr 1275
FpXQXQ_autsum_mul 1433
_FpXQX_sqr 1729
FpXQXQ_pow 1908
FpXQXQ_powers 1965
FpXX_neg 2073
to_intmod 2191
FpXX_halve 2240
ZlXX_integXn 2702
FpXQX_invBarrett_basecase 2918
FpXQX_invBarrett 3476
FpXY_FpXQV_evalx 3852
FpXQX_gcd_basecase 3896
FpXQX_FpXQXQV_eval 4191
_FpXQX_sub 4638
FpXQXn_mulhigh 4690
FpXX_mulu 7116
FpXQX_mulhigh_i 7392
FpXXn_red 8428
_FpXQX_divrem 9954
FpXQX_get_red 12685
FpXX_deriv 13405
FpXY_eval 13657
FpXQX_gcd 14545
FpXY_FpY_mulspec 15179
FpXQXV_prod 16678
FpXY_evaly 18799
_FpXQXQ_one 18963
FpXX_shift 19490
_FpXQXQ_red 22956
FpXX_sub 30880
Fq_addmul 36478
FpXX_red 39934
FpXQXn_mul 44552
_FpXQXQ_mul 45926
FpXQXQ_mul 49194
FpXY_evalx 51552
to_ZX 53770
FpXX_Fp_mul 56452
FpXQX_div_by_X_x 71939
FpXQX_divrem_Barrett 85254
_FpXQX_mul 118444
_FpXQX_add 121791
FpXX_FpX_mul 125645
_FpXQXQ_cmul 125668
FpXQX_extgcd 133610
FpXX_FpX_mulspec 140824
FpXX_subspec 152221
FpXQX_divrem_Barrettspec 153180
FpXQX_divrem_basecase 173365
FpXQXQ_sqr 176117
_FpXQXQ_sqr 176117
FpXQX_sqr 186666
ZXX_is_ZX 246002
FpXQX_rem 263338
FpXX_recipspec 306360
ZXX_lgrenormalizespec 316761
FpXX_add 446115
FpXQX_FpXQ_mul 553166
FpXQX_divrem 1069304
to_FlxqX 1251294
get_FpXQX_red 1332724
FpXQX_mul 1384469
FpXQX_mulspec 1696780
Kronecker_to_FpXQX 1891018
FpXQX_red 1937194
ZXX_is_ZX_spec 3639937

Generated by: LCOV version 1.16