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-bordeaux1.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.8.0 lcov report (development 16624-25b9976) Lines: 546 612 89.2 %
Date: 2014-06-24 Functions: 59 64 92.2 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 392 512 76.6 %

Function Name Sort by function name Hit count Sort by hit count
BLS_test 230
BPSW_isprime 320382
BPSW_isprime_big 3115
BPSW_isprime_small 324472
BPSW_psp 657673
BPSW_psp_nosmalldiv 11590
Fl_MR_Jaeschke 1671
Fl_MR_Jaeschke_ok 1126367
Fl_bad_for_base 4190251
Fl_init_MR_Jaeschke 4188612
IsLucasPsP 6144
LucasMod 6144
MR_Jaeschke 1870
MR_Jaeschke_ok 2901
addp 115
addp_union 25
addprimes 115
bad_for_base 32446
check_prime 4090
cleanprimetab 15
gisprime 985
gispseudoprime 15
gprimepi_lower_bound 0
gprimepi_upper_bound 0
init_MR_Jaeschke 32280
is_2_prp_101 1362709
isanypower_nosmalldiv 5449
isprime 511476
isprimePL 490
isprimeSelfridge 1960
ispseudoprime 0
iu_coprime 74989
millerrabin 25
pl831 11825
prime 125
prime_successor 50
prime_table_closest_p 4417399
prime_table_find_n 120
prime_table_next_p 4417315
primepi 175
primepi_lower_bound 5
primepi_upper_bound 5465
primes 40
primes0 60
primes_interval 25
primes_interval_i 269
primes_interval_zv 14
primes_upto_zv 255
primes_zv 0
randomprime 35
removeprimes 20
rmprime 20
rmprimes 20
selfridge_init 485
uBPSW_psp 2824337
u_2_prp 4186941
u_LucasMod 1544857
uislucaspsp 1544862
uisprime 9652101
uisprime_101 11154
uisprime_661 18423
uprime 0
uprimepi 4144
uu_coprime 16619702

Generated by: LCOV version 1.9