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.8.0 lcov report (development 19053-42ab05e) Lines: 641 716 89.5 %
Date: 2016-06-29 Functions: 53 54 98.1 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 426 535 79.6 %

Function Name Sort by function name Hit count Sort by hit count
GEN2mpz 162511353
addiispec 1536336847
adduispec 1176190207
adduispec_offset 324285039
addumului 589545
affir 132468598
cmpiispec 1977429266
convi 480684
diviiexact 256806948
divis 341510
divis_rem 30453235
diviu_rem 122745605
diviuexact 234021540
diviuuexact 506254
divri 17652554
divri_with_gmp 3585819
divrr 105792931
divrr_with_gmp 31184381
dvmdii 753993860
equaliispec 48923000
floorr 510389
icopy_ef 18815537
incloop 31107399
incneg 6188
incpos 31091407
int_normalize 135787841
mantissa2nr 23554171
mpz2GEN 144489666
muliispec 1671384084
muliispec_mirror 61085134
muluispec 1804242113
muluui 528462
pari_gmp_free 6742
pari_gmp_realloc 0
pari_kernel_close 1272
pari_kernel_init 1780
red_montgomery 6599588
remi2n 10554523
resetloop 156744
roundr_up_ip 176956043
setloop 2236615
shiftispec 282768463
sqrispec 615089216
sqrispec_mirror 4212374
sqrtr_abs 22542979
sqrtremi 1695613
subiispec 1709502270
subiuspec 1034606358
truncr 743440
umodiu 632495605
xmpn_copy 1251753
xmpn_mirror 209106806
xmpn_mirrorcopy 269988766
xmpn_zero 57313179

Generated by: LCOV version 1.9