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 - arith2.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.8.0 lcov report (development 16781-61614ca) Lines: 599 713 84.0 %
Date: 2014-09-14 Functions: 75 85 88.2 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 328 473 69.3 %

Function Name Sort by function name Hit count Sort by hit count
RgV_is_ZV0 210
RgV_is_ZVnon0 287
RgV_is_ZVpos 275024
Z_issquarefree 771
Z_smoothen 9548
_addii 0
_dvmdii 436
_mod4 28
_mulii 147
_sqri 308
bigomega 196
boundfact 49
check_arith_all 168910
check_arith_non0 2719
check_arith_pos 0
check_basis 126
clean_Z_factor 168
core0 266
core2 70
core2_i 84
core2fa 168
core2partial 168
coredisc 14
coredisc0 14
coredisc2 14
corefa 0
corepartial 0
digits 49
digits_dacsmall 3054
divisors 361347
divisors_init 361389
divisorsu 30319
euler_sumdiv 1998
euler_sumdivk 454
eulerphi 144200
eulerphiu 148788
eulerphiu_fact 149166
factor_pn_1 6671
factor_pn_1_limit 6671
factorlim 23821
factoru_pow 21738
fuse_Z_factor 0
gen_digits 3430
gen_digits_dac 73701
gen_digits_i 3480
gen_fromdigits 1449
gen_fromdigits_dac 10549
get_vB 4928
good_arena_size 1194
init_primepointer_geq 0
init_primepointer_gt 0
init_primepointer_leq 0
init_primepointer_lt 6095986
initprimes 1194
initprimes0 1194
initprimes1 1194
initprimetable 1194
is_Z_factor 210
is_Z_factor_i 137771
is_Z_factornon0 287
is_Z_factorpos 137274
issquarefree 35
maxprime 13124785
maxprime_check 0
numdiv 196
numdiv_aux 67
omega 196
set_fact 10640
set_fact_check 350749
set_optimize 0
set_vexp 31360
sieve_chunk 2720
sumdigits 35
sumdigits0 105
sumdigits_block 14
sumdigitsu 355152
sumdiv 196
sumdiv_aux 53
sumdivk 686
sumdivk_aux 106
u_euler_sumdiv 571
u_euler_sumdivk 1317
uissquarefree 7991
uissquarefree_fact 168
usumdivkvec 28

Generated by: LCOV version 1.9