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 - language - forprime.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.10.0 lcov report (development 21352-4be8729) Lines: 370 440 84.1 %
Date: 2017-11-23 06:21:03 Functions: 32 37 86.5 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
init_primepointer_geq 0
init_primepointer_gt 0
init_primepointer_leq 0
maxprime_check 0
set_optimize 0
forcomposite 42
forcomposite_init 42
u_forprime_restrict 63
forcomposite_next 147
forprime 301
forprime_init 562
arith_set 721
good_arena_size 1536
initprimes 1536
initprimes0 1536
initprimes1 1536
initprimetable 1536
pari_close_primes 1536
pari_init_primes 1536
pari_sieve_init 1536
sieve_chunk 3496
sieve_block 4602
init_modular_small 33668
init_modular 99915
u_forprime_sieve_init 695375
optimize_chunk 1525136
sieve_init 1525136
init_modular_big 4640807
forprime_next 8401452
init_primepointer_lt 14489785
u_forprime_set_prime_table 17371212
u_forprime_init 21934116
u_forprime_arith_init 22196464
u_forprime_sieve_arith_init 22891786
maxprime 36587678
shift_cache 86002691
u_forprime_next 420138622

Generated by: LCOV version 1.11