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 - alglin2.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.16.1 lcov report (development 28676-df828f1c94) Lines: 1029 1141 90.2 %
Date: 2023-08-26 07:54:43 Functions: 81 87 93.1 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
Frobeniusform 0
QM_ImZ_hnf 0
QM_ImZ_hnfall 0
RgM_replace 0
RgXQ_minpoly_FpXQ 0
gerepilemat2_inplace 0
adjsafe 7
caract 14
caract_const 14
qfgaussred 14
RgM_adj_from_char 21
RgXQ_minpoly_FpXQXQ 21
QM_ImZ 28
QM_ImZ_all 28
cxquadnorm 28
jacobi 28
RgM_Fp_charpoly 35
matcompanion 35
QM_minors_coprime 42
RgM_minpoly 49
minpoly_listpolslice 49
QM_ImQ 56
bad_char 56
RgXQ_minpoly_naive 63
pnormlpvec 63
minpoly_dvdslice 98
adj 105
matadjoint0 112
caradj 119
matrixqz0 133
RgM_hess_charpoly 161
carhess 161
RgM_hess 168
gnorml1 168
hess 168
pnormlp 196
QM_charpoly_ZX_bound 266
minpoly_polslice 294
gnormlp 357
relative0 364
matfrobenius 378
transS 413
RgM_Frobenius 427
charpoly0 490
weakfrobenius_step1 595
weakfrobenius_step2 595
weakfrobenius_step3 595
FpM_hess 737
QM_ImQ_hnf 1008
QM_ImQ_hnfall 1085
QM_ImQ_all 1141
QM_ImZ_all_i 1162
qfgaussred_positive 1335
carberkowitz 1554
Flm_charpoly 1791
fix_pol 1792
QM_charpoly_ZX 1827
mattrace 1939
ZM_charpoly 1957
transD 2303
charpoly 3161
RgXQ_minpoly 3199
RgXQ_minpoly_fast 3199
charpoly_bound 3483
easymin 3605
minpoly 3605
intersect 3752
QM_charpoly_ZX_slice 3867
QM_charpoly_ZX_worker 3867
QM_charpoly_ZX_i 4050
easychar 5058
qfsign 12012
gaussred 12026
transL 14259
rot 19180
FpM_charpoly 19194
Flm_charpoly_i 23499
Flm_hess 23499
suitable 46872
gsupnorm 112669
gnorml1_fake 142513
store 506059
gsupnorm_aux 619066
gtrace 731695
gnorm 3262536
gnorml2 61634382
gnorml2_i 61637726

Generated by: LCOV version 1.14