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.10.0 lcov report (development 21703-2e13792) Lines: 1495 2539 58.9 %
Date: 2018-01-17 06:18:31 Functions: 199 293 67.9 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
GENtoGENstr_nospace 0
GENtoTeXstr 0
Strexpand 0
_cfwrite 0
_fwrite 0
_initout 0
_lfwrite 0
blancs 0
brute 0
check_magic 0
check_secure 0
dbg 0
dbgGEN 0
dbg_addr 0
dbg_pari_heap 0
dbg_word 0
decode_color 0
dft_help 0
do_append 0
externstr 0
file_is_binary 0
forpath_init 0
forpath_next 0
fputGEN_pariout 0
get_file 0
get_lines 0
gp_dlopen 0
gp_embedded 0
gp_embedded_init 0
gp_getenv 0
gp_read_from_input 0
gp_read_str_multiline 0
gp_readvec_file 0
gpextern 0
gpinstall 0
gpsystem 0
gpwritebin 0
install0 0
is_long_ok 0
is_magic_ok 0
is_sizeoflong_ok 0
lim_lines_output 0
matbrute 0
ok_pipe 0
outmat 0
output 0
pari_ask_confirm 0
pari_file_exists 0
pari_fopen 0
pari_fprintf 0
pari_fread_longs 0
pari_is_file 0
pari_nb_hist 0
pari_safefopen 0
pari_strndup 0
pari_unique_filename 0
pari_unique_filename_suffix 0
pari_vfprintf 0
path_is_absolute 0
print0_file 0
print_entree 0
print_functions_hash 0
rdGEN 0
rd_long 0
rdstr 0
readbin 0
readobj 0
readstr 0
str_addr 0
strftime_expand 0
string_gets 0
strip_last_nl 0
switchout 0
switchout_get_FILE 0
texe 0
texparen 0
try_dlopen 0
try_name 0
try_open 0
try_pipe 0
uordinal 0
vsigne 0
wr 0
wrGEN 0
wr_check 0
wr_long 0
write0 0
write1 0
writeGEN 0
write_magic 0
writebin 0
writenamedGEN 0
writetex 0
wrstr 0
GENtostr 7
err_flush 7
gp_read_file 7
itoc 7
printp 7
printtex 7
switchin 7
switchin_last 7
term_height 7
term_height_intern 7
warning0 7
log10_2 12
Strtex 14
error0 14
pari_sprint0 14
Strchr 21
pari_get_histtime 21
printsep1 21
normalOutS 23
gp_readvec_stream 28
zerotostr 35
killallfiles 49
texi 56
is_dir_stat 70
pari_is_dir 70
wr_texnome 70
pari_get_hist 91
get_texvar 98
wr_lead_texnome 98
history 112
times_texnome 112
texVpowE 140
texexpo 140
texnome 140
texi_sign 182
err_printf 245
init_unique 314
pari_dir_exists 314
pari_is_rwx 314
pari_tmp_dir 314
pari_unique_dir 314
prints 490
printf0 518
pari_printf 595
pari_vprintf 595
env_ok 628
term_color 644
GENtoGENstr 693
GENtostr_fun 700
Strprintf 721
printsep 763
real0tostr 972
stack_strcat 1190
str_alloc0 1225
dopr_arg_vector 1239
stack_sprintf 1386
stack_strdup 1386
pari_close_files 1517
pari_close_homedir 1517
initout 1519
pari_init_homedir 1519
pari_stdin_isatty 1519
resetout 1519
gsprintf 1603
print_precontext 1631
v_get_arg 1638
in_help 1703
gvsprintf 1717
ltoc 1876
fix_buffer 2058
GENtostr_raw 2282
print_context 2296
pari_get_homedir 3034
gp_read_stream 3115
wr_vecsmall 4363
gp_read_stream_buf 4403
_expand_env 4558
_path_expand 4558
path_expand 4558
delete_buffer 4730
new_buffer 4730
init_filtre 5990
pari_unlink 6662
out_printf 7739
new_line 8001
print_errcontext 8518
filestate_restore 8578
out_vprintf 9066
wr_dec 10427
gp_filter 10738
Str 10787
RgV_to_str 10801
Str_fun 10801
str_print0 10815
quote_string 11508
real0tostr_width_frac 12580
absrtostr_width_frac 13078
get_sigd 13309
fmtreal 13337
paren 13475
pari_sprintf 13502
shift_add 13764
print_prefixed_text 13915
term_width 16739
term_width_intern 16739
print1 17220
GENtostr_unquoted 18037
absrtostr 19208
os_getenv 20412
zeros 20880
pari_get_infile 22834
pari_fopengz 22897
pari_vsprintf 25671
normalErrF 25737
sm_dopr 26910
str_printf 27729
pari_strdup 29260
ex10 32279
pari_fopen_or_fail 32739
pari_open_file 32739
type_name 33840
gen_output 35600
gen_output_fun 35600
matbruti 35614
pari_puts 36693
init_linewrap 37020
isdenom 44401
out_term_color 48010
fmtnum 52585
str_arg_vprintf 54639
pari_fclose 55587
newfile 55657
pari_kill_file 55657
term_get_color 57321
fmtstr 58676
str_putscut 58676
pari_add_hist 63248
dosign 65172
outpad 65887
pari_fread_chars 70931
pari_last_was_newline 72008
get_var 77630
wr_lead_monome 78295
print 86700
pari_init_files 88150
pari_thread_close_files 88772
popinfile 90316
input_loop 90982
pari_set_last_newline 91221
pari_last_tmp_file 95462
print0 103934
out_print0 104725
wr_monome 123074
str_long 125369
str_ulong 125369
file_getline 128924
file_input 128924
times_monome 130011
filtre0 138117
pari_flush 147149
get_fun 151147
strlen_real 154376
normalOutF 155902
pari_putc 156869
monome 159341
stack_GENtostr_fun 174194
VpowE 174783
wrexpo 174783
kill_file_stack 177538
_flush_log 181639
stack_GENtostr_fun_unquoted 212543
str_init 215505
isfactor 217343
puts_lw 235516
normalErrS 246028
_fputs 246051
_puts_log 246051
itostr 367348
str_absint 420223
normalErrC 427091
out_puts 427993
str_alloc 445157
out_putc 585423
bruti_intern 723712
itostr_sign 806305
numdig 806305
bruti 870490
set_last_newline 1010756
bruti_sign 1039050
print_0_or_pm1 1039232
isone 1191819
utodec 1507816
str_puts 1528761
isnull_for_pol 1647709
isnull 3075581
putc_lw 6942872
normalOutC 6996260
_putc_log 7423351
str_putc 8120247

Generated by: LCOV version 1.11