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.16.2 lcov report (development 29115-f22e516b23) Lines: 1935 2060 93.9 %
Date: 2024-05-05 08:08:07 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 57828735
Q_to_Fp 23957
Qdivii 129196323
Qdivis 1518560
Qdiviu 131659232
Zp_nosquare_m1 42
_serprec 7123404
addQp 2390117
addRc 301980846
addRq 1274
addTp 7
add_intmod_same 3690458
add_rfrac 3039474
add_rfrac_scal 8830987
add_scal 22896887
add_ser_scal 401228
addqf 77
addsub_frac 27962124
addsub_frac_i 13748453
addsub_polmod 2142
addsub_polmod_scal 13511208
addsub_pp 8081420
conj_i 19098889
conjvec 84
divRc 2259123
divTp 3667
div_T_scal 5726647
div_intmod_same 341799
div_polmod_same 36001
div_rfrac 1186656
div_rfrac_pol 270989
div_rfrac_scal 13169
div_scal_T 9265521
div_scal_pol 9256364
div_scal_rfrac 37466
div_scal_ser 18395
div_ser 767986
div_ser_scal 1332367
divcR 22457323
divfq 42
divpT 1201746
divpp 2508933
divqf 63
divrunextu 206326268
fill_ser 5664879
fix_rfrac 248339
gadd 5718540921
gaddsg 270985663
gconj 132167
gdiv 421473791
gdivgs 12164897
gdivgu 43900412
gdivgunextu 804801
ginv 34285170
gmul 8340185389
gmul2n 116787476
gmulsg 244409528
gmulug 124278698
gred_rfrac2 44766472
gred_rfrac_simple 57833062
gsqr 1120440075
gsub 2803563456
gsubsg 3189455
init_ser 5677019
inv_polmod 207855
is_ext_qfr 98
kro_quad 28
mulRc 350994260
mulRc_direct 49
mulRq 2352
mulTp 4891064
mul_gen_rfrac 160865
mul_intmod_same 3101817
mul_polmod 2678207
mul_polmod_same 8624058
mul_polmod_scal 3439497
mul_rfrac 7907142
mul_rfrac_scal 10453343
mul_scal 116576257
mul_ser_scal 311733
mulcIR 11503660
mulcc 263661768
mulcxI 14386523
mulcxmI 1608188
mulcxpowIs 4464766
mulpp 12964402
mulqf 28
mulqq 1106
mulrfrac 35716927
quad_polmod_conj 18319
quad_polmod_mul 5908951
quad_polmod_norm 18319
rfrac_denom_mul_scal 9857104
ser_add 3562101
ser_normalize 7560
setfrac 14523774
sqr_polmod 483334
sqr_ser_part 106856
sub_intmod_same 1158469
transtype 154479411
warn_coercion 105

Generated by: LCOV version 1.14