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 16804-345a01c) Lines: 545 611 89.2 %
Date: 2014-09-20 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 322
BPSW_isprime 448154
BPSW_isprime_big 4361
BPSW_isprime_small 453880
BPSW_psp 876795
BPSW_psp_nosmalldiv 15870
Fl_MR_Jaeschke 2363
Fl_MR_Jaeschke_ok 1594096
Fl_bad_for_base 5888819
Fl_init_MR_Jaeschke 5886498
IsLucasPsP 7895
LucasMod 7895
MR_Jaeschke 2604
MR_Jaeschke_ok 3748
addp 161
addp_union 35
addprimes 161
bad_for_base 43869
check_prime 5726
cleanprimetab 21
gisprime 1379
gispseudoprime 21
gprimepi_lower_bound 0
gprimepi_upper_bound 0
init_MR_Jaeschke 43670
is_2_prp_101 1928482
isanypower_nosmalldiv 7627
isprime 715108
isprimePL 686
isprimeSelfridge 2744
ispseudoprime 0
iu_coprime 96898
millerrabin 35
pl831 16555
prime 175
prime_successor 70
prime_table_closest_p 6102110
prime_table_find_n 168
prime_table_next_p 6101992
primepi 245
primepi_lower_bound 7
primepi_upper_bound 7637
primes 56
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 3955779
u_2_prp 5884135
u_LucasMod 2163525
uislucaspsp 2163532
uisprime 13586290
uisprime_101 16462
uisprime_661 26625
uprime 0
uprimepi 5802
uu_coprime 22803805

Generated by: LCOV version 1.9