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.8.0 lcov report (development 19043-64ae2d8) Lines: 661 743 89.0 %
Date: 2016-06-25 Functions: 100 102 98.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 394 552 71.4 %

Function Name Sort by function name Hit count Sort by hit count
_given_value 4044
_higher 49
_lower 42
addhelp 49
alias0 35
andpari 175532
bin_number_len 38
bin_read 28
binary_read 56
chartoGENstr 56
check_name 7
check_proto 2358071
cmp_by_var 5059
cmp_epname 7
compile_str 10108
dec_number_len 2164572
dec_read 7736548
dec_read_more 589885
dec_strtoi_len 589885
delete_var 109695
do_alias 5792299
eval_mnemonic 5584
exponent 75292
fetch_entry 4814
fetch_entry_raw 5622047
fetch_user_var 4688
fetch_var 41474
fetch_var_higher 68325
fetch_var_value 7
fill_hashtable_single 2374472
findentry 5775510
gadd1e 3163195
gadde 2373417
gdive 7
gdivente 7
gdivrounde 7
gmode 7
gmule 91134
gp_read_str 0
gpolvar 518
gshift_right 1392
gshiftle 7
gshiftre 7
gsub1e 14
gsube 15171541
hashvalue 2374472
hashvalue_raw 5775510
hex_number_len 54
hex_read 28
ifpari 12902405
ifpari_multi 74452
ifpari_void 16552566
initep 25233
insertep 2399642
install 7
int_read 7523097
is_entry 152562
isbin 34337138
ishex 34337089
kill0 21
killep 21
name_var 224
number 7811840
orpari 2480940
pari_add_function 0
pari_fill_hashtable 9376
pari_is_default 901
pari_isbdigit 1484
pari_lex 28521398
pari_pthread_init_varstate 12119
pari_thread_init_varstate 185266
pari_var_close 1836
pari_var_create 21864
pari_var_init 2344
pari_var_next 224
pari_var_next_temp 126
print_all_user_fun 7
readseq 3353
real_0_digits 168
real_read 146957
real_read_more 66550
skipconstante 7408987
skipdigits 7412194
skipexponent 7408403
skipstring 1112483
strntoGENstr 384081
strtoGENstr 231272
strtobin_len 56
strtoi 7523097
strtor 146957
type0 22765
var_register 63
var_restore 243216
varentries_reset 287
varentries_set 10405
varentries_unset 62178
varhigher 56
varlower 28
vars_sort_inplace 147
vars_to_RgXV 147
varstate_restore 58022
varstate_save 152835

Generated by: LCOV version 1.9