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 - kernel/gmp - mp.c (source / functions) Hit Total Coverage
Test: PARI/GP v2.10.0 lcov report (development 21921-ca7d0c8) Lines: 647 716 90.4 %
Date: 2018-02-20 06:16:13 Functions: 53 54 98.1 %
Legend: Lines: hit not hit

Function Name Sort by function name Hit count Sort by hit count
pari_gmp_realloc 0
pari_kernel_close 912
pari_kernel_init 912
incneg 6268
resetloop 170732
pari_gmp_free 308956
divis 398454
floorr 497009
diviuuexact 528989
muluui 551197
addumului 854729
convi 894280
xmpn_copy 1485887
truncr 1729623
setloop 2496625
divri_with_gmp 3322805
sqrtremi 3487574
sqrispec_mirror 5291792
red_montgomery 11388177
icopy_ef 13245880
remi2n 16185144
divri 18688948
sqrtr_abs 23405508
mantissa2nr 25280109
divis_rem 31667444
divrr_with_gmp 34928312
muliispec_mirror 60344057
xmpn_zero 61656625
incpos 66477574
incloop 66505868
divrr 89378372
int_normalize 90512752
equaliispec 109597263
affir 119401456
diviu_rem 127854720
xmpn_mirror 195249986
adduispec_offset 260116003
mpz2GEN 263034215
diviiexact 269639303
GEN2mpz 274221445
xmpn_mirrorcopy 281689651
diviuexact 289912237
roundr_up_ip 304268263
shiftispec 393241776
sqrispec 783057128
subiuspec 846495574
umodiu 928315341
dvmdii 967538853
adduispec 1169345310
addiispec 1637637438
subiispec 1680121944
cmpiispec 2089911288
muliispec 2307469805
muluispec 2354838154

Generated by: LCOV version 1.11