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 - qfsolve.c (source / functions) Coverage Total Hit
Test: PARI/GP v2.19.0 lcov report (development 31092-e6893b0017) Lines: 98.3 % 634 623
Test Date: 2026-08-12 17:02:34 Functions: 100.0 % 34 34
Legend: Lines:     hit not hit

Function Name Sort by function name Hit count Sort by function hit count
ZsymM_Z_divexact 20328
ZsymM_Z_divexact_partial 92246
blocks4 2289
both_pm1 19672
check_symmetric 19978
completebasis 410974
det_minors 707
hilberts 7280
id 1001
kermodp 286657
partialgaussred 44884
principal_minor 33253
prod_fm 41293
qf_apply_tau 13324
qf_apply_transvect_Z 4205
qfb_factorback 3962
qfbmat 1666
qfbmat2 21
qfbsqrt 2275
qflllgram_indef 44884
qflllgram_indefgoon 11095
qflllgram_indefgoon2 2275
qfminimize 14
qfminimize_fact 16184
qfparam 7245
qfsolve 12719
qfsolve_i 12719
qfsolvemodp 18039
qftriv 44884
quadclass2 2688
symmetric_non0_coeff 14
update_fm 72688
vecextend 117358
witt 2128

Generated by: LCOV version 2.0-1