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 - lfunquad.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.18.1 lcov report (development 30702-bddb8d6928) Lines: 337 348 96.8 %
Date: 2026-02-23 02:23:56 Functions: 42 43 97.7 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
sigsumtwist11 0
div4 30
sigsumm12 30
sigsumtwist12_6 54
Dneg 60
dimodd 60
get_S_odd 60
modularodd 60
mulodd 60
sigsum4 102
sigsumtwist12p0 138
sigsum8 180
Dpos 222
dimeven 222
get_S_even 222
modulareven 222
muleven 222
usumdivk_0_all 222
sigsum12 234
Hcol 282
myinverseimage 282
vecRCpol 282
mfDcoefs 306
sigsum16 306
sigsumtwist12pt 432
sigsumtwist12_N 516
findNeven 552
findNodd 654
RCpol 696
sigsumtwist 870
sigsum 1188
usefeq 1206
usumdivktwist_fact_all 1284
RgV_multwist 1296
Lfeq 1584
Linv 1584
myround 1584
usumdivk_fact_all 2670
lfunquadneg 2790
lfunquadneg_i 2790
RgV_mul 3258
vpowp 5646
euler_sumdiv 82062

Generated by: LCOV version 1.16