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 - es.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.8.0 lcov report (development 18906-a425091) Lines: 1524 2535 60.1 %
Date: 2016-05-06 Functions: 201 292 68.8 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 959 1902 50.4 %

Function Name Sort by function name Hit count Sort by hit count
GENtoGENstr 693
GENtoGENstr_nospace 0
GENtoTeXstr 0
GENtostr 0
GENtostr_fun 693
GENtostr_raw 2338
GENtostr_unquoted 65399
RgV_to_str 0
RgV_to_str_fun 10143
Str 10129
Str_fun 10143
Strchr 7
Strexpand 0
Strprintf 721
Strtex 14
VpowE 149758
_cfwrite 0
_expand_env 7032
_flush_log 410454
_fputs 897292
_fwrite 0
_initout 0
_lfwrite 0
_path_expand 7032
_putc_log 16406931
_puts_log 897292
absrtostr 15083
absrtostr_width_frac 315
blancs 0
brute 0
bruti 818412
bruti_intern 589503
bruti_sign 977067
check_magic 0
check_secure 0
dbg 0
dbgGEN 0
dbg_addr 0
dbg_pari_heap 0
dbg_word 0
decode_color 0
delete_buffer 4314
delete_dirs 6016
dft_help 7
do_append 0
dopr_arg_vector 1218
dosign 5185
eng_ord 0
env_ok 614
err_flush 7
err_printf 245
error0 14
ex10 15391
externstr 0
file_getline 168550
file_input 168550
file_is_binary 0
filestate_restore 58215
filtre0 176801
fix_buffer 1897
fmtnum 4898
fmtreal 560
fmtstr 196759
forpath_init 0
forpath_next 0
fputGEN_pariout 0
gen_output 26427
gen_output_fun 26427
get_file 0
get_fun 104794
get_lines 0
get_sigd 532
get_texvar 98
get_var 59801
gp_dlopen 7
gp_embedded 0
gp_embedded_init 0
gp_expand_path 2344
gp_filter 10108
gp_getenv 0
gp_read_file 7
gp_read_from_input 0
gp_read_str_multiline 0
gp_read_stream 2401
gp_read_stream_buf 3367
gp_readvec_file 0
gp_readvec_stream 21
gpextern 0
gpinstall 7
gpsystem 0
gpwritebin 0
gsprintf 14
gvsprintf 21572
history 112
in_help 1304
init_filtre 5767
init_linewrap 28702
init_unique 307
initout 2344
input_loop 143236
install0 7
is_dir_stat 63
is_long_ok 0
is_magic_ok 0
is_sizeoflong_ok 0
isdenom 42147
isfactor 203119
isnull 2897279
isnull_for_pol 1606521
isone 1010228
itoc 0
itostr 348514
itostr_sign 713741
kill_file_stack 3707
killallfiles 1871
lim_lines_output 0
log10_2 12
ltoc 84
matbrute 0
matbruti 26427
monome 142807
new_buffer 4822
new_line 8150
newfile 53054
normalErrC 2183399
normalErrF 174792
normalErrS 897279
normalOutC 14223532
normalOutF 235662
normalOutS 13
numdig 713741
ok_pipe 0
os_getenv 71030
os_signal 23244
out_print0 78353
out_printf 55085
out_putc 8111720
out_puts 871861
out_term_color 246801
out_vprintf 70311
outmat 0
outpad 5430
output 0
paren 7945
pari_add_hist 62599
pari_ask_confirm 0
pari_close_files 1836
pari_close_homedir 1836
pari_default_path 2344
pari_dir_exists 307
pari_fclose 53019
pari_file_exists 0
pari_flush 177265
pari_fopen 0
pari_fopen_or_fail 30885
pari_fopengz 22120
pari_fprintf 0
pari_fread_chars 70931
pari_fread_longs 0
pari_get_hist 91
pari_get_histtime 21
pari_get_homedir 4688
pari_get_infile 22113
pari_init_files 193208
pari_init_homedir 2344
pari_is_dir 63
pari_is_file 0
pari_is_rwx 307
pari_kill_file 53054
pari_last_tmp_file 198175
pari_last_was_newline 121003
pari_nb_hist 0
pari_open_file 30885
pari_printf 14617
pari_putc 5926998
pari_puts 108442
pari_safefopen 0
pari_set_last_newline 210007
pari_sprint0 14
pari_sprintf 63176
pari_stdin_isatty 2344
pari_strdup 88919
pari_strndup 0
pari_tmp_dir 307
pari_unique_dir 307
pari_unique_filename 0
pari_unlink 6329
pari_vfprintf 0
pari_vprintf 14617
pari_vsprintf 64471
path_expand 7032
path_is_absolute 0
popinfile 3672
print 72466
print0 77618
print0_file 0
print1 5145
print_0_or_pm1 977249
print_context 1393
print_entree 0
print_errcontext 58224
print_functions_hash 0
print_precontext 1022
print_prefixed_text 63691
printf0 497
prints 490
printsep 707
printsep1 21
printtex 7
putc_lw 14160619
puts_lw 276673
quote_string 11011
rdGEN 0
rd_long 0
rdstr 0
readbin 0
readobj 0
readstr 0
real0tostr 896
real0tostr_width_frac 35
resetout 2344
set_last_newline 8980886
shift_add 847
sm_dopr 157572
stack_GENtostr_fun 149487
stack_GENtostr_fun_unquoted 239130
stack_sprintf 1295
stack_strcat 1029
stack_strdup 1295
str_absint 350760
str_addr 0
str_alloc 369035
str_alloc0 1103
str_init 309789
str_long 104439
str_print0 14
str_putc 10912412
str_puts 1486653
str_putscut 196759
str_ulong 104439
strftime_expand 0
string_gets 0
strlen_real 358216
switchin 7
switchin_last 7
switchout 0
switchout_get_FILE 0
term_color 532
term_get_color 309222
term_height 7
term_height_intern 7
term_width 65721
term_width_intern 65721
texVpowE 140
texe 0
texexpo 140
texi 56
texi_sign 182
texnome 140
texparen 0
times_monome 119035
times_texnome 112
try_dlopen 0
try_name 0
try_open 0
try_pipe 0
type_name 52264
utodec 1440907
v_get_arg 1617
vsigne 0
warning0 7
wr 0
wrGEN 0
wr_check 0
wr_dec 8349
wr_lead_monome 60277
wr_lead_texnome 98
wr_long 0
wr_monome 115493
wr_texnome 70
wr_vecsmall 2207
wrexpo 149758
write0 0
write1 0
writeGEN 0
write_magic 0
writebin 0
writenamedGEN 0
writetex 0
wrstr 0
zeros 6146
zerotostr 21

Generated by: LCOV version 1.9