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-bordeaux1.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 16624-25b9976) Lines: 1762 2428 72.6 %
Date: 2014-06-24 Functions: 235 279 84.2 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 1059 1878 56.4 %

Function Name Sort by function name Hit count Sort by hit count
GENtoGENstr 495
GENtoGENstr_nospace 0
GENtoTeXstr 0
GENtostr 0
GENtostr1 16327
GENtostr_aux 90541
GENtostr_fun 27702
GENtostr_fun_unquoted 88681
GENtostr_unquoted 4620
RgV_to_str 0
RgV_to_str_fun 7042
Str 7020
Str_fun 7030
Strchr 5
Strexpand 12
Strprintf 515
Strtex 10
VpowE 92265
_cfwrite 12
_expand_env 2807
_flush_log 100205
_fputs 26244
_fwrite 120
_initout 0
_lfwrite 108
_path_expand 2807
_putc_log 4566158
_puts_log 26244
absrtostr 11638
absrtostr_width_frac 185
blancs 0
brute 0
bruti 413094
bruti_intern 390224
bruti_sign 509491
check_filtre 868
check_magic 8
dbg 0
dbgGEN 0
dbg_addr 0
dbg_pari_heap 0
dbg_word 0
decode_color 0
delete_buffer 2612
delete_dirs 1794
dft_help 40
do_append 0
dopr_arg_vector 895
dosign 2890
eng_ord 0
env_ok 780
err_flush 0
err_printf 12
error0 10
ex10 11818
file_getline 45948
file_input 45928
file_is_binary 12
filestate_restore 1966
filtre 8811
filtre0 53871
fix_buffer 1215
fmtnum 2630
fmtreal 410
fmtstr 26208
forpath_init 16
forpath_next 16
fputGEN_pariout 0
gen_output 15718
gen_output_fun 15718
get_file 0
get_fun 62574
get_sigd 390
get_texvar 105
get_var 37018
gp_dlopen 40
gp_expand_path 913
gp_getenv 8
gp_read_file 8
gp_read_stream 1695
gp_read_stream_buf 2397
gp_readvec_file 4
gp_readvec_stream 19
gpinstall 40
gpwritebin 8
gsprintf 10
gvsprintf 60
history 105
init_filtre 3355
init_linewrap 16574
init_unique 390
initout 913
input_loop 37218
install0 40
is_dir_stat 16
is_long_ok 16
is_magic_ok 32
is_sizeoflong_ok 8
isdenom 25799
isfactor 123383
isnull 1845259
isone 643237
itoc 0
itostr 192106
itostr_sign 438824
kill_file_stack 1787
killallfiles 906
lim_lines_output 0
log10_2 8
ltoc 60
matbrute 0
matbruti 16070
monome 88010
new_buffer 2676
new_line 25
newfile 57036
normalErrC 67621
normalErrF 5888
normalErrS 26227
normalOutC 4498537
normalOutF 94317
normalOutS 17
numdig 438824
ok_pipe 0
os_getenv 2626
os_signal 9883
out_print0 46814
out_printf 1729
out_putc 229048
out_puts 119824
out_term_color 8374
out_vprintf 2509
outmat 0
outpad 3020
output 0
paren 5283
pari_add_hist 26928
pari_ask_confirm 0
pari_close_files 881
pari_close_homedir 881
pari_default_path 913
pari_dir_exists 390
pari_fclose 57011
pari_file_exists 0
pari_flush 92301
pari_fopen 0
pari_fopen_or_fail 41475
pari_fopengz 15510
pari_fprintf 0
pari_fread_chars 49727
pari_fread_longs 92
pari_get_hist 90
pari_get_histtime 15
pari_get_homedir 1834
pari_get_infile 15521
pari_init_files 913
pari_init_homedir 913
pari_is_dir 16
pari_is_file 32
pari_is_rwx 390
pari_kill_file 57036
pari_last_tmp_file 36807
pari_last_was_newline 28949
pari_nb_hist 0
pari_open_file 41475
pari_printf 618
pari_putc 160527
pari_puts 17568
pari_safefopen 0
pari_set_last_newline 37204
pari_sprint0 10
pari_sprintf 7461
pari_stdin_isatty 913
pari_strdup 19364
pari_strndup 0
pari_tmp_dir 390
pari_unique_dir 390
pari_unique_filename 0
pari_unlink 8506
pari_vfprintf 0
pari_vprintf 618
pari_vsprintf 8381
path_expand 2807
path_is_absolute 16
popinfile 1746
print 43919
print0 46684
print0_file 32
print1 2755
print_0_or_pm1 509688
print_context 159
print_entree 0
print_errcontext 1991
print_functions_hash 0
print_prefixed_text 2046
printf0 380
prints 670
printsep 115
printsep1 10
printtex 10
putc_lw 4460565
puts_lw 103805
quote_string 7778
rdGEN 20
rd_long 72
rdstr 12
readbin 8
readobj 28
real0tostr 559
real0tostr_width_frac 25
resetout 913
set_last_newline 348872
shift_add 795
sm_dopr 11845
stack_sprintf 920
stack_strcat 675
stack_strdup 920
str_absint 235479
str_addr 0
str_alloc 248877
str_alloc0 704
str_init 103993
str_long 64063
str_print0 42
str_putc 4694598
str_puts 722951
str_putscut 26208
str_ulong 64063
strftime_expand 0
strlen_real 9176
switchin 16
switchin_last 0
switchout 0
switchout_get_FILE 32
term_color 370
term_get_color 10692
term_height 5
term_height_intern 5
term_width 3616
term_width_intern 3616
texVpowE 150
texe 0
texexpo 150
texi 59
texi_sign 197
texnome 150
texparen 0
times_monome 71664
times_texnome 120
try_dlopen 0
try_name 16
try_open 16
try_pipe 0
type_name 14481
utodec 865044
v_get_arg 1275
vsigne 0
warning0 5
wr 32
wrGEN 20
wr_check 40
wr_dec 6862
wr_lead_monome 37388
wr_lead_texnome 105
wr_long 88
wr_monome 70251
wr_texnome 75
wr_vecsmall 1614
wrexpo 92265
write0 20
write1 8
writeGEN 4
write_magic 8
writebin 8
writenamedGEN 12
writetex 4
wrstr 12
zeros 4397
zerotostr 15

Generated by: LCOV version 1.9