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 21064-a7054ad) Lines: 1801 2530 71.2 %
Date: 2017-09-25 06:24:50 Functions: 247 292 84.6 %
Legend: Lines: hit not hit

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 2268
GENtostr_unquoted 14735
RgV_to_str 10187
Str 10161
Str_fun 10175
Strchr 21
Strexpand 12
Strprintf 721
Strtex 14
VpowE 181654
_cfwrite 8
_expand_env 4575
_flush_log 173538
_fputs 240563
_fwrite 80
_initout 0
_lfwrite 72
_path_expand 4575
_putc_log 7088891
_puts_log 240563
absrtostr 16982
absrtostr_width_frac 13036
blancs 0
brute 0
bruti 798016
bruti_intern 672495
bruti_sign 950910
check_magic 8
check_secure 32
dbg 0
dbgGEN 0
dbg_addr 0
dbg_pari_heap 0
dbg_word 0
decode_color 0
delete_buffer 4730
dft_help 8
do_append 0
dopr_arg_vector 1239
dosign 63982
eng_ord 0
env_ok 680
err_flush 7
err_printf 253
error0 14
ex10 30011
externstr 4
file_getline 122549
file_input 122521
file_is_binary 12
filestate_restore 8137
filtre0 131096
fix_buffer 2030
fmtnum 51286
fmtreal 13295
fmtstr 54628
forpath_init 16
forpath_next 16
fputGEN_pariout 0
gen_output 33010
gen_output_fun 33010
get_file 0
get_fun 144260
get_lines 8
get_sigd 13267
get_texvar 98
get_var 74498
gp_dlopen 8
gp_embedded 0
gp_embedded_init 0
gp_filter 10108
gp_getenv 8
gp_read_file 15
gp_read_from_input 0
gp_read_str_multiline 0
gp_read_stream 3119
gp_read_stream_buf 4419
gp_readvec_file 4
gp_readvec_stream 32
gpextern 4
gpinstall 8
gpsystem 24
gpwritebin 8
gsprintf 14
gvsprintf 132
history 116
in_help 1581
init_filtre 5990
init_linewrap 34394
init_unique 340
initout 1503
input_loop 85786
install0 8
is_dir_stat 86
is_long_ok 16
is_magic_ok 32
is_sizeoflong_ok 8
isdenom 36512
isfactor 192455
isnull 2962952
isnull_for_pol 1664016
isone 1114702
itoc 7
itostr 690440
itostr_sign 1095219
kill_file_stack 132277
killallfiles 49
lim_lines_output 0
log10_2 12
ltoc 1876
matbrute 0
matbruti 33017
monome 166422
new_buffer 4730
new_line 7995
newfile 58123
normalErrC 410536
normalErrF 24512
normalErrS 240520
normalOutC 6678355
normalOutF 149026
normalOutS 43
numdig 1095219
ok_pipe 0
os_getenv 19553
out_print0 101013
out_printf 7375
out_putc 566386
out_puts 413628
out_term_color 46374
out_vprintf 8686
outmat 0
outpad 64546
output 0
paren 9282
pari_add_hist 59176
pari_ask_confirm 0
pari_close_files 1501
pari_close_homedir 1501
pari_dir_exists 340
pari_fclose 58053
pari_file_exists 0
pari_flush 140686
pari_fopen 0
pari_fopen_or_fail 35181
pari_fopengz 22841
pari_fprintf 0
pari_fread_chars 70939
pari_fread_longs 56
pari_get_hist 91
pari_get_histtime 25
pari_get_homedir 3010
pari_get_infile 22850
pari_init_files 65832
pari_init_homedir 1503
pari_is_dir 86
pari_is_file 36
pari_is_rwx 340
pari_kill_file 58123
pari_last_tmp_file 89767
pari_last_was_newline 67523
pari_nb_hist 0
pari_open_file 35181
pari_printf 585
pari_putc 154355
pari_puts 34103
pari_safefopen 0
pari_set_last_newline 85864
pari_sprint0 14
pari_sprintf 12900
pari_stdin_isatty 1503
pari_strdup 28758
pari_strndup 0
pari_thread_close_files 66122
pari_tmp_dir 340
pari_unique_dir 340
pari_unique_filename 0
pari_unique_filename_suffix 0
pari_unlink 7160
pari_vfprintf 0
pari_vprintf 585
pari_vsprintf 23063
path_expand 4575
path_is_absolute 16
popinfile 67679
print 86866
print0 100250
print0_file 36
print1 13370
print_0_or_pm1 951104
print_context 2247
print_entree 0
print_errcontext 8105
print_functions_hash 0
print_precontext 1582
print_prefixed_text 13506
printf0 518
printp 7
prints 490
printsep 735
printsep1 21
printtex 7
putc_lw 6627366
puts_lw 224604
quote_string 10540
rdGEN 12
rd_long 44
rdstr 8
readbin 8
readobj 20
readstr 4
real0tostr 944
real0tostr_width_frac 12580
resetout 1503
set_last_newline 977354
shift_add 13722
sm_dopr 24302
stack_GENtostr_fun 165814
stack_GENtostr_fun_unquoted 200957
stack_sprintf 1345
stack_strcat 1190
stack_strdup 1345
str_absint 388285
str_addr 0
str_alloc 411301
str_alloc0 1169
str_arg_vprintf 52031
str_init 203442
str_long 132731
str_print0 10237
str_printf 27729
str_putc 7668883
str_puts 1478448
str_putscut 54628
str_ulong 132731
strftime_expand 0
string_gets 0
strlen_real 152609
switchin 23
switchin_last 7
switchout 0
switchout_get_FILE 36
term_color 660
term_get_color 55209
term_height 7
term_height_intern 7
term_width 15840
term_width_intern 15840
texVpowE 140
texe 0
texexpo 140
texi 60
texi_sign 194
texnome 140
texparen 0
times_monome 119315
times_texnome 112
try_dlopen 0
try_name 16
try_open 16
try_pipe 8
type_name 33476
utodec 2178022
v_get_arg 1638
vsigne 0
warning0 7
wr 36
wrGEN 12
wr_check 44
wr_dec 9692
wr_lead_monome 74911
wr_lead_texnome 98
wr_long 60
wr_monome 128226
wr_texnome 70
wr_vecsmall 3366
wrexpo 181654
write0 24
write1 8
writeGEN 4
write_magic 8
writebin 8
writenamedGEN 8
writetex 4
wrstr 8
zeros 19375
zerotostr 35

Generated by: LCOV version 1.11