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 - compile.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.8.0 lcov report (development 19614-52e089f) Lines: 1327 1489 89.1 %
Date: 2016-09-28 05:54:17 Functions: 77 80 96.2 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
call0 21
cattovec 30072
checkdups 12861
closure_deriv 49
closurefunc 7799
compilecall 16376
compilecast 5361909
compilecast_loc 5477323
compilefunc 2628544
compilefuncinline 14249
compilelambda 22
compilelocal 7
compilelvalue 959
compilemat 7105
compilematcoeff 6311
compilemy 1657
compilenewptr 448
compilenode 13177523
compileseq 7299
compilesmall 6747919
compilestate_reset 168
compilestate_restore 30189
compilestate_save 1316967
compilestore 21458
compileuninline 4
compilevec 3791692
copyifclone 142033
countlisttogen 12968043
countvar 1664
ctxmvar 6764
data_push 1785337
debug_context 0
detag 224709
fetch_member_raw 20384
first_safe_arg 5294292
frame_push 130916
genclosure 122099
genclosurectx 114291
get_ret_type 3407059
getclosure 14283
getcodepos 217774
getentry 192338
getfunc 5470131
getfunction 217767
getlvalue 23047
getmvar 189038
getvar 42506
gp_closure 81264
is_func_named 21016536
is_node_zero 2121
listtogen 12967924
localpush 42
localvars_find 7
localvars_read_str 10108
matchQ 0
matindex_type 7382
op_insert_loc 1638
op_push 28479058
op_push_loc 29802592
optimizecall 16383
optimizefunc 2623609
optimizemat 7105
optimizematcoeff 6808
optimizenode 15205768
optimizeseq 7292
optimizevec 3791993
pack_localvars 35
pari_close_compiler 205178
pari_init_compiler 205052
pari_translate_string 0
parseproto 9130578
push_frame 210
snm_closure 2152
str_defproto 35
strntoGENexp 1107930
strtoclosure 112148
strtofunction 7
translate 1107930
var_push 50547
vec_optimize 3860051

Generated by: LCOV version 1.11