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 16937-4bd9b4e) Lines: 545 611 89.2 %
Date: 2014-10-24 Functions: 59 64 92.2 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 391 512 76.4 %

Function Name Sort by function name Hit count Sort by hit count
BLS_test 322
BPSW_isprime 448126
BPSW_isprime_big 4361
BPSW_isprime_small 453852
BPSW_psp 874898
BPSW_psp_nosmalldiv 15807
Fl_MR_Jaeschke 2349
Fl_MR_Jaeschke_ok 1588719
Fl_bad_for_base 5868142
Fl_init_MR_Jaeschke 5865835
IsLucasPsP 7885
LucasMod 7885
MR_Jaeschke 2590
MR_Jaeschke_ok 3728
addp 161
addp_union 28
addprimes 161
bad_for_base 43746
check_prime 5726
cleanprimetab 21
gisprime 1372
gispseudoprime 14
gprimepi_lower_bound 0
gprimepi_upper_bound 0
init_MR_Jaeschke 43547
is_2_prp_101 1907979
isanypower_nosmalldiv 7606
isprime 715073
isprimePL 686
isprimeSelfridge 2744
ispseudoprime 0
iu_coprime 96552
millerrabin 28
pl831 16555
prime 168
prime_successor 70
prime_table_closest_p 6087209
prime_table_find_n 161
prime_table_next_p 6087091
primepi 245
primepi_lower_bound 7
primepi_upper_bound 7546
primes 49
primes0 84
primes_interval 35
primes_interval_i 111
primes_interval_zv 20
primes_upto_zv 91
primes_zv 0
randomprime 49
removeprimes 28
rmprime 28
rmprimes 28
selfridge_init 679
uBPSW_psp 3955626
u_2_prp 5863486
u_LucasMod 2163462
uislucaspsp 2163469
uisprime 13547735
uisprime_101 16462
uisprime_661 26493
uprime 0
uprimepi 6453
uu_coprime 22734397

Generated by: LCOV version 1.9