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.1 lcov report (development 22726-9e20c6a88) Lines: 379 448 84.6 %
Date: 2018-06-23 05:36:28 Functions: 33 38 86.8 %
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_init 257
forprime 301
forprimestep 371
forprimestep_init 628
arith_set 937
good_arena_size 1535
initprimes 1535
initprimes0 1535
initprimes1 1535
initprimetable 1535
pari_init_primes 1535
pari_sieve_init 1535
pari_close_primes 1595
sieve_chunk 3504
sieve_block 4545
init_modular_small 144758
u_forprime_sieve_init 802626
optimize_chunk 1554335
sieve_init 1554335
init_modular_big 4715009
forprime_next 8401591
init_primepointer_lt 14934824
u_forprime_set_prime_table 17903046
u_forprime_init 22530325
u_forprime_arith_init 22789600
u_forprime_sieve_arith_init 23592265
maxprime 37735457
shift_cache 83412778
u_forprime_next 434512402

Generated by: LCOV version 1.13