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 to exceed 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 - mpqs.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.18.1 lcov report (development 30072-2ccdc2326c) Lines: 695 841 82.6 %
Date: 2025-03-12 09:19:58 Functions: 34 38 89.5 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
mpqs_status 0
rel_add_ei 0
rel_sub_ei 0
split_relp 0
toolarge 7
mpqs_class_init 28
mpqs_class_rels 336
rels_to_quad 336
mpqs_find_k 3272
mpqs 3279
mpqs_FB_ctor 3300
mpqs_create_FB 3300
mpqs_locate_A_range 3300
mpqs_poly_ctor 3300
mpqs_set_parameters 3300
mpqs_set_sieve_threshold 3300
mpqs_sieve_array_ctor 3300
mpqs_solve_linear_system 3369
rels_to_F2Ms 3369
split 7096
mpqs_increment 9214
decimal_len 9851
rels_to_pairs 10465
mpqs_si_choose_primes 12578
combine_large_primes 12720
zv_is_even 12720
rel_Y 25440
rel_p 25440
mpqs_eval_cand 133469
mpqs_eval_sieve 143087
mpqs_self_init 143087
mpqs_sieve 143087
rel_to_ei 362048
frel_add 388307
mpqs_sieve_p 812946
mpqs_add_factor 7612747
mpqs_sieve_p2 52966369
mpqs_sieve_p1 127050406

Generated by: LCOV version 1.16