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 - buch3.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.18.1 lcov report (development 30288-703288f808) Lines: 1519 1629 93.2 %
Date: 2025-05-19 09:23:07 Functions: 119 124 96.0 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
bnrinit0 0
dft_bound 0
isprincipalraygen 0
minkowski_bound 0
nf_deg1_prime 0
bnrclassnolist 7
bnrconductorofchar 7
ZM_intersect 14
bnrcompositum 14
bnrlcmcond 14
rnfnormgroup 14
decodemodule 21
discrayabslist 21
is_module 21
bnrclassno_1 28
bnrliftsubgroup 28
chk_listBU 28
compute_M0 28
discrayabslistarch 28
zsimp 28
bnfcertify 35
bnfnarrow 35
bnrisconductor0 35
isprimitive 35
regulatorbound 35
rnfconductor 35
minimforunits 42
bnrdisclist0 49
Hermite_bound 63
bnfcertify0 63
bnrconductor0 63
bound_unit_index 63
init_bad 63
lowerboundforregulator 63
zimmertbound 63
bnrclassno0 105
bnrclassno 112
get_nz 168
bnrdisc0 175
fasmall_append 175
bnrgaloismatrix 231
ABC_to_bnr 273
bnr_vecchar_sanitize 350
factordivexact 406
get_NR1D 427
bnrisgalois 448
check_bnrgal 448
subgrouplist_cond_sub 455
get_discdata 469
get_discray 469
zsimpjoin 518
bnrconductormod 532
bnrchar 609
bnrchar_i 609
bnrconductor 616
bnrmap 616
bnrconductor_factored 623
factorpow 812
rnfconductor0 826
rnfnormgroup_i 826
ZMV_mul 910
get_classno 910
hdet 1022
rowselect_p 1022
quotient_expo 1036
factormul 1043
bnrclassno_all 1106
factorsplice 1169
is_complex 1228
abmap_char_image 1232
bnr_char_sanitize 1260
vecselect_p 1344
abmap_nchar_image 1449
Lbnrclassno 1484
prV_norms 1568
bnrdisc 1645
bnrdisc_i 1645
check_prime 1715
primecertify 1715
is_zero 1804
bnrsurjection 2933
bnrautmatrix 3094
bnrgaloisapply 3577
idealmoddivisor 4214
bnr_subgroup_sanitize 4249
make_integral_Z 4368
bnrconductor_raw 5383
bnrconductor_factored_i 6006
get_pinvpi 9863
get_pi 10003
bnr_get_Ui 13055
idealmoddivisor_aux 15001
too_big 15449
fast_val 17983
compute_fact 25515
bnr_grp 32277
Buchray 41391
bnrtoprimitive 42119
get_Gen 48090
bnrconductor_factored_arch 48125
cond0_e 48125
condoo_archp 48125
is_unit 70553
bnr_log_gen_arch 87414
subgroup_conductor_ok 95214
subgroupcond 182565
conductor_elts 183020
subgrouplist0 184770
bnrinitmod 211375
ZM_content_mul 227292
Buchraymod 253571
Buchraymod_i 257233
bnrisconductor 275531
bnr_subgroup_check 276102
isprincipalray 407916
contains 410073
bnrisprincipal 415000
bnr_log_gen_pr 420027
ideallog_to_bnr 507430
ideallog_to_bnr_i 523801
ZM2_ZC2_mul 1342057
bnrisprincipalmod 1459789
bnr_get_El 1464605
bnr_get_U 1852419

Generated by: LCOV version 1.16