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 - gen1.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.18.0 lcov report (development 29732-95c6201d93) Lines: 1936 2061 93.9 %
Date: 2024-11-21 09:08:54 Functions: 101 101 100.0 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
Leading_is_neg 57829169
Q_to_Fp 226838
Qdivii 134776645
Qdivis 1561541
Qdiviu 136241279
Zp_nosquare_m1 42
_serprec 7161978
addQp 4760434
addRc 303688715
addRq 1274
addTp 7
add_intmod_same 3690738
add_rfrac 3039747
add_rfrac_scal 8830966
add_scal 26105617
add_ser_scal 408094
addqf 77
addsub_frac 28598589
addsub_frac_i 14115036
addsub_polmod 7203
addsub_polmod_scal 13424845
addsub_pp 19953703
conj_i 19376365
conjvec 84
divRc 2352446
divTp 3660
div_T_scal 6684447
div_intmod_same 341872
div_polmod_same 36743
div_rfrac 1186775
div_rfrac_pol 271003
div_rfrac_scal 13169
div_scal_T 9267139
div_scal_pol 9257904
div_scal_rfrac 37515
div_scal_ser 18550
div_ser 771510
div_ser_scal 1338593
divcR 23095652
divfq 42
divpT 1203979
divpp 13211471
divqf 63
divrunextu 224116874
fill_ser 5693888
fix_rfrac 248374
gadd 5882520434
gaddsg 270555078
gconj 132621
gdiv 432446562
gdivgs 12936196
gdivgu 54707540
gdivgunextu 813628
ginv 36430630
gmul 8516194089
gmul2n 124673525
gmulsg 229474560
gmulug 124319642
gred_rfrac2 44766311
gred_rfrac_simple 57833419
gsqr 1122236174
gsub 2828210555
gsubsg 3167095
init_ser 5706235
inv_polmod 209288
is_ext_qfr 98
kro_quad 28
mulRc 350756706
mulRc_direct 49
mulRq 2352
mulTp 4981695
mul_gen_rfrac 160886
mul_intmod_same 3103602
mul_polmod 2675106
mul_polmod_same 8562230
mul_polmod_scal 3427497
mul_rfrac 7907310
mul_rfrac_scal 10452370
mul_scal 121962745
mul_ser_scal 316288
mulcIR 11663932
mulcc 273686407
mulcxI 15627294
mulcxmI 3079398
mulcxpowIs 5524131
mulpp 17470427
mulqf 28
mulqq 1106
mulrfrac 37454002
quad_polmod_conj 18326
quad_polmod_mul 5858586
quad_polmod_norm 18326
rfrac_denom_mul_scal 9857265
ser_add 3581388
ser_normalize 7630
setfrac 14921071
sqr_polmod 484324
sqr_ser_part 112731
sub_intmod_same 1158553
transtype 154482723
warn_coercion 105

Generated by: LCOV version 1.16