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 - base1.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.16.2 lcov report (development 29115-f22e516b23) Lines: 1713 1803 95.0 %
Date: 2024-04-19 08:07:09 Functions: 139 156 89.1 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
ZX_to_monic 0
checksqmat 0
elt_galoismatrixapply 0
embednorm_T2 0
factoredpolred 0
factoredpolred2 0
idealramfrobenius 0
nf_get_allroots 0
nfinitred2 0
nfsplitting 0
polred2 0
polredabs2 0
polredabsall 0
pr_galoismatrixapply 0
smallpolred 0
smallpolred2 0
vecgaloismatrixapply 0
pr_galoisapply 7
pr_make 7
vecgaloisapply 7
polred 14
polredord 21
poltomonic 42
badp 49
elt_galoisapply 49
idealfrobenius_aut 70
polred0 70
idealfrobenius 77
nfisisom 77
Polred 84
get_bnfpol 112
nfisincl 112
idealramgroups 126
nfnewprec 154
nfinitred 182
rnfpolredabs 231
nfpolred 280
tests_OK 287
rnfpolredbest 357
idealramgroupswild 497
incl_disc 539
rnfpolred_i 588
idealramfrobenius_aut 616
v9checkgal 658
v13checkgchar 819
nfisincl_from_fact_frac 1232
nfsplitting_auto 1232
RgFV_to_FlxqV 1239
nfgaloispermtobasis 1379
nfsplitting_composite 1421
nfsplitting0 1435
idealquasifrob 1463
get_nfindex 1666
idealinertiagroup 1834
idealramgroupstame 1911
idealramgroups_aut 2408
gal_check_pol 2485
nfcertify 3101
primes_certify 3101
polredbest 3514
polredbest_i 3871
nfinit_basic_partial 3906
polredbest_aux 4053
filter 4095
polred_aux 4130
nfinit 6226
zk_galoisapplymod 6255
nfisincl_from_fact 7196
nfisincl0 7308
partmap_reverse 7315
tschirnhaus 7652
partmap_reverse_frac 8085
partmap_reverse_frac_worker 8085
RgF_to_Flxq 8092
get_aut 8162
FpX_FpC_nfpoleval 8824
ZXX_Q_mul 8897
nfinit0 10160
check_ZKmodule 10519
check_ZKmodule_i 10575
nfpoleval 11151
ZM_image_shallow 12690
polredabs 13377
polredabs0 13825
remove_duplicates 13825
nfgaloismatrixapply 13909
chk_gen_init 14042
findmindisc 14049
polredabs_i 14049
nfinit_basic_flag 14119
polred_init 18137
checkabgrp 19817
get_bnf 22099
set_mulid 22302
make_Tr 27975
ZX_cmp 29970
chk_gen_prec 32165
v11checkbnf 37436
rawchecknf 45640
rawcheckbnf 46599
ZX_is_better 51612
embed_T2 70948
get_red_G 72849
nfinit_complete 83621
get_Tr 83623
nf_multable 83625
nfmaxord_to_nf 83625
nf_input_type 85467
nfinit_basic 85467
ZX_canon_neg 89019
nfnewprec_shallow 91282
nf_basden 91309
nfgaloismatrix 94528
QX_table_nfpoleval 94945
ZC_galoisapply 95135
chk_gen 98081
get_polchar 98081
set_LLL_basis 101482
typv6 113169
get_nf 115542
cmpii_polred 125764
galoisapply 126374
try_polmin 136084
real_norm 160661
nfmaxord_complete 167249
nffp_init 174604
get_bas_den 202515
v10checknf 233037
get_roots 234735
get_pol 260241
make_G 265902
make_M 265905
make_M_G 265905
nftyp 274337
checkrnf 298007
prec_fix 298067
v13checkrnf 298609
checkrnf_i 308167
quicktrace 381742
checknfelt_mod 555834
get_nfpol 667344
ZX_Q_normalize 840943
ZX_primitive_to_monic 841261
ZX_Z_normalize 843905
nf_get_prec 971682
checkbid 1381090
checkbid_i 1637973
checkbnr 1821647
checkbnr_i 2004778
checkbnf 3232537
checkbnf_i 5242509
ZX_Q_mul 6356775
embed_norm 18934208
complex_norm 34898397
checknf 103989612
checknf_i 107010205

Generated by: LCOV version 1.14