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 - ZV.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.18.1 lcov report (development 29877-9124a6ce27) Lines: 800 938 85.3 %
Date: 2025-01-18 09:08:44 Functions: 122 139 87.8 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
ZC_ZV_mul 0
ZC_Z_sub 0
ZM_max_expi 0
ZM_max_expi_i 0
ZM_multosym 0
ZM_nc_mul_i 0
ZM_nm_mul 0
ZM_pow 0
ZM_reducemodlll 0
ZM_sqr_fast 0
ZM_sqr_slice 0
ZM_sqr_worker 0
ZM_togglesign 0
ZV_max_expi 0
ZV_max_expi_i 0
nm_Z_mul 0
zv_sumpart 0
ZM_mul_diag 21
ZMV_to_zmV 49
ZV_sum 77
zv_abs 77
zmV_to_ZMV 126
zv_neg_inplace 126
_ZM_mul 280
ZM_divexactu 441
QM_sqr 700
ZM_mul_fast 839
ZM_to_zm 1022
ZM_mul_slice 1105
ZM_mul_worker 1105
zvV_equal 1638
zv_ZM_mul 1736
ZC_divexactu 2261
ZM_transmul 2289
ZM_supnorm 4197
ZV_max_lg 10640
ZMrow_equal0 16231
zv_sum 16495
ZM_Z_div 18064
ZV_abscmp 19740
ZM_max_lg 22297
zm_to_Flm 22694
ZM_powu 22799
_ZM_sqr 23324
ZM_sqr 24395
ZM_sqr_i 24395
zv_z_mul 28461
zv_neg 51686
ZC_z_mul 62109
ZM_equal0 72442
ZM_mul_sw 73586
ZM_sub 91380
ZC_reducemodlll 97939
ZC_reducemodmatrix 111416
ZC_reducemodmatrix_i 111416
QM_QC_mul 126563
zm_to_ZM 156279
ZM_isscalar 157398
ZC_is_ei 165366
ZM_reducemodmatrix_i 227036
ZM_reducemodmatrix 227037
ZV_ZM_mul 230629
ZV_equal 295008
ZV_content 297354
ZV_neg_inplace 344127
Zupdate_row 360426
ZC_Z_add 365298
zv_to_Flv 366646
ZM_hnfdivrem 454428
ZV_to_nv 466212
ZM_Z_divexact 471503
subtract_slices 515102
ZM_transmultosym 532221
ZM_diag_mul 533942
Z_ZC_sub 545764
ZM_isdiagonal 556617
QM_mul 557793
add_slices 588688
ZM_copy 638597
RgM_check_ZM 650455
ZM_isidentity 654772
ZC_lincomb_1 739847
ZM_ishnf 751694
ZM_add 878660
zv_prod 950593
ZM_zm_mul 975273
ZRED 1035729
ZM_Q_mul 1089411
ZincrementalGS 1187354
RgV_check_ZV 1421565
ZM_neg 1658298
zv_prod_Z 1864469
check_ZV 1930897
ZV_zc_mul 2229528
ZC_Q_mul 2719207
ZV_cmp 3147067
ZM_Z_mul 3216545
ZM_equal 3325903
ZC_Z_div 3663923
ZM_det_triangular 3952466
ZV_togglesign 5035752
ZC_Z_divexact 5271591
ZV_equal_lg 6226192
ZC_neg 6300213
ZV_dotsquare 6658998
ZC_sub 8754937
ZV_prod 8829254
ZC_sub_i 9054067
ZC_hnfdivrem 10748742
ZM_mul_classical 13286453
sw_bound 13360040
ZV_equal0 14390739
vecsmall_prod 14694393
ZC_copy 14704735
ZC_lincomb1 15381977
ZV_dotproduct 16193190
ZM_zc_mul 17213010
zv_content 18455108
ZV_dotproduct_i 19182311
ZM_zc_mul_i 19276681
ZM_mul 20287174
ZM_mul_i 20665623
zv_equal0 23103586
ZM_ZC_mul 24111686
ZC_add 26013438
ZM_max_lg_i 26719680
Flc_lincomb1_inplace 29697729
zv_equal 30984892
ZC_lincomb 33271970
ZC_Z_mul 34634691
ZC_add_i 36134790
ZC_lincomb1_inplace 62148665
ZC_lincomb1_inplace_i 73083535
ZM_ZC_mul_i 74542158
ZV_max_lg_i 108211305
ZMrow_ZC_mul 135146023
zv_dotproduct 196399119
_mulii 318571093
ZMrow_ZC_mul_i 575136887

Generated by: LCOV version 1.16