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 - anal.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.10.0 lcov report (development 20459-9710128) Lines: 624 718 86.9 %
Date: 2017-04-29 05:33:44 Functions: 96 100 96.0 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
_given_value 2662
_higher 42
_lower 36
addhelp 36
alias0 24
andpari 187104
bin_number_len 30
bin_read 24
binary_read 48
chartoGENstr 48
check_name 0
check_proto 1294819
cmp_by_var 4308
compile_str 8664
dec_number_len 2112282
dec_read 6566832
dec_read_more 626712
dec_strtoi_len 626712
delete_var 52614
do_alias 4786616
eval_mnemonic 28
exponent 64632
fetch_entry 2762
fetch_entry_raw 4732708
fetch_user_var 2678
fetch_var 32277
fetch_var_higher 20387
fetch_var_value 6
fill_hashtable_single 1304619
findentry 4796772
gadd1e 2712228
gadde 2034374
gdive 36
gdivente 6
gdivrounde 6
gmode 6
gmule 68520
gp_read_str 0
gpolvar 624
gshift_right 1194
gshiftle 6
gshiftre 6
gsub1e 12
gsube 13004178
hashvalue 1304619
hashvalue_raw 4796772
hex_number_len 42
hex_read 24
ifpari 10971383
ifpari_multi 36390
ifpari_void 14480868
initep 19608
insertep 1324167
install 0
int_read 6494410
is_entry 63208
isbin 29502880
ishex 29502838
kill0 12
killep 12
name_var 216
number 6631464
orpari 2063874
pari_add_function 0
pari_fill_hashtable 3674
pari_is_default 856
pari_isbdigit 1272
pari_lex 24302462
pari_pthread_init_varstate 3945
pari_thread_init_varstate 61474
pari_var_close 1224
pari_var_create 18078
pari_var_init 1225
pari_var_next 216
pari_var_next_temp 108
readseq 3498
real_0_digits 144
real_read 70840
real_read_more 1630
skipconstante 6387080
skipdigits 6389070
skipexponent 6386512
skipstring 948174
strntoGENstr 163746
strtoGENstr 83400
strtobin_len 48
strtoi 6494410
strtor 70840
type0 19920
var_register 60
var_restore 68252
varentries_reset 276
varentries_set 6768
varentries_unset 9588
varhigher 54
varlower 24
vars_sort_inplace 126
vars_to_RgXV 126
varstate_restore 6818
varstate_save 68831

Generated by: LCOV version 1.11