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 - modules - galois.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.18.1 lcov report (development 30702-bddb8d6928) Lines: 1784 1855 96.2 %
Date: 2026-02-23 02:23:56 Functions: 72 74 97.3 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
F4 6300
Monomial 31651406
ZX_DDF_sorted 10386
_aff 4188
_cr 2010
_gr 106824
_typ 1068
alloc_pobj 42756
allocgroup 32100
bin 14637354
check_isin 16050
closure10 810
closure11 120
closure8 978
closure9 618
cmp_pol 11220
cmp_re 167306434
data10 5046
data11 258
data8 7356
data9 3390
dbg_rac 0
delete_roots 160
do_par 248970
fixprec 203267
galmodp 2670
galois_res 10404
galoisbig 2670
galoisimpeven10 150
galoisimpeven8 450
galoisimpeven9 234
galoisimpodd10 534
galoisimpodd8 438
galoisimpodd9 210
galoismodulo10 846
galoismodulo11 156
galoismodulo8 1014
galoismodulo9 654
galoisprim10 126
galoisprim8 90
galoisprim9 174
galopen 26706
get_ro 1644665
get_ro_perm 1543932
getpreci 16050
gpoly 813383
gpolynomial 831282
init_isin 16050
initgroup 16050
isin_G_H 16050
lirecoset 16050
lireresolv 10656
moreprec 100733
new_pol 2354
partitions_galois 2514
permmul 16008
polgalois 8172
polgalois0 13074
polgaloisnames 10404
polgaloisnamesbig 2670
preci 281476
printperm 0
raye 297546
rayergroup 28242
rayergroup11 1380
read_obj 26706
roots_to_ZX 15989
sortroots 160
sufprec 1442509
sufprec_r 2741670
transroot 78176
tschirn 2190
zaux 2952
zaux1 5904

Generated by: LCOV version 1.16