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 16791-0d1274a) Lines: 1769 2431 72.8 %
Date: 2014-09-16 Functions: 235 279 84.2 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 1066 1878 56.8 %

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 90710
GENtostr_fun 27859
GENtostr_fun_unquoted 88729
GENtostr_unquoted 4658
RgV_to_str 0
RgV_to_str_fun 7042
Str 7020
Str_fun 7030
Strchr 5
Strexpand 12
Strprintf 515
Strtex 10
VpowE 92610
_cfwrite 12
_expand_env 2822
_flush_log 100599
_fputs 26471
_fwrite 120
_initout 0
_lfwrite 108
_path_expand 2822
_putc_log 4507587
_puts_log 26471
absrtostr 10855
absrtostr_width_frac 185
blancs 0
brute 0
bruti 412148
bruti_intern 389189
bruti_sign 508123
check_magic 8
dbg 0
dbgGEN 0
dbg_addr 0
dbg_pari_heap 0
dbg_word 0
decode_color 0
delete_buffer 2617
delete_dirs 1804
dft_help 40
do_append 0
dopr_arg_vector 915
dosign 2913
eng_ord 0
env_ok 770
err_flush 0
err_printf 12
error0 10
ex10 11035
file_getline 46308
file_input 46288
file_is_binary 12
filestate_restore 1984
filtre 8831
filtre0 54246
fix_buffer 1205
fmtnum 2633
fmtreal 430
fmtstr 26321
forpath_init 16
forpath_next 16
fputGEN_pariout 0
gen_output 15830
gen_output_fun 15830
get_file 0
get_fun 62691
get_sigd 410
get_texvar 105
get_var 37040
gp_dlopen 40
gp_expand_path 918
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 100
in_help 420
init_filtre 3360
init_linewrap 16691
init_unique 385
initout 918
input_loop 37473
install0 40
is_dir_stat 16
is_long_ok 16
is_magic_ok 32
is_sizeoflong_ok 8
isdenom 25820
isfactor 123269
isnull 1843359
isone 642106
itoc 0
itostr 190685
itostr_sign 436576
kill_file_stack 1797
killallfiles 911
lim_lines_output 0
log10_2 8
ltoc 60
matbrute 0
matbruti 16182
monome 88305
new_buffer 2681
new_line 25
newfile 56476
normalErrC 68092
normalErrF 5942
normalErrS 26454
normalOutC 4439495
normalOutF 94657
normalOutS 17
numdig 436576
ok_pipe 0
os_getenv 2626
os_signal 9938
out_print0 46819
out_printf 1734
out_putc 229644
out_puts 120091
out_term_color 8446
out_vprintf 2492
outmat 0
outpad 3043
output 0
paren 5265
pari_add_hist 27130
pari_ask_confirm 0
pari_close_files 886
pari_close_homedir 886
pari_default_path 918
pari_dir_exists 385
pari_fclose 56451
pari_file_exists 0
pari_flush 92623
pari_fopen 0
pari_fopen_or_fail 40915
pari_fopengz 15510
pari_fprintf 0
pari_fread_chars 49727
pari_fread_longs 92
pari_get_hist 85
pari_get_histtime 15
pari_get_homedir 1844
pari_get_infile 15521
pari_init_files 918
pari_init_homedir 918
pari_is_dir 16
pari_is_file 32
pari_is_rwx 385
pari_kill_file 56476
pari_last_tmp_file 37080
pari_last_was_newline 29169
pari_nb_hist 0
pari_open_file 40915
pari_printf 596
pari_putc 160652
pari_puts 17705
pari_safefopen 0
pari_set_last_newline 37384
pari_sprint0 10
pari_sprintf 7479
pari_stdin_isatty 918
pari_strdup 19427
pari_strndup 0
pari_tmp_dir 385
pari_unique_dir 385
pari_unique_filename 0
pari_unlink 8391
pari_vfprintf 0
pari_vprintf 596
pari_vsprintf 8424
path_expand 2822
path_is_absolute 16
popinfile 1756
print 43924
print0 46689
print0_file 32
print1 2755
print_0_or_pm1 508320
print_context 159
print_entree 0
print_errcontext 2009
print_functions_hash 0
print_prefixed_text 2064
printf0 400
prints 670
printsep 115
printsep1 10
printtex 10
putc_lw 4402303
puts_lw 103930
quote_string 7813
rdGEN 20
rd_long 72
rdstr 12
readbin 8
readobj 28
real0tostr 579
real0tostr_width_frac 25
resetout 918
set_last_newline 349735
shift_add 875
sm_dopr 11891
stack_sprintf 945
stack_strcat 680
stack_strdup 945
str_absint 235455
str_addr 0
str_alloc 248050
str_alloc0 664
str_init 104203
str_long 64125
str_print0 42
str_putc 4634814
str_puts 721870
str_putscut 26321
str_ulong 64125
strftime_expand 0
strlen_real 9256
switchin 16
switchin_last 0
switchout 0
switchout_get_FILE 32
term_color 370
term_get_color 10790
term_height 5
term_height_intern 5
term_width 3634
term_width_intern 3634
texVpowE 150
texe 0
texexpo 150
texi 59
texi_sign 197
texnome 150
texparen 0
times_monome 71540
times_texnome 120
try_dlopen 0
try_name 16
try_open 16
try_pipe 0
type_name 14486
utodec 856055
v_get_arg 1335
vsigne 0
warning0 5
wr 32
wrGEN 20
wr_check 40
wr_dec 5890
wr_lead_monome 37385
wr_lead_texnome 105
wr_long 88
wr_monome 70490
wr_texnome 75
wr_vecsmall 1510
wrexpo 92610
write0 20
write1 8
writeGEN 4
write_magic 8
writebin 8
writenamedGEN 12
writetex 4
wrstr 12
zeros 4566
zerotostr 15

Generated by: LCOV version 1.9