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 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 - prime.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.10.0 lcov report (development 21743-016b453) Lines: 583 641 91.0 %
Date: 2018-01-22 06:18:30 Functions: 66 68 97.1 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
primes_zv 0
uprime 0
gprimepi_lower_bound 1
gprimepi_upper_bound 1
gispseudoprime 14
primepi_lower_bound 14
cleanprimetab 21
PL_certificate 28
addp_union 28
millerrabin 28
removeprimes 28
rmprime 28
rmprimes 28
isprimePL 35
check_prime 49
randomprime 49
BLS_test 63
primes 63
prime_successor 70
primes_interval 98
primes0 119
ispseudoprime 147
primes_upto_zv 154
addp 161
addprimes 161
prime_table_find_n 238
prime 245
primepi 252
pari_init_primetab 1519
Fl_MR_Jaeschke 1641
MR_Jaeschke 1775
PL_certify 3075
BPSW_try_PL 5008
primes_interval_zv 7194
primes_interval_i 7348
MR_Jaeschke_ok 7425
uprimepi 9519
pari_pthread_init_primetab 10278
pl831 15231
IsLucasPsP 16373
LucasMod 16373
isanypower_nosmalldiv 21916
uisprime_661 25887
BPSW_psp_nosmalldiv 30045
u_LucasMod 36243
primepi_upper_bound 56799
pari_thread_init_primetab 88115
init_MR_Jaeschke 101618
bad_for_base 101749
iu_coprime 321922
BPSW_isprime 954954
BPSW_isprime_small 955069
Fl_MR_Jaeschke_ok 1419711
u_LucasMod_pre 1584010
uislucaspsp 1620260
is_2_prp_101 1889955
gisprime 3452614
isprime 4282692
uBPSW_psp 5701057
BPSW_psp 6893920
u_2_prp 8017468
Fl_init_MR_Jaeschke 8021174
Fl_bad_for_base 8028477
uisprime_101 9275380
prime_table_next_p 14764306
prime_table_closest_p 14764397
uisprime 28696697
uu_coprime 33640887

Generated by: LCOV version 1.11